Closed
Bug 301439
Opened 21 years ago
Closed 21 years ago
Listbox isn't scrolled to the right position when going back in history
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
People
(Reporter: martijn.martijn, Assigned: roc)
References
()
Details
(Keywords: regression, testcase)
Attachments
(4 files)
|
2.52 KB,
text/html
|
Details | |
|
2.51 KB,
text/html
|
Details | |
|
1.91 KB,
text/html
|
Details | |
|
10.33 KB,
patch
|
dbaron
:
review+
dbaron
:
superreview+
benjamin
:
approval1.8b4+
|
Details | Diff | Splinter Review |
To reproduce:
- Go to url
- Scoll listbox of 'Product', select 'Core'
- Scroll listbox of 'Component', select 'Layout'
- In the search input box, type: 'scroll position'
- Begin the search.
- After the search page has loaded, go back.
Result:
'Product' listbox is not scrolled to the position before the search.
This used to work at least in Mozilla1.7.
| Reporter | ||
Comment 1•21 years ago
|
||
Removing the align="left" from the table cell in this testcase seems to fix the
bug.
| Reporter | ||
Comment 2•21 years ago
|
||
Ok, this regressed between 2005-06-15 and 2005-06-17:
http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2005-06-15+05%3A00%3A00&maxdate=2005-06-17+10%3A00%3A00&cvsroot=%2Fcvsroot
Maybe because of the checkin in this period of bug 290428?
| Reporter | ||
Comment 3•21 years ago
|
||
I forgot to say, this can only be seen with bfcache turned off.
Comment 4•21 years ago
|
||
This is actually broken in 2005-06-16-06 builds too. So the bonsai range is
http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2005-06-15+05%3A00%3A00&maxdate=2005-06-16+07%3A00%3A00&cvsroot=%2Fcvsroot
Possible causes: bug 296337, bug 64510.
I see this on Linux too.
Flags: blocking1.8b4?
OS: Windows 2000 → All
Hardware: PC → All
| Assignee | ||
Comment 5•21 years ago
|
||
I'm guessing 64510 based on the align="left".
Did it happen with align="right" before that checkin?
| Reporter | ||
Comment 7•21 years ago
|
||
> Did it happen with align="right" before that checkin?
Yes, the regression period for that is between 2004-09-11 and 2004-09-13:
http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2004-09-11+08%3A00%3A00&maxdate=2004-09-13+10%3A00%3A00&cvsroot=%2Fcvsroot
Possibly a regression from bug 257916?
| Assignee | ||
Comment 8•21 years ago
|
||
This testcase shows the underlying problem: if you scroll down the list and
then resize the window, we jump back up to the top.
The problem is that listboxes do two-pass reflow. In the first pass, the
computed height is explicitly set to unconstrained. This means the scrollframe
expands to its intrinsic height, notices that the vertical scrollbar is no
longer needed, and sets the scrollbar's maxheight to zero, which forces the
current position to also be zero.
Assignee: nobody → roc
Status: NEW → ASSIGNED
| Assignee | ||
Comment 9•21 years ago
|
||
This fixes the bug by telling the scrollframe that we will do a second pass and
it should not adjust scrollbar layout yet.
I'm a bit worried that something similar could happen to overflow:auto blocks
in tables, where a speculative unconstrained-width reflow could cause the block
to fit all in one line, scrolling it to the top. But I can't make that happen
in a testcase.
I'm surprised this bug hasn't been noticed before!
Attachment #190067 -
Flags: superreview?(dbaron)
Attachment #190067 -
Flags: review?(dbaron)
Updated•21 years ago
|
Flags: blocking1.8b4? → blocking1.8b4+
Attachment #190067 -
Flags: superreview?(dbaron)
Attachment #190067 -
Flags: superreview+
Attachment #190067 -
Flags: review?(dbaron)
Attachment #190067 -
Flags: review+
| Assignee | ||
Comment 10•21 years ago
|
||
Comment on attachment 190067 [details] [diff] [review]
fix
need approval for this history bug (blocker)
Attachment #190067 -
Flags: approval1.8b4?
Updated•21 years ago
|
Attachment #190067 -
Flags: approval1.8b4? → approval1.8b4+
| Assignee | ||
Comment 11•21 years ago
|
||
checked in
Status: ASSIGNED → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
| Assignee | ||
Comment 12•21 years ago
|
||
Surprisingly, it looks like this reduced Tp on btek a bit.
| Assignee | ||
Comment 13•21 years ago
|
||
That suggests it might be worth trying to suppress scrollbar reflow in combobox
dropdowns until the dropdown is shown.
Actually post-reflow-refactor, we might be able to entirely suppress reflow of
the combobox dropdown until it's shown. I've always thought it would be nice to
suppress the creation of the popup widget until then too.
You need to log in
before you can comment on or make changes to this bug.
Description
•