From 41919836b20e00b9a494de1df4f2ee625d9e8dbb Mon Sep 17 00:00:00 2001 From: jlukic Date: Fri, 28 Feb 2014 00:02:37 -0500 Subject: [PATCH] Fixes #614, issue with modal vertical position on multiple shows --- src/modules/modal.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/modal.js b/src/modules/modal.js index 97ad251e9..c19c5f09f 100755 --- a/src/modules/modal.js +++ b/src/modules/modal.js @@ -429,7 +429,7 @@ $.fn.modal = function(parameters) { cacheSizes: function() { module.cache = { pageHeight : $body.outerHeight(), - height : $module.outerHeight() + settings.offset + parseInt($module.css('marginTop'), 10), + height : $module.outerHeight() + settings.offset, contextHeight : (settings.context == 'body') ? $(window).height() : $dimmable.height() @@ -490,7 +490,7 @@ $.fn.modal = function(parameters) { } }, position: function() { - module.verbose('Centering modal on page', module.cache, module.cache.height / 2); + module.verbose('Centering modal on page', module.cache); if(module.can.fit()) { $module .css({