From 84f1e4f257268b4b8d6132065263702e61074797 Mon Sep 17 00:00:00 2001 From: scottjehl Date: Wed, 29 Feb 2012 19:53:52 +0800 Subject: [PATCH] modified the resetActivePageHeight internal function so that it subtracts top and bottom padding before setting the min-height amount. This fixes #3663. It may also influence issue #3556, so worth retesting. --- js/jquery.mobile.navigation.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/js/jquery.mobile.navigation.js b/js/jquery.mobile.navigation.js index 25cb39f9e05..85e4732d62f 100644 --- a/js/jquery.mobile.navigation.js +++ b/js/jquery.mobile.navigation.js @@ -522,7 +522,11 @@ define( [ //simply set the active page's minimum height to screen height, depending on orientation function resetActivePageHeight(){ - $( "." + $.mobile.activePageClass ).css( "min-height", getScreenHeight() ); + var aPage = $( "." + $.mobile.activePageClass ), + aPagePadT = parseFloat( aPage.css( "padding-top" ) ), + aPagePadB = parseFloat( aPage.css( "padding-bottom" ) ); + + aPage.css( "min-height", getScreenHeight() - aPagePadT - aPagePadB ); } //shared page enhancements