提交 9ade3092 编写于 作者: C Catouse

* fix error in model trigger.

上级 7c63d5d3
...@@ -41,6 +41,7 @@ ...@@ -41,6 +41,7 @@
showHeader: true, showHeader: true,
delay: 0, delay: 0,
// iframeBodyClass: '', // iframeBodyClass: '',
// onlyIncreaseHeight: false,
backdrop: true, backdrop: true,
keyboard: true keyboard: true
}; };
...@@ -247,10 +248,15 @@ ...@@ -247,10 +248,15 @@
// todo: update iframe url to ref attribute // todo: update iframe url to ref attribute
var $framebody = frame$('body').addClass('body-modal'); var $framebody = frame$('body').addClass('body-modal');
if(options.iframeBodyClass) $framebody.addClass(options.iframeBodyClass); if(options.iframeBodyClass) $framebody.addClass(options.iframeBodyClass);
var ajustFrameSize = function() var ajustFrameSize = function(check)
{ {
$modal.removeClass('fade'); $modal.removeClass('fade');
var height = $framebody.outerHeight(); var height = $framebody.outerHeight();
if(check === true && options.onlyIncreaseHeight)
{
height = Math.max(height, $body.data('minModalHeight') || 0);
$body.data('minModalHeight', height);
}
$body.css('height', height); $body.css('height', height);
if (options.fade) $modal.addClass('fade'); if (options.fade) $modal.addClass('fade');
readyToShow(); readyToShow();
...@@ -264,7 +270,7 @@ ...@@ -264,7 +270,7 @@
setTimeout(ajustFrameSize, 100); setTimeout(ajustFrameSize, 100);
$framebody.off('resize.' + NAME).on('resize.' + NAME, ajustFrameSize); $framebody.off('resize.' + NAME).on('resize.' + NAME, function(){ajustFrameSize(true)});
} }
frame$.extend( frame$.extend(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册