Closed
Bug 718268
Opened 13 years ago
Closed 13 years ago
After closing tab, tab list scrolls back to the top
Categories
(Firefox for Android Graveyard :: General, defect, P3)
Tracking
(firefox13 verified, fennec+)
VERIFIED
FIXED
Firefox 13
People
(Reporter: martijn.martijn, Assigned: sriram)
Details
(Whiteboard: tabs-ux)
Attachments
(1 file, 1 obsolete file)
1.77 KB,
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
Steps to reproduce:
- Open 8 tabs or more
- Open the tab list popup by tapping on the thing on the right of the url bar
- Select the last tab in the tab list
- Close the last tab
Expected result:
Last tab is closed, the second to last tab is the last tab now and is selected and in view.
Actual result:
Last tab is closed, the second to last tab is the last tab now and is selected, but is not in view. The tab list has scrolled to the beginning.
Updated•13 years ago
|
tracking-fennec: --- → +
Priority: -- → P3
Updated•13 years ago
|
Whiteboard: tabs-ux
Assignee | ||
Updated•13 years ago
|
Assignee: nobody → sriram
Assignee | ||
Comment 1•13 years ago
|
||
setSelection() (my bad, I didn't know about it) perfectly positions the view. Now that we know when a List is inflated (basically after requestLayout() on the ListContainer), we can safely do a setSelection() for the list.
This also solves the problem in Eclair.
Also, closing Tab 1 when Tab 6 (obscured from the view) is the selected tab, should not scroll the list to Tab 6. The mScrollToSelectedTab flag takes care of the same.
Attachment #595217 -
Flags: review?(mark.finkle)
Assignee | ||
Comment 2•13 years ago
|
||
I think there is a problem with this patch. If there are 10 tabs with tabs 4-6 shown to the user, and user closes tab 5, it still scrolls to the top.
Do we really want to show tabs 4,6,7 to the user? (Requires more calculations and scrolling properly). Or do we want to scroll to the selected tab every time a tab is closed?
Please treat this patch to be a WIP until we know what we want to do ;)
Comment 3•13 years ago
|
||
Comment on attachment 595217 [details] [diff] [review]
Patch
Do we really need the mScrollToSelectedTab code at all? When a user closes a tab, we should not attempt to scroll at all, right?
Changing from review to feedback
Attachment #595217 -
Flags: review?(mark.finkle) → feedback+
Assignee | ||
Comment 4•13 years ago
|
||
This seems a better approach to me. Here we just remove the tab from the adapter and invalidate the list's views. Thereby the scroll position is retained (by listview itself), the views are redrawn as needed.
Attachment #595217 -
Attachment is obsolete: true
Attachment #596841 -
Flags: review?(mark.finkle)
Updated•13 years ago
|
Attachment #596841 -
Flags: review?(mark.finkle) → review+
Assignee | ||
Comment 5•13 years ago
|
||
Comment 6•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 13
Comment 7•13 years ago
|
||
Nightly 13.0a1 (2012-02-15)
Device: Samsung Nexus S - Android 2.3.6
When closing the last tab, the second to last tab is the last tab now and is selected and in view.
Status: RESOLVED → VERIFIED
status-firefox13:
--- → verified
Updated•5 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•