This repository was archived by the owner on Oct 8, 2021. It is now read-only.
Closed
Conversation
Nested lists with same parent text resolve to the same sub-page.
Handle case where page has an id (url), we want to use that as a key in the listCountPerPage dictionary
…broken in latest
- The test case calls changePage() with a hash ("#b"). In our normal processing of clicks/form submits we strip it before calling. The old code did a strip in changePage() just in case, so I added it back in to fix the last bug.
Nested lists with same parent text resolve to the same sub-page.
Handle case where page has an id (url), we want to use that as a key in the listCountPerPage dictionary
js/jquery.mobile.listview.js
Outdated
Contributor
There was a problem hiding this comment.
What's the $.expando thing about? Is that leftover from the previous pull request?
Contributor
Author
There was a problem hiding this comment.
it's to use the jQuery internal id as a key for the listCountPerPage hash instead of undefined in case the parentPage does not have an id.
…sue-1617 Conflicts: tests/unit/listview/listview_core.js
js/jquery.mobile.listview.js
Outdated
Contributor
There was a problem hiding this comment.
Along the lines of the email I sent to you Scott and John ... I think the listCountPerPage increment should be moved out of the each(). What we're really trying to do here is identify the listview on the page. Then we could do something like:
parentListId = parentList.attr("id") || ++listCountPerPage[parentId];
... each(function( i ) {
listId = list.attr("id") || parentListId + "-" + i;
…inging this up to jQuery coding standards. Renamed one memory variable for legibility and clarity. Signed-off-by: Steven Black <steveb@stevenblack.com>
Nested lists with same parent text resolve to the same sub-page.
Handle case where page has an id (url), we want to use that as a key in the listCountPerPage dictionary
Reformatted changes to code standards
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Nested lists with same parent text resolve to the same sub-page.