Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(59)

Unified Diff: third_party/WebKit/Source/core/layout/LayoutObject.cpp

Issue 2007003003: Check subtree paint invalidation when overflow clip status changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 b8823828a5cfdcaad8b691188080c8771f07d703..04086f7ad42b683b5f278f260ca90b4995a36b82 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -1313,6 +1313,10 @@ void LayoutObject::invalidateTreeIfNeeded(const PaintInvalidationState& paintInv
return;
PaintInvalidationState newPaintInvalidationState(paintInvalidationState, *this);
+
+ if (mayNeedPaintInvalidationSubtree())
+ newPaintInvalidationState.setForceSubtreeInvalidationCheckingWithinContainer();
+
PaintInvalidationReason reason = invalidatePaintIfNeeded(newPaintInvalidationState);
clearPaintInvalidationFlags(newPaintInvalidationState);
@@ -3454,6 +3458,14 @@ void LayoutObject::setMayNeedPaintInvalidation()
frameView()->scheduleVisualUpdateForPaintInvalidationIfNeeded();
}
+void LayoutObject::setMayNeedPaintInvalidationSubtree()
+{
+ if (mayNeedPaintInvalidationSubtree())
+ return;
+ m_bitfields.setMayNeedPaintInvalidationSubtree(true);
+ setMayNeedPaintInvalidation();
+}
+
void LayoutObject::clearPaintInvalidationFlags(const PaintInvalidationState& paintInvalidationState)
{
// paintInvalidationStateIsDirty should be kept in sync with the
@@ -3464,6 +3476,7 @@ void LayoutObject::clearPaintInvalidationFlags(const PaintInvalidationState& pai
m_bitfields.setNeededLayoutBecauseOfChildren(false);
m_bitfields.setShouldInvalidateOverflowForPaint(false);
m_bitfields.setMayNeedPaintInvalidation(false);
+ m_bitfields.setMayNeedPaintInvalidationSubtree(false);
m_bitfields.setShouldInvalidateSelection(false);
}
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutObject.h ('k') | third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698