Created
May 4, 2015 13:31
-
-
Save gabrielschulhof/a88a897885df25907111 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/js/widgets/page.js b/js/widgets/page.js | |
index 7c6a144..a9a7950 100644 | |
--- a/js/widgets/page.js | |
+++ b/js/widgets/page.js | |
@@ -83,6 +83,11 @@ $.widget( "mobile.page", { | |
}, | |
_create: function() { | |
+ // Dialog widget is deprecated in 1.4 remove this in 1.5 | |
+ if ( $.mobile.getAttribute( this.element[ 0 ], "role" ) === "dialog" ) { | |
+ this.options.dialog = true; | |
+ } | |
+ | |
// If false is returned by the callbacks do not create the page | |
if ( this._trigger( "beforecreate" ) === false ) { | |
return false; | |
@@ -100,10 +105,6 @@ $.widget( "mobile.page", { | |
if ( this.options.enhance ) { | |
this.element.enhanceWithin(); | |
} | |
- // Dialog widget is deprecated in 1.4 remove this in 1.5 | |
- if ( $.mobile.getAttribute( this.element[ 0 ], "role" ) === "dialog" && $.mobile.dialog ) { | |
- this.element.dialog(); | |
- } | |
}, | |
_enhance: function() { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment