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

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

Issue 318793002: When performing a fast-path scroll, issue repaints for viewport-constrained layers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Merged. Created 6 years, 6 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 | « LayoutTests/compositing/repaint/fixed-pos-inside-composited-intermediate-layer-expected.txt ('k') | 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 69e42ef47414032d9ece4f360069cc4aa9996db5..0a043b360750f4097852dc8cbf5a87af31cbe8e0 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -1419,8 +1419,8 @@ bool FrameView::scrollContentsFastPath(const IntSize& scrollDelta, const IntRect
IntRect updateRect = pixelSnappedIntRect(layer->repainter().repaintRectIncludingNonCompositingDescendants());
- RenderLayer* enclosingCompositingLayer = layer->enclosingCompositingLayer(ExcludeSelf);
- if (enclosingCompositingLayer && !enclosingCompositingLayer->renderer()->isRenderView()) {
+ const RenderLayerModelObject* repaintContainer = layer->renderer()->containerForRepaint();
+ if (repaintContainer && !repaintContainer->isRenderView()) {
// If the fixed-position layer is contained by a composited layer that is not its containing block,
// then we have to invalidate that enclosing layer, not the RenderView.
// FIXME: Why do we need to issue this invalidation? Won't the fixed position element just scroll
@@ -1429,7 +1429,7 @@ bool FrameView::scrollContentsFastPath(const IntSize& scrollDelta, const IntRect
IntRect previousRect = updateRect;
previousRect.move(scrollDelta);
updateRect.unite(previousRect);
- enclosingCompositingLayer->repainter().setBackingNeedsRepaintInRect(updateRect);
+ layer->renderer()->repaintUsingContainer(repaintContainer, updateRect, InvalidationScroll);
} else {
// Coalesce the paint invalidations that will be issued to the renderView.
updateRect = contentsToRootView(updateRect);
« no previous file with comments | « LayoutTests/compositing/repaint/fixed-pos-inside-composited-intermediate-layer-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698