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

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: Fix. 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 4b5e2eda8e9f66024f1aecb789beed729c4e07be..77965e1ab35e9d7ebf3f0fe8ce2e025082105183 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()) {
ojan 2014/06/04 20:07:29 Can we really get a null repaintContainer here? It
chrishtr 2014/06/04 20:11:41 Yes it can happen. crbug.com/380147
leviw_travelin_and_unemployed 2014/06/04 20:37:25 Do you have a test case? We shouldn't be getting a
chrishtr 2014/06/04 21:18:57 compositing/reflections/nested-reflection-transfor
ojan 2014/06/07 17:35:23 I don't see scrollContentsFastPath on that stack.
chrishtr 2014/06/09 16:40:17 Ok I see, I misinterpreted your question. It does
// 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 repaints 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