forked from mirrors/gecko-dev
Bug 1799425. Only set checkboard flag when adding background color item for root content document. r=emilio
Webrender uses this flag as a hint to separate mix blend containers so it should only be present on the root content document. Differential Revision: https://phabricator.services.mozilla.com/D162046
This commit is contained in:
parent
9c44d165bb
commit
1358ce8ff1
5 changed files with 50 additions and 4 deletions
|
|
@ -5428,7 +5428,8 @@ void PresShell::AddCanvasBackgroundColorItem(
|
|||
if (!addedScrollingBackgroundColor || forceUnscrolledItem) {
|
||||
nsDisplaySolidColor* item = MakeDisplayItem<nsDisplaySolidColor>(
|
||||
aBuilder, aFrame, aBounds, bgcolor);
|
||||
if (addedScrollingBackgroundColor) {
|
||||
if (addedScrollingBackgroundColor &&
|
||||
mPresContext->IsRootContentDocumentCrossProcess()) {
|
||||
item->SetIsCheckerboardBackground();
|
||||
}
|
||||
AddDisplayItemToBottom(aBuilder, aList, item);
|
||||
|
|
|
|||
21
layout/reftests/bugs/1799425-1-ref.html
Normal file
21
layout/reftests/bugs/1799425-1-ref.html
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
<style>
|
||||
body,
|
||||
html {
|
||||
background-color: white;
|
||||
}
|
||||
.wrapper {
|
||||
mix-blend-mode: difference;
|
||||
}
|
||||
.text {
|
||||
color: white;
|
||||
}
|
||||
</style>
|
||||
<div class="wrapper">
|
||||
<div class="text">This text should always be black
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="video">
|
||||
<div>Hover here to make video disappear</div>
|
||||
<iframe srcdoc="<div style='width: 100px; height: 100px; background: blue;'></div>">
|
||||
</div>
|
||||
26
layout/reftests/bugs/1799425-1.html
Normal file
26
layout/reftests/bugs/1799425-1.html
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
<style>
|
||||
body,
|
||||
html {
|
||||
background-color: white;
|
||||
}
|
||||
.wrapper {
|
||||
mix-blend-mode: difference;
|
||||
}
|
||||
.text {
|
||||
color: white;
|
||||
}
|
||||
</style>
|
||||
<div class="wrapper">
|
||||
<div class="text">This text should always be black
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="video">
|
||||
<div>Hover here to make video disappear</div>
|
||||
<iframe srcdoc="<style>
|
||||
html, body {
|
||||
background: white;
|
||||
}
|
||||
</style>
|
||||
<div style='width: 100px; height: 100px; background: blue;'></div>">
|
||||
</div>
|
||||
|
|
@ -2132,4 +2132,5 @@ pref(layout.css.prefers-color-scheme.content-override,2) == 1787127.html 1787127
|
|||
== 1792643-1.html 1792643-1-ref.html
|
||||
skip-if(!/^Windows\x20NT\x2010\.0/.test(http.oscpu)) == 1798297-1.html 1798297-1-ref.html
|
||||
skip-if(!/^Windows\x20NT\x2010\.0/.test(http.oscpu)) != 1798297-1.html 1798297-1-notref.html
|
||||
== 1799425-1.html 1799425-1-ref.html
|
||||
== 1800437-1.html 1800437-1-ref.html
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
[root-canvas-001.xht]
|
||||
fuzzy:
|
||||
if os == "win": maxDifference=91-93;totalPixels=2250-2300
|
||||
Loading…
Reference in a new issue