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

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

Issue 445263002: Remove cached bounds in RenderLayer. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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/RenderLayerScrollableArea.cpp
diff --git a/Source/core/rendering/RenderLayerScrollableArea.cpp b/Source/core/rendering/RenderLayerScrollableArea.cpp
index 62d2aa6a6c2d9ad5676a362d7c4678171f49636d..5ad2ced0aaa43bb38086bd88b63da51606da8c94 100644
--- a/Source/core/rendering/RenderLayerScrollableArea.cpp
+++ b/Source/core/rendering/RenderLayerScrollableArea.cpp
@@ -355,11 +355,14 @@ void RenderLayerScrollableArea::setScrollOffset(const IntPoint& newScrollOffset)
// FIXME(361045): remove InspectorInstrumentation calls once DevTools Timeline migrates to tracing.
InspectorInstrumentation::willScrollLayer(&box());
+ const RenderLayerModelObject* repaintContainer = box().containerForPaintInvalidation();
+
// Update the positions of our child layers (if needed as only fixed layers should be impacted by a scroll).
// We don't update compositing layers, because we need to do a deep update from the compositing ancestor.
if (!frameView->isInPerformLayout()) {
// If we're in the middle of layout, we'll just update layers once layout has finished.
- layer()->updateLayerPositionsAfterOverflowScroll();
+ layer()->clipper().clearClipRectsIncludingDescendants();
+ box().setPreviousPaintInvalidationRect(box().boundsRectForPaintInvalidation(repaintContainer));
// Update regions, scrolling may change the clip of a particular region.
frameView->updateAnnotatedRegions();
// FIXME: We shouldn't call updateWidgetPositions() here since it might tear down the render tree,
@@ -369,7 +372,6 @@ void RenderLayerScrollableArea::setScrollOffset(const IntPoint& newScrollOffset)
updateCompositingLayersAfterScroll();
}
- const RenderLayerModelObject* repaintContainer = box().containerForPaintInvalidation();
// The caret rect needs to be invalidated after scrolling
frame->selection().setCaretRectNeedsUpdate();

Powered by Google App Engine
This is Rietveld 408576698