navbar link stays active when using changePage() #1181

Closed
dirkpennings opened this Issue Mar 3, 2011 · 5 comments

Projects

None yet

7 participants

@dirkpennings

When using $.mobile.changePage() to navigate to your second internal linked page and going back through the back button, you see the clicked navbar link still has the class "ui-btn-active".

This unlike the normal internal linking functionality..

examples (click the "Bar" menu option):

normal, working: http://jsfiddle.net/dirkpennings/kt7VQ/

changePage, not working: http://jsfiddle.net/dirkpennings/EPUqj/

@toddparker
Contributor

Updated the changePage example with latest:
http://jsfiddle.net/EPUqj/4/

@johnbender johnbender was assigned Sep 22, 2011
@toddparker
Contributor

@dirkpennings - Is this still an issue with 1.0.1?
Also please test on master (1.1-pre): www.jquerymobile.com/test

@jefftougas

Still seems to be an issue.. Example with nightly build: http://jsfiddle.net/YkhQH/2/

@jasondscott jasondscott was assigned Jun 8, 2012
@jasondscott jasondscott pushed a commit to jasondscott/jquery-mobile that referenced this issue Jun 21, 2012
Jason Scott Fixes: #1181 - navbar link stays active when using changePage()
Clears the active button class on the pressed navbar button after a
pagechange.
f8abd04
@polarfish

Excuse me, I may not completely understand the process of releasing fixes, but when the fix of this bug will be released? In version 1.3.0? It's opened 2 years ago and still has "No milestone" label.

@jaspermdegroot
Member

Closing as fixed by 64143ae

@jaspermdegroot jaspermdegroot added a commit that referenced this issue Apr 1, 2013
@jaspermdegroot jaspermdegroot Navbar: Changed active state logic. Fixes #5707
Removed workaround for #1181. Fixed that issue by addressing the actual cause: event.target returns ui-btn-inner instead of the anchor
70e2aed
@jaspermdegroot jaspermdegroot added a commit that referenced this issue Apr 1, 2013
@jaspermdegroot jaspermdegroot Navbar: Changed active state logic. Fixes #5707
Removed workaround for #1181. Fixed that issue by addressing the actual cause: event.target returns ui-btn-inner instead of the anchor
440f7c0
@jaspermdegroot jaspermdegroot added a commit that referenced this issue Apr 1, 2013
@jaspermdegroot jaspermdegroot Navbar: make sure nav buttons with href="#" still get active state.
This fixes a regression from the fix for #5707. That issue was a regression from the fix for #1181. I added the workaround for #1181 again but changed the event to avoid the regression.
307ff5e
@jaspermdegroot jaspermdegroot added a commit that referenced this issue Apr 1, 2013
@jaspermdegroot jaspermdegroot Navbar: make sure nav buttons with href="#" still get active state.
This fixes a regression from the fix for #5707. That issue was a regression from the fix for #1181. I added the workaround for #1181 again but changed the event to avoid the regression.
cf54b98
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment