Skip to content

Instantly share code, notes, and snippets.

@gabrielschulhof
Created September 21, 2012 07:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gabrielschulhof/3760126 to your computer and use it in GitHub Desktop.
Save gabrielschulhof/3760126 to your computer and use it in GitHub Desktop.
Put back _registerInternalEVents
diff --git a/js/jquery.mobile.navigation.js b/js/jquery.mobile.navigation.js
index ae18def..a116012 100644
--- a/js/jquery.mobile.navigation.js
+++ b/js/jquery.mobile.navigation.js
@@ -1243,7 +1243,7 @@ define( [
//The following event bindings should be bound after mobileinit has been triggered
//the following deferred is resolved in the init file
$.mobile.navreadyDeferred = $.Deferred();
- $.mobile.navreadyDeferred.done(function() {
+ $.mobile._registerInternalEvents = function() {
//bind to form submit events, handle with Ajax
$( document ).delegate( "form", "submit", function( event ) {
var $this = $( this );
@@ -1545,7 +1545,8 @@ define( [
$( document ).bind( "pageshow", resetActivePageHeight );
$( window ).bind( "throttledresize", resetActivePageHeight );
- });//navreadyDeferred done callback
+ };//navreadyDeferred done callback
+ $.mobile.navreadyDeferred.done( $.mobile._registerInternalEvents );
})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
@gabrielschulhof
Copy link
Author

This doesn't really change the logic. It merely saves a pointer to the callback function we pass into .done() for people to overwrite.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment