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

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

Issue 566433002: Don't clip invalidation of composited scrolling contents (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 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: Source/core/rendering/PaintInvalidationState.cpp
===================================================================
--- Source/core/rendering/PaintInvalidationState.cpp (revision 181869)
+++ Source/core/rendering/PaintInvalidationState.cpp (working copy)
@@ -87,13 +87,21 @@
return;
const RenderBox& box = toRenderBox(renderer);
- LayoutRect clipRect(toPoint(m_paintOffset), box.layer()->size());
- if (m_clipped) {
- m_clipRect.intersect(clipRect);
+
+ // Do not clip scroll layer contents because the compositor expects the whole layer
+ // to be always invalidated in-time.
+ if (box.usesCompositedScrolling()) {
+ ASSERT(!m_clipped); // The box should establish paint invalidation container, so no m_clipped inherited.
} else {
- m_clipRect = clipRect;
- m_clipped = true;
+ LayoutRect clipRect(toPoint(m_paintOffset), box.layer()->size());
+ if (m_clipped) {
+ m_clipRect.intersect(clipRect);
+ } else {
+ m_clipRect = clipRect;
+ m_clipped = true;
+ }
}
+
m_paintOffset -= box.scrolledContentOffset();
}

Powered by Google App Engine
This is Rietveld 408576698