Fix for issue #1405: Moved assignment of $activeClickedLink to the vclick handler in charge of adding the active state

This commit is contained in:
gseguin 2011-08-17 17:32:55 -07:00
parent d55b225ae9
commit 9f3836e7b1

View file

@ -1068,7 +1068,8 @@
var link = findClosestLink( event.target );
if ( link ) {
if ( path.parseUrl( link.getAttribute( "href" ) || "#" ).hash !== "#" ) {
$( link ).closest( ".ui-btn" ).not( ".ui-disabled" ).addClass( $.mobile.activeBtnClass );
$activeClickedLink = $( link ).closest( ".ui-btn" ).not( ".ui-disabled" );
$activeClickedLink.addClass( $.mobile.activeBtnClass );
$( "." + $.mobile.activePageClass + " .ui-btn" ).not( link ).blur();
}
}
@ -1146,8 +1147,6 @@
// moved into more comprehensive isExternalLink
isExternal = useDefaultUrlHandling || ( path.isExternal( href ) && !isCrossDomainPageLoad );
$activeClickedLink = $link.closest( ".ui-btn" );
if( isExternal ) {
httpCleanup();
//use default click handling