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

Unified Diff: Source/core/frame/FrameView.cpp

Issue 212553004: [repaint-after-layout] Skip invalidations if our RenderView did a full invalidation. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase to master Created 6 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 3a1ec6409f82112ae332983736e9b0e71a77c387..b9df752249123de673a975e6be51d62d84905605 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -1037,7 +1037,17 @@ void FrameView::repaintTree(RenderObject* root)
// Until those states are fully fledged, I'll just disable the ASSERTS.
DisableCompositingQueryAsserts disabler;
+ bool renderViewDidFullInvalidation = false;
+
for (RenderObject* renderer = root; renderer; renderer = renderer->nextInPreOrder()) {
+ // If the RenderView did a full invalidation, and that's the view that we're part
+ // of, skip issuing invalidations for the RenderObject as it will be
+ // covered by the RenderView invalidation.
+ if (!renderer->hasLayer() && renderer != root && (renderer->view() == root) && renderViewDidFullInvalidation) {
Julien - ping for review 2014/03/27 22:37:26 I don't think we should check hasLayer() here as i
dsinclair 2014/03/28 18:35:26 Done.
+ renderer->clearRepaintState();
+ continue;
+ }
+
const LayoutRect& oldRepaintRect = renderer->oldRepaintRect();
const LayoutRect& newRepaintRect = renderer->newRepaintRect();
@@ -1048,6 +1058,9 @@ void FrameView::repaintTree(RenderObject* root)
renderer->setShouldDoFullRepaintAfterLayout(true);
}
+ if (renderer == root && root->isRenderView())
Julien - ping for review 2014/03/27 22:37:26 Note that this check will be run for each renderer
dsinclair 2014/03/28 18:35:26 Done.
+ renderViewDidFullInvalidation = renderer->shouldDoFullRepaintAfterLayout();
+
// FIXME: Currently renderers with layers will get repainted when we call updateLayerPositionsAfterLayout.
// That call should be broken apart to position the layers be done before
// the repaintTree call so this will repaint everything.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698