mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 06:11:37 +00:00
Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. r=dbaron
MozReview-Commit-ID: JQGb41kp76P --HG-- extra : rebase_source : f9105e949f8fa02697a94718ea69742ac115f8e6
This commit is contained in:
parent
36993c4e93
commit
7391f4b580
16
layout/base/crashtests/1467688.html
Normal file
16
layout/base/crashtests/1467688.html
Normal file
@ -0,0 +1,16 @@
|
||||
<html class="reftest-wait">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
<body style="transform:translate(4px)">
|
||||
<div id="invalid" style="width:100px; height:100px; background-color:red;"></div>
|
||||
<script>
|
||||
function doTest() {
|
||||
document.documentElement.style.perspective = '100px';
|
||||
document.getElementById("invalid").style.backgroundColor = "green";
|
||||
document.documentElement.removeAttribute("class");
|
||||
}
|
||||
window.addEventListener("MozReftestInvalidate", doTest);
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
@ -544,5 +544,6 @@ load 1462412.html
|
||||
load 1463940.html
|
||||
pref(dom.webcomponents.shadowdom.enabled,true) HTTP load 1464641.html
|
||||
load 1464737.html
|
||||
load 1467688.html
|
||||
load 1467964.html
|
||||
load 1469354.html
|
||||
|
@ -3863,13 +3863,7 @@ nsStyleDisplay::CalcDifference(const nsStyleDisplay& aNewData) const
|
||||
}
|
||||
}
|
||||
|
||||
if (HasPerspectiveStyle() != aNewData.HasPerspectiveStyle()) {
|
||||
// A change from/to being a containing block for position:fixed.
|
||||
hint |= nsChangeHint_UpdateContainingBlock;
|
||||
}
|
||||
|
||||
if (mChildPerspective != aNewData.mChildPerspective ||
|
||||
mTransformStyle != aNewData.mTransformStyle ||
|
||||
if (mTransformStyle != aNewData.mTransformStyle ||
|
||||
mTransformBox != aNewData.mTransformBox) {
|
||||
transformHint |= kUpdateOverflowAndRepaintHint;
|
||||
}
|
||||
@ -3887,6 +3881,16 @@ nsStyleDisplay::CalcDifference(const nsStyleDisplay& aNewData) const
|
||||
}
|
||||
}
|
||||
|
||||
if (HasPerspectiveStyle() != aNewData.HasPerspectiveStyle()) {
|
||||
// A change from/to being a containing block for position:fixed.
|
||||
hint |= nsChangeHint_UpdateContainingBlock |
|
||||
nsChangeHint_UpdateOverflow |
|
||||
nsChangeHint_RepaintFrame;
|
||||
} else if (mChildPerspective != aNewData.mChildPerspective) {
|
||||
hint |= nsChangeHint_UpdateOverflow |
|
||||
nsChangeHint_RepaintFrame;
|
||||
}
|
||||
|
||||
// Note that the HasTransformStyle() != aNewData.HasTransformStyle()
|
||||
// test above handles relevant changes in the
|
||||
// NS_STYLE_WILL_CHANGE_TRANSFORM bit, which in turn handles frame
|
||||
|
Loading…
Reference in New Issue
Block a user