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

Unified Diff: Source/core/rendering/RenderObject.cpp

Issue 714083003: Revert "Move some scroll invalidations to the paint invalidation phase" (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month 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: Source/core/rendering/RenderObject.cpp
diff --git a/Source/core/rendering/RenderObject.cpp b/Source/core/rendering/RenderObject.cpp
index 62447b830be9fe0fd91d38a5bd5bdad7bbbfab2c..6e9ef607248ebb712d07200cb038c2ebfab60954 100644
--- a/Source/core/rendering/RenderObject.cpp
+++ b/Source/core/rendering/RenderObject.cpp
@@ -3159,6 +3159,21 @@ void RenderObject::invalidatePaintIncludingNonCompositingDescendantsInternal(con
}
}
+void forceRecomputePaintInvalidationRectsIncludingNonCompositingDescendants(RenderObject* renderer)
+{
+ // We clear the previous paint invalidation rect as it's wrong (paint invaliation container
+ // changed, ...). Forcing a full invalidation will make us recompute it. Also we are not
+ // changing the previous position from our paint invalidation container, which is fine as
+ // we want a full paint invalidation anyway.
+ renderer->setPreviousPaintInvalidationRect(LayoutRect());
+ renderer->setShouldDoFullPaintInvalidation();
+
+ for (RenderObject* child = renderer->slowFirstChild(); child; child = child->nextSibling()) {
+ if (!child->isPaintInvalidationContainer())
+ forceRecomputePaintInvalidationRectsIncludingNonCompositingDescendants(child);
+ }
+}
+
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698