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

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

Issue 271803002: [RAL] Fix nested non-composited RenderView repainting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Proposed fix Created 6 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
« Source/core/rendering/RenderBox.cpp ('K') | « Source/core/rendering/RenderView.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderView.cpp
diff --git a/Source/core/rendering/RenderView.cpp b/Source/core/rendering/RenderView.cpp
index ef34168d5c4cd1d7ea98613e72378c50f26b5f1e..0c909cf8b937a27ee5603028337a1f0d45557cde 100644
--- a/Source/core/rendering/RenderView.cpp
+++ b/Source/core/rendering/RenderView.cpp
@@ -438,6 +438,19 @@ void RenderView::paintBoxDecorations(PaintInfo& paintInfo, const LayoutPoint&)
}
}
+void RenderView::repaintTreeAfterLayout(const RenderLayerModelObject& repaintContainer)
Julien - ping for review 2014/05/30 02:39:32 This code path seems very artificial to me as I wo
leviw_travelin_and_unemployed 2014/05/30 15:52:57 I'm not sure I understand what the "artificial" pa
dsinclair 2014/06/02 00:38:29 That code path is never hit in RAL. I don't necess
Julien - ping for review 2014/06/02 23:21:19 It's not hit by RAL because we made it so, not bec
+{
+ ASSERT(RuntimeEnabledFeatures::repaintAfterLayoutEnabled());
+ ASSERT(!needsLayout());
+
+ // We specifically need to repaint the viewRect since other renderers
+ // short-circuit on full-repaint.
+ if (doingFullRepaint() && !viewRect().isEmpty())
+ repaintViewRectangle(viewRect());
+
+ RenderBlock::repaintTreeAfterLayout(repaintContainer);
+}
+
void RenderView::repaintViewRectangle(const LayoutRect& ur) const
{
ASSERT(!ur.isEmpty());
@@ -448,9 +461,12 @@ void RenderView::repaintViewRectangle(const LayoutRect& ur) const
// We always just invalidate the root view, since we could be an iframe that is clipped out
// or even invisible.
Element* elt = document().ownerElement();
- if (!elt)
- m_frameView->repaintContentRectangle(pixelSnappedIntRect(ur));
- else if (RenderBox* obj = elt->renderBox()) {
+ if (!elt) {
+ if (hasLayer() && layer()->compositingState() == PaintsIntoOwnBacking)
+ layer()->repainter().setBackingNeedsRepaintInRect(ur);
+ else
+ m_frameView->repaintContentRectangle(pixelSnappedIntRect(ur));
+ } else if (RenderBox* obj = elt->renderBox()) {
LayoutRect vr = viewRect();
LayoutRect r = intersection(ur, vr);
« Source/core/rendering/RenderBox.cpp ('K') | « Source/core/rendering/RenderView.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698