From 79929949dbdda63c15033935a30c41b4b4c38032 Mon Sep 17 00:00:00 2001 From: Alex Kovar Date: Sat, 5 Feb 2011 14:00:31 -0600 Subject: [PATCH 1/3] fix issue with failed page load not releasing page transition lock --- js/jquery.mobile.navigation.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/js/jquery.mobile.navigation.js b/js/jquery.mobile.navigation.js index 729e4e64..85b174fd 100644 --- a/js/jquery.mobile.navigation.js +++ b/js/jquery.mobile.navigation.js @@ -337,6 +337,13 @@ } } + function releasePageTransitionLock(){ + isPageTransitioning = false; + if(pageTransitionQueue.length>0) { + $.mobile.changePage.apply($.mobile, pageTransitionQueue.pop()); + } + } + //function for transitioning between two existing pages function transitionPages() { $.mobile.silentScroll(); @@ -398,10 +405,7 @@ //remove initial build class (only present on first pageshow) $html.removeClass( "ui-mobile-rendering" ); - isPageTransitioning = false - if(pageTransitionQueue.length>0) { - $.mobile.changePage.apply($.mobile, pageTransitionQueue.pop()); - } + releasePageTransitionLock(); }; function addContainerClass(className){ @@ -566,6 +570,7 @@ .fadeOut( 400, function(){ $(this).remove(); }); + releasePageTransitionLock(); } }); } From d970c20e4c890d358bd61ab832b0683dc7ef1ae4 Mon Sep 17 00:00:00 2001 From: Alex Kovar Date: Sat, 5 Feb 2011 14:03:31 -0600 Subject: [PATCH 2/3] fixed error when from is undefined --- js/jquery.mobile.navigation.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/jquery.mobile.navigation.js b/js/jquery.mobile.navigation.js index 85b174fd..d8e60992 100644 --- a/js/jquery.mobile.navigation.js +++ b/js/jquery.mobile.navigation.js @@ -439,7 +439,7 @@ // callback - remove classes, etc to.animationComplete(function() { - from.add( to ).removeClass("out in reverse " + transition ); + to.add(from).removeClass("out in reverse " + transition ); if( from ){ from.removeClass( $.mobile.activePageClass ); } From 910c4d43f019e90906b14b06659694fe35ec554e Mon Sep 17 00:00:00 2001 From: Alex Kovar Date: Sat, 5 Feb 2011 14:39:11 -0600 Subject: [PATCH 3/3] fixed small display glitch on navigation tests --- tests/unit/navigation/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/unit/navigation/index.html b/tests/unit/navigation/index.html index 7fe04e58..b1b38751 100644 --- a/tests/unit/navigation/index.html +++ b/tests/unit/navigation/index.html @@ -50,7 +50,7 @@