| Index: Source/core/rendering/RenderBox.cpp
|
| diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp
|
| index 600a7954cecdc614da9443a9c6067e59007e865f..967df24d0c5be4979db3b014384a3ea22c4868fe 100644
|
| --- a/Source/core/rendering/RenderBox.cpp
|
| +++ b/Source/core/rendering/RenderBox.cpp
|
| @@ -153,10 +153,10 @@ void RenderBox::styleWillChange(StyleDifference diff, const RenderStyle& newStyl
|
| if (oldStyle) {
|
| // The background of the root element or the body element could propagate up to
|
| // the canvas. Just dirty the entire canvas when our style changes substantially.
|
| - if (diff >= StyleDifferenceRepaint && node() &&
|
| - (isHTMLHtmlElement(*node()) || isHTMLBodyElement(*node()))) {
|
| + if (diff.needsRepaint() && node()
|
| + && (isHTMLHtmlElement(*node()) || isHTMLBodyElement(*node()))) {
|
|
|
| - if (!RuntimeEnabledFeatures::repaintAfterLayoutEnabled() || diff != StyleDifferenceLayout)
|
| + if (!RuntimeEnabledFeatures::repaintAfterLayoutEnabled() || !diff.needsFullLayout())
|
| view()->repaint();
|
|
|
| if (oldStyle->hasEntirelyFixedBackground() != newStyle.hasEntirelyFixedBackground())
|
| @@ -165,7 +165,7 @@ void RenderBox::styleWillChange(StyleDifference diff, const RenderStyle& newStyl
|
|
|
| // When a layout hint happens and an object's position style changes, we have to do a layout
|
| // to dirty the render tree using the old position value now.
|
| - if (diff == StyleDifferenceLayout && parent() && oldStyle->position() != newStyle.position()) {
|
| + if (diff.needsFullLayout() && parent() && oldStyle->position() != newStyle.position()) {
|
| markContainingBlocksForLayout();
|
| if (oldStyle->position() == StaticPosition)
|
| repaint();
|
| @@ -221,7 +221,7 @@ void RenderBox::styleDidChange(StyleDifference diff, const RenderStyle* oldStyle
|
| }
|
|
|
| // Our opaqueness might have changed without triggering layout.
|
| - if (diff == StyleDifferenceRepaint || diff == StyleDifferenceRepaintLayer) {
|
| + if (diff.needsRepaint()) {
|
| RenderObject* parentToInvalidate = parent();
|
| for (unsigned i = 0; i < backgroundObscurationTestMaxDepth && parentToInvalidate; ++i) {
|
| parentToInvalidate->invalidateBackgroundObscurationStatus();
|
|
|