mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 526394. Part 36: Store the overflow area explicitly whenever it's not exactly equal to the border-box; if they're both empty but with different dimensions or position, we should still store the explicit overflow area. Also fix test_offsets to compute the expected scrolled area correctly. r=mats
This commit is contained in:
parent
8d3cbbd5d2
commit
68f4784a75
@ -51,9 +51,10 @@ function testElement(element)
|
||||
var scrollWidth, scrollHeight, clientWidth, clientHeight;
|
||||
if (element.id == "scrollbox") {
|
||||
var lastchild = $("lastline");
|
||||
scrollWidth = Math.round(lastchild.getBoundingClientRect().width) + paddingLeft + paddingRight;
|
||||
scrollHeight = Math.round(element.lastChild.getBoundingClientRect().bottom) -
|
||||
Math.round(element.firstChild.getBoundingClientRect().top) + paddingTop + paddingBottom;
|
||||
scrollWidth = Math.floor(lastchild.getBoundingClientRect().width) + paddingLeft + paddingRight;
|
||||
var contentsHeight = element.lastChild.getBoundingClientRect().bottom -
|
||||
element.firstChild.getBoundingClientRect().top;
|
||||
scrollHeight = Math.floor(contentsHeight) + paddingTop + paddingBottom;
|
||||
clientWidth = paddingLeft + width + paddingRight - scrollbarWidth;
|
||||
clientHeight = paddingTop + height + paddingBottom - scrollbarHeight;
|
||||
}
|
||||
|
@ -5589,7 +5589,7 @@ nsIFrame::FinishAndStoreOverflow(nsRect* aOverflowArea, nsSize aNewSize)
|
||||
if (presContext->GetTheme()->
|
||||
GetWidgetOverflow(presContext->DeviceContext(), this,
|
||||
disp->mAppearance, &r)) {
|
||||
aOverflowArea->UnionRect(*aOverflowArea, r);
|
||||
aOverflowArea->UnionRectIncludeEmpty(*aOverflowArea, r);
|
||||
}
|
||||
}
|
||||
|
||||
@ -5633,8 +5633,8 @@ nsIFrame::FinishAndStoreOverflow(nsRect* aOverflowArea, nsSize aNewSize)
|
||||
}
|
||||
|
||||
PRBool overflowChanged;
|
||||
if (*aOverflowArea != nsRect(nsPoint(0, 0), aNewSize)) {
|
||||
overflowChanged = *aOverflowArea != GetOverflowRect();
|
||||
if (!aOverflowArea->IsExactEqual(nsRect(nsPoint(0, 0), aNewSize))) {
|
||||
overflowChanged = !aOverflowArea->IsExactEqual(GetOverflowRect());
|
||||
SetOverflowRect(*aOverflowArea);
|
||||
}
|
||||
else {
|
||||
|
Loading…
Reference in New Issue
Block a user