Bug #1068
open
Closing first tab visually truncates the new first tab
Added by v ... over 1 year ago.
Updated over 1 year ago.
Description
- Open 4 or 5 tabs ;
- Select the first tab ;
- Close it through the X button on its left ;
- The focus goes to the previously second tab, which becomes now the new first tab ;
- Notice that only half of the tab is visible now (the bug).
When the focus is on a tab other than the first one, then closing it moves the focus to another tab which is entirely displayed on the view.
The bug only applies when closing the first tab.
See the two attached screenshots.
Files
Yes, Android's TabView currently makes some interesting decisions about how to handle scrolling when some tabs are removed. This isn't anything I handle directly, and when I have tried to manually override the scroll position it has made it worse instead of better (the tools they have to control the scroll position are not very sophisticated). My current approach is just to let TabView do whatever it does naturally and let users scroll it back and forth if they want to.
Thanks for the explanation.
That's exactly my point. They don't want to provide an easy way for developers to control the tab scroll position. You have to use the methods inherited from android.view.View (like setScrollX()
).
Also available in: Atom
PDF