Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
TerryZ committed Jul 24, 2017
1 parent 592f6af commit dd7e5ac
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 11 deletions.
1 change: 1 addition & 0 deletions b.dialog.bootstrap3.css
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ div.bDialog.fullWidth {
-webkit-border-radius: 0px;
-moz-border-radius: 0px;
border-radius: 0px;
padding-right: 0px;
}
div.bDialog.fullWidth div.modal-header {
-webkit-border-radius: 0px;
Expand Down
24 changes: 14 additions & 10 deletions b.dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -197,16 +197,18 @@
$(this).remove();
if($('[dialog="bDialog"]',$(topBody)).size() > 0) $('[dialog="bDialog"]:last',$(topBody)).addClass('dialogInActive');
});
$top('div.bDialog:last',$top(topBody)).off('click.bDialog').on('click.bDialog',function(e){
var srcEl = e.target || e.srcElement;
if($(srcEl).is('div.bDialog')){
var that = $top('div.bDialog:last',$top(topBody));
$top(that).removeClass('animated').removeClass('shake');
setTimeout(function () {
that.addClass('animated').addClass('shake');
}, 0);
}
});
if(!p.fullWidth){
$top('div.bDialog:last',$top(topBody)).off('click.bDialog').on('click.bDialog',function(e){
var srcEl = e.target || e.srcElement;
if($(srcEl).is('div.bDialog')){
var that = $top('div.bDialog:last',$top(topBody));
$top(that).removeClass('animated').removeClass('shake');
setTimeout(function () {
that.addClass('animated').addClass('shake');
}, 0);
}
});
}
//浏览器窗口尺寸变化时,自动对窗口位置进行调整
$top(window.top).bind('resize.bDialog', function() {
// clear a previously set timeout
Expand Down Expand Up @@ -293,6 +295,8 @@
var bodyFrameCss = {'height':frameHeight,'max-height':frameHeight};
$("iframe.bDialogBodyFrame",$(dialog)).css(bodyFrameCss);
}
if(p.fullWidth) $(dialog).css('padding-right','0px');

//清除所有已弹出窗口的当前激活样式
$('[dialog="bDialog"]',$(topBody)).removeClass('dialogInActive');
$(dialog).addClass('dialogInActive');
Expand Down
Loading

0 comments on commit dd7e5ac

Please sign in to comment.