зеркало из https://github.com/mozilla/pjs.git
Bug 545049. When the overflow area of a transformed frame changes, we need to repaint the whole thing. r=mats
This commit is contained in:
Родитель
7218dc5fcd
Коммит
ce2015a790
|
@ -5662,8 +5662,10 @@ nsIFrame::FinishAndStoreOverflow(nsRect* aOverflowArea, nsSize aNewSize)
|
|||
&hasOutlineOrEffects);
|
||||
|
||||
/* If we're transformed, transform the overflow rect by the current transformation. */
|
||||
if ((mState & NS_FRAME_MAY_BE_TRANSFORMED_OR_HAVE_RENDERING_OBSERVERS) &&
|
||||
GetStyleDisplay()->HasTransform()) {
|
||||
PRBool hasTransform =
|
||||
(mState & NS_FRAME_MAY_BE_TRANSFORMED_OR_HAVE_RENDERING_OBSERVERS) &&
|
||||
GetStyleDisplay()->HasTransform();
|
||||
if (hasTransform) {
|
||||
/* Since our size might not actually have been computed yet, we need to make sure that we use the
|
||||
* correct dimensions by overriding the stored bounding rectangle with the value the caller has
|
||||
* ensured us we'll use.
|
||||
|
@ -5687,10 +5689,10 @@ nsIFrame::FinishAndStoreOverflow(nsRect* aOverflowArea, nsSize aNewSize)
|
|||
}
|
||||
}
|
||||
|
||||
if (overflowChanged && hasOutlineOrEffects) {
|
||||
// When there's an outline or box-shadow or SVG effects, changes to
|
||||
// those styles might require repainting of the old and new overflow
|
||||
// areas. Repainting of the old overflow area is handled in
|
||||
if (overflowChanged && (hasOutlineOrEffects || hasTransform)) {
|
||||
// When there's an outline or box-shadow or SVG effects or transform,
|
||||
// changes to those styles might require repainting of the old and new
|
||||
// overflow areas. Repainting of the old overflow area is handled in
|
||||
// nsCSSFrameConstructor::DoApplyRenderingChangeToTree in response
|
||||
// to nsChangeHint_RepaintFrame. Since the new overflow area is not
|
||||
// known at that time, we have to handle it here.
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<body>
|
||||
<table>
|
||||
<td style="-moz-transform:translateX(10px); width:20px; height:20px; background:lime;">
|
||||
</td>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,16 @@
|
|||
<!DOCTYPE HTML>
|
||||
<html class="reftest-wait">
|
||||
<body>
|
||||
<table>
|
||||
<td id="d" style="-moz-transform:translateX(400px); width:20px; height:20px; background:lime;">
|
||||
</td>
|
||||
</table>
|
||||
<script>
|
||||
function doTest() {
|
||||
document.getElementById("d").style.MozTransform = "translateX(10px)";
|
||||
document.documentElement.removeAttribute("class");
|
||||
}
|
||||
window.addEventListener("MozReftestInvalidate", doTest, false);
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -1408,10 +1408,11 @@ fails HTTP(..) == 518172-2b.html 518172-b-ref.html # bug 518172
|
|||
== 539323-1.html 539323-1-ref.html
|
||||
== 539323-2.html 539323-2-ref.html
|
||||
== 539323-3.html 539323-3-ref.html
|
||||
== 542620-1.html 542620-1-ref.html
|
||||
== 541382-1.html 541382-1-ref.html
|
||||
random-if(!haveTestPlugin) == 541406-1.html 541406-1-ref.html
|
||||
== 542620-1.html 542620-1-ref.html
|
||||
== 545049-1.html 545049-1-ref.html
|
||||
== 546033-1.html 546033-1-ref.html
|
||||
== 550716-1.html 550716-1-ref.html
|
||||
== 549184-1.html 549184-1-ref.html
|
||||
random-if(!haveTestPlugin) == 546071-1.html 546071-1-ref.html
|
||||
== 549184-1.html 549184-1-ref.html
|
||||
== 550716-1.html 550716-1-ref.html
|
||||
|
|
Загрузка…
Ссылка в новой задаче