author | Matt Woodrow <mwoodrow@mozilla.com> |
Sun, 15 Apr 2018 16:38:45 +1200 | |
changeset 468709 | 070057638112fc3250567b9050748049d2e6fe75 |
parent 468708 | 4cc04fbbd1d7d6a4af9dbb0cbea52905cff3fef7 |
child 468710 | 5daa11905109206fd857f9589f60b57bfc3399b9 |
push id | 9165 |
push user | asasaki@mozilla.com |
push date | Thu, 26 Apr 2018 21:04:54 +0000 |
treeherder | mozilla-beta@064c3804de2e [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | miko |
bugs | 1452805 |
milestone | 61.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/layout/generic/nsFrame.cpp +++ b/layout/generic/nsFrame.cpp @@ -2916,16 +2916,22 @@ nsIFrame::BuildDisplayListForStackingCon nsDisplayTransform::UntransformRect(visibleRect, overflow, this, &visibleRect); } else { // This should only happen if the transform is singular, in which case nothing is visible anyway dirtyRect.SetEmpty(); visibleRect.SetEmpty(); } } inTransform = true; + } else if (IsFixedPosContainingBlock()) { + // Restict the building area to the overflow rect for these frames, since + // RetainedDisplayListBuilder uses it to know if the size of the stacking + // context changed. + visibleRect.IntersectRect(visibleRect, GetVisualOverflowRect()); + dirtyRect.IntersectRect(dirtyRect, GetVisualOverflowRect()); } bool hasOverrideDirtyRect = false; // If we have an override dirty region, and neither us nor our ancestors are // modified, then use it. if (HasOverrideDirtyRegion() && !aBuilder->InInvalidSubtree() && !IsFrameModified()) { nsDisplayListBuilder::DisplayListBuildingData* data = GetProperty(nsDisplayListBuilder::DisplayListBuildingRect());
new file mode 100644 --- /dev/null +++ b/layout/reftests/display-list/1452805-1.html @@ -0,0 +1,39 @@ +<html class="reftest-wait"> + <head> + <style> + div { + width: 200px; + height: 200px; + background-color: blue; + filter: greyscale(50%); + position: relative; + } + #second { + width: 600px; + height: 500px; + display: none; + background-color: green; + } + </style> + </head> + <body> + <div id="top" style="z-index:-4;"></div> + <div style="top: 10px;"></div> + <div style="top: 20px;"> + <div id="second" style="top: -400px;"></div> + </div> + + <script> + function doTest2() { + document.getElementById("second").style.display = "block"; + document.documentElement.removeAttribute("class"); + } + function doTest() { + document.getElementById("top").style.zIndex = -5; + setTimeout(doTest2, 500); + } + document.addEventListener("MozReftestInvalidate", doTest); + </script> + </body> +</html> +
new file mode 100644 --- /dev/null +++ b/layout/reftests/display-list/1452805-ref.html @@ -0,0 +1,26 @@ +<html> + <head> + <style> + div { + width: 200px; + height: 200px; + background-color: blue; + filter: greyscale(50%); + position: relative; + } + #second { + width: 600px; + height: 500px; + background-color: green; + } + </style> + </head> + <body> + <div id="top" style="z-index:-4;"></div> + <div style="top: 10px;"></div> + <div style="top: 20px;"> + <div id="second" style="top: -400px;"></div> + </div> + </body> +</html> +
--- a/layout/reftests/display-list/reftest.list +++ b/layout/reftests/display-list/reftest.list @@ -22,8 +22,9 @@ needs-focus == 1429027-1.html 1429027-1- == 1432553-2.html 1432553-2-ref.html == 1436189-1.html 1436189-1-ref.html skip-if(!asyncPan) == 1437374-1.html 1437374-1-ref.html == 1439809-1.html 1439809-1-ref.html == 1443027-1.html 1443027-ref.html == 1443027-2.html 1443027-ref.html == 1443027-3.html 1443027-3-ref.html == 1451971-1.html 1451971-ref.html +== 1452805-1.html 1452805-ref.html