mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-04-24 08:04:43 +00:00
Merge remote branch 'origin/master'
This commit is contained in:
commit
30e085c05b
1 changed files with 15 additions and 6 deletions
|
|
@ -960,14 +960,25 @@
|
|||
return;
|
||||
}
|
||||
|
||||
var $link = $( link );
|
||||
var $link = $( link ),
|
||||
//remove active link class if external (then it won't be there if you come back)
|
||||
httpCleanup = function(){
|
||||
window.setTimeout( function() { removeActiveLinkClass( true ); }, 200 );
|
||||
};
|
||||
|
||||
//if there's a data-rel=back attr, go back in history
|
||||
if( $link.is( ":jqmData(rel='back')" ) ) {
|
||||
window.history.back();
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
//if ajax is disabled, exit early
|
||||
if( !$.mobile.ajaxEnabled ){
|
||||
httpCleanup();
|
||||
//use default click handling
|
||||
return;
|
||||
}
|
||||
|
||||
var baseUrl = getClosestBaseUrl( $link ),
|
||||
|
||||
//get href, if defined, otherwise default to empty hash
|
||||
|
|
@ -1016,10 +1027,8 @@
|
|||
|
||||
$activeClickedLink = $link.closest( ".ui-btn" );
|
||||
|
||||
if( isExternal || !$.mobile.ajaxEnabled ) {
|
||||
//remove active link class if external (then it won't be there if you come back)
|
||||
window.setTimeout( function() { removeActiveLinkClass( true ); }, 200 );
|
||||
|
||||
if( isExternal ) {
|
||||
httpCleanup();
|
||||
//use default click handling
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue