mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 858803. Fix coordinate system of subdocument frame bounds. r=mattwoodrow
--HG-- extra : rebase_source : 3fd0436f141542dcf50f318a47670329c9c7a814
This commit is contained in:
parent
e21f85a30b
commit
a7bc9f4f3c
@ -415,12 +415,10 @@ nsSubDocumentFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
||||
// it need to have underlying frames from the subdocument. So we need to
|
||||
// calculate the bounds based on which frame will be the underlying frame
|
||||
// for the canvas background color item.
|
||||
nsRect bounds;
|
||||
nsRect subdocBoundsInParentUnits = GetContentRectRelativeToSelf();
|
||||
nsRect bounds = GetContentRectRelativeToSelf() +
|
||||
aBuilder->ToReferenceFrame(this);
|
||||
if (subdocRootFrame) {
|
||||
bounds = subdocBoundsInParentUnits.ConvertAppUnitsRoundOut(parentAPD, subdocAPD);
|
||||
} else {
|
||||
bounds = subdocBoundsInParentUnits;
|
||||
bounds = bounds.ConvertAppUnitsRoundOut(parentAPD, subdocAPD);
|
||||
}
|
||||
|
||||
// If we are in print preview/page layout we want to paint the grey
|
||||
|
6
layout/reftests/bugs/858803-1-ref.html
Normal file
6
layout/reftests/bugs/858803-1-ref.html
Normal file
@ -0,0 +1,6 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<body>
|
||||
<div style="position:absolute; left:100px; top:100px; width:300px; height:300px; border:1px solid black; background:yellow"></div>
|
||||
</body>
|
||||
</html>
|
8
layout/reftests/bugs/858803-1.html
Normal file
8
layout/reftests/bugs/858803-1.html
Normal file
@ -0,0 +1,8 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<body>
|
||||
<iframe src="data:application/vnd.mozilla.xul+xml,<?xml version='1.0' encoding='UTF-8'?><window xmlns='http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul' style='background:yellow'></window>"
|
||||
style="position:absolute; left:100px; top:100px; width:300px; height:300px; border:1px solid black;">
|
||||
</iframe>
|
||||
</body>
|
||||
</html>
|
@ -1753,3 +1753,4 @@ skip-if(B2G) == 818276-1.html 818276-1-ref.html
|
||||
== 847850-1.html 847850-1-ref.html
|
||||
== 848421-1.html 848421-1-ref.html
|
||||
test-pref(layout.css.flexbox.enabled,true) == 849407-1.html 849407-1-ref.html
|
||||
== 858803-1.html 858803-1-ref.html
|
||||
|
Loading…
Reference in New Issue
Block a user