@@ -11,13 +11,13 @@ define([
1111//>>excludeEnd("jqmBuildExclude");
1212
1313( function ( $ , undefined ) {
14- var path = $ . mobile . path , history , popstateEvent ;
14+ var path = $ . mobile . path , history ;
1515
1616 // TODO consider queueing navigation activity until previous activities have completed
1717 // so that end users don't have to think about it. Punting for now
1818 // TODO !! move the event bindings into callbacks on the navigate event
1919 $ . navigate = function ( url , data , noEvents ) {
20- var state , href , parsed , loc , hash ,
20+ var state , href , parsed , loc , hash , popstateEvent ,
2121 resolutionUrl = path . isPath ( url ) ? path . getLocation ( ) : $ . mobile . getDocumentUrl ( ) ;
2222
2323 // Get the url as it would look squashed on to the current resolution url
@@ -69,7 +69,7 @@ define([
6969 title : document . title
7070 } , data ) ;
7171
72- if ( $ . support . pushState ) {
72+ if ( $ . event . special . navigate . isPushStateEnabled ( ) ) {
7373 popstateEvent = new $ . Event ( "popstate" ) ;
7474 popstateEvent . originalEvent = {
7575 type : "popstate" ,
@@ -134,7 +134,7 @@ define([
134134
135135 // Partly to support our test suite which manually alters the support
136136 // value to test hashchange. Partly to prevent all around weirdness
137- if ( ! $ . support . pushState ) {
137+ if ( ! $ . event . special . navigate . isPushStateEnabled ( ) ) {
138138 return ;
139139 }
140140
@@ -211,7 +211,7 @@ define([
211211
212212 // If pushstate is supported the state will be included in the popstate event
213213 // data and appended to the navigate event. Late check here for late settings (eg tests)
214- if ( $ . support . pushState ) {
214+ if ( $ . event . special . navigate . isPushStateEnabled ( ) ) {
215215 return ;
216216 }
217217
0 commit comments