mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-26 11:45:37 +00:00
57368ff4e7
This fixes an incremental layout bug, where the number of times we reflow the frame affects its layout. This is because we make the decisions about the vertical scrollbar before the horizontal scrollbar (and, when making the decision, adjust mHelper.mScrollPort for the size of the scrollbar). Thus, in order to avoid a situation where reflowing the scrollframe once leads us to have no vertical scrollbar, but reflowing it a second time leads us to add that scrollbar, we need to retest for the need for a vertical scrollbar after we add the horizontal one. (It's possible there are some other missing cases here, but this is the one that (a) already existed in the code and (b) is needed to fix the reftest failure on Windows that I got on bug 1308876, in layout/reftests/text-overflow/xulscroll.html . The reftest here shows the bug even without bug 1308876 (though I confirmed that only by loading the test and reference in a nightly build, not in the reftest harness). I did test that, in combination with bug 1308876, the test fails without the patch and passes with the patch. MozReview-Commit-ID: LhMi7LbmB6J
28 lines
377 B
HTML
28 lines
377 B
HTML
<!DOCTYPE HTML>
|
|
<title>XUL scrollbar testcase</title>
|
|
<style>
|
|
|
|
html { overflow: hidden }
|
|
|
|
div.outer {
|
|
display: -moz-box;
|
|
overflow: scroll;
|
|
width: 200px;
|
|
height: 100px;
|
|
background: yellow;
|
|
}
|
|
|
|
div.inner {
|
|
width: 300px;
|
|
height: 100px;
|
|
min-width: 300px;
|
|
min-height: 100px;
|
|
background: aqua;
|
|
}
|
|
</style>
|
|
|
|
<div class="outer">
|
|
<div class="inner">
|
|
</div>
|
|
</div>
|