| Index: third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
| diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.cpp b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
| index 3643e94629c4bbd3e1a0d650abd090703f3602ee..2acbb0cb68a03822fe421b205ab54e46187a1e3b 100644
|
| --- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
| +++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
| @@ -1341,10 +1341,8 @@ void LayoutObject::invalidateTreeIfNeeded(const PaintInvalidationState& paintInv
|
|
|
| void LayoutObject::invalidatePaintOfSubtreesIfNeeded(const PaintInvalidationState& childPaintInvalidationState)
|
| {
|
| - for (LayoutObject* child = slowFirstChild(); child; child = child->nextSibling()) {
|
| - if (!child->isOutOfFlowPositioned())
|
| - child->invalidateTreeIfNeeded(childPaintInvalidationState);
|
| - }
|
| + for (LayoutObject* child = slowFirstChild(); child; child = child->nextSibling())
|
| + child->invalidateTreeIfNeeded(childPaintInvalidationState);
|
| }
|
|
|
| static PassOwnPtr<TracedValue> jsonObjectForOldAndNewRects(const LayoutRect& oldRect, const LayoutPoint& oldLocation, const LayoutRect& newRect, const LayoutPoint& newLocation)
|
| @@ -1435,8 +1433,7 @@ PaintInvalidationReason LayoutObject::invalidatePaintIfNeeded(const PaintInvalid
|
| return PaintInvalidationNone; // Don't invalidate paints if we're printing.
|
|
|
| const LayoutBoxModelObject& paintInvalidationContainer = paintInvalidationState.paintInvalidationContainer();
|
| - // TODO(wangxianzhu): Enable this assert after we fix all paintInvalidationContainer mismatch issues. crbug.com/360286
|
| - // ASSERT(paintInvalidationContainer == containerForPaintInvalidation());
|
| + ASSERT(paintInvalidationContainer == containerForPaintInvalidation());
|
|
|
| const LayoutRect oldBounds = previousPaintInvalidationRect();
|
| const LayoutPoint oldLocation = RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled() ? LayoutPoint() : previousPositionFromPaintInvalidationBacking();
|
| @@ -2620,9 +2617,9 @@ LayoutObject* LayoutObject::container(const LayoutBoxModelObject* ancestor, bool
|
| return o;
|
| }
|
|
|
| -LayoutObject* LayoutObject::containerCrossingFrameBoundaries() const
|
| +LayoutObject* LayoutObject::parentCrossingFrameBoundaries() const
|
| {
|
| - return isLayoutView() ? frame()->ownerLayoutObject() : container();
|
| + return isLayoutView() ? frame()->ownerLayoutObject() : parent();
|
| }
|
|
|
| bool LayoutObject::isSelectionBorder() const
|
| @@ -3421,9 +3418,9 @@ static PaintInvalidationReason documentLifecycleBasedPaintInvalidationReason(con
|
| }
|
| }
|
|
|
| -inline void LayoutObject::markContainerChainForPaintInvalidation()
|
| +inline void LayoutObject::markAncestorsForPaintInvalidation()
|
| {
|
| - for (LayoutObject* container = this->containerCrossingFrameBoundaries(); container && !container->shouldCheckForPaintInvalidationRegardlessOfPaintInvalidationState(); container = container->containerCrossingFrameBoundaries())
|
| + for (LayoutObject* container = this->parentCrossingFrameBoundaries(); container && !container->shouldCheckForPaintInvalidationRegardlessOfPaintInvalidationState(); container = container->parentCrossingFrameBoundaries())
|
| container->m_bitfields.setChildShouldCheckForPaintInvalidation(true);
|
| }
|
|
|
| @@ -3432,7 +3429,7 @@ void LayoutObject::setShouldInvalidateSelection()
|
| if (!canUpdateSelectionOnRootLineBoxes())
|
| return;
|
| m_bitfields.setShouldInvalidateSelection(true);
|
| - markContainerChainForPaintInvalidation();
|
| + markAncestorsForPaintInvalidation();
|
| frameView()->scheduleVisualUpdateForPaintInvalidationIfNeeded();
|
| }
|
|
|
| @@ -3448,7 +3445,7 @@ void LayoutObject::setShouldDoFullPaintInvalidation(PaintInvalidationReason reas
|
| reason = documentLifecycleBasedPaintInvalidationReason(document().lifecycle());
|
| m_bitfields.setFullPaintInvalidationReason(reason);
|
| if (!isUpgradingDelayedFullToFull)
|
| - markContainerChainForPaintInvalidation();
|
| + markAncestorsForPaintInvalidation();
|
| }
|
|
|
| frameView()->scheduleVisualUpdateForPaintInvalidationIfNeeded();
|
| @@ -3459,7 +3456,7 @@ void LayoutObject::setMayNeedPaintInvalidation()
|
| if (mayNeedPaintInvalidation())
|
| return;
|
| m_bitfields.setMayNeedPaintInvalidation(true);
|
| - markContainerChainForPaintInvalidation();
|
| + markAncestorsForPaintInvalidation();
|
| frameView()->scheduleVisualUpdateForPaintInvalidationIfNeeded();
|
| }
|
|
|
|
|