Closed Bug 1214602 Opened 9 years ago Closed 9 years ago

Bring back single column layout for tabs tray

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
normal

Tracking

(firefox44 fixed)

RESOLVED FIXED
Firefox 44
Tracking Status
firefox44 --- fixed

People

(Reporter: sebastian, Assigned: sebastian)

References

Details

Attachments

(3 files, 1 obsolete file)

In bug 1202861 we want to introduce a setting to switch between single and multi column mode in the tabs tray. This will require that we bring back the single column layout. We've also been discussing whether we just want to bring back the one column layout (but keeping the other improvements) and move the setting as well as the multi column layout to v3 - just because we've got our plate full as it is. Currently (in Nightly) we use TabsGridLayout and there are several ways how we could get the single column mode back: 1) Just use TabsListLayout on phones again. This is definitely the easiest one. There might be regressions that have been hiding because we did not use this view for quite some time. This is probably the preferable solution if we decide to move multi column mode to v3. 2) Continue to use TabsGridLayout and just set it to one column. This would allow us to continue to use the current code base. However we'd need to use a different layout for the tabs itself when using one column mode. And I'm not sure if we can switch the number of columns at runtime. 3) Switch to RecyclerView (bug 1116415). Switching between different layouts is as easy as just switching the LayoutManager on the RecyclerView. Martyn attached a WIP patch in bug 1116415 but I expect that we still need some time to get it right and fix the fallout. However this will be the groundwork to unlock other future features like animations (bug 818124) and better swipe-to-close (bug 1178794).
If we decide to go back to one column layout only and do multi column layout in v3 then I'd prefer option 1. If we want to have the column mode toggle now then I'm more in favor of investing some more time and to go with option 3.
Attached patch 1214602-option1-WIP.patch (obsolete) (deleted) — Splinter Review
This is a WIP patch for option 1. It reverts back to using TabsListLayout in portrait mode but continues to use (multi-column) TabsGridLayout in landscape mode.
I think it's valuable to improve our tabs tray with the way of option 3. This is a really high visibility part of our UI and will likely be a place that a lot of inter-product features send our users. It would be nice to always welcome them with a nice, polished experience. RecyclerView is also going to be pretty useful for a bunch of stuff that will really drive this quality and polish to the finish line. But, at the same time I see the issue with resourcing and focusing. Could we get an estimate as to how long adding RecyclerView may take?
Flags: needinfo?(s.kaspari)
(In reply to Anthony Lam (:antlam) from comment #5) > I think it's valuable to improve our tabs tray with the way of option 3. > [..] > Could we get an estimate as to how long adding RecyclerView may take? I agree (I want to make compact tabs and RecyclerView happen). It's hard to estimate. Just migrating a GridView/List to a RecyclerView is not that big of a task but the tabs tray is more complex. I expect that we will need some days to tweak this and see how it performs and feels like in Nightly. With the time constraint (~2 weeks until merge day) I think we should go with option 1 here, group all "compact tabs" bugs and solve them with a RecyclerView based implementation in Fx45 or Fx46.
Flags: needinfo?(s.kaspari)
Attached image tabstray-landscape.png (deleted) —
Unfortunately the Nightly flags did not completely safe us from regressing the TabsListLayout. In landscape the dimensions are currently distorted. I'm tempted to keep the (multi-column) GridLayout in landscape, but I also fear that this means we will have to fix all the fallout we already know. But then again we might have to fix some of that for tablets too. But first I'll look into fixing the list - maybe it's easy.
Attachment #8673629 - Attachment is obsolete: true
Bug 1214602 - Bring back single column layout for tabs tray. r?margaret This patch will use the single column list on phones in portrait mode again. In landscape mode the multi column grid will be used. In addition to that this patch removes the Nightly flag (Bug 1204917).
Attachment #8675560 - Flags: review?(margaret.leibovic)
(In reply to Sebastian Kaspari (:sebastian) from comment #8) > Created attachment 8675560 [details] > MozReview Request: Bug 1214602 - Bring back single column layout for tabs > tray. r?margaret I tested this patch on all devices I have here (Android 6, 5 and 2.3). The patch keeps the grid in landscape mode because the single-column horizontally list is not really made for full screen. This seems to be the easier solution until we have more time building the compact mode.
Comment on attachment 8675560 [details] MozReview Request: Bug 1214602 - Bring back single column layout for tabs tray. r?margaret https://reviewboard.mozilla.org/r/22393/#review19987 Well that's pretty simple!
Attachment #8675560 - Flags: review?(margaret.leibovic) → review+
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 44
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: