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

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

Issue 625903004: [New Multicolumn] Correct paint rectangle calculation for compositing. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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/RenderLayer.cpp
diff --git a/Source/core/rendering/RenderLayer.cpp b/Source/core/rendering/RenderLayer.cpp
index 9c306c9dd320254c78ad2ed96a6a0be03fe7c60c..de7234cdb0d11680e679e78f1793bed94151fa49 100644
--- a/Source/core/rendering/RenderLayer.cpp
+++ b/Source/core/rendering/RenderLayer.cpp
@@ -1491,7 +1491,14 @@ void RenderLayer::collectFragments(LayerFragments& fragments, const RenderLayer*
// Shift the dirty rect into flow thread coordinates.
LayoutPoint offsetOfPaginationLayerFromRoot;
- enclosingPaginationLayer()->convertToLayerCoords(rootLayer, offsetOfPaginationLayerFromRoot);
+ if (rootLayer != enclosingPaginationLayer() && rootLayer->enclosingPaginationLayer() == enclosingPaginationLayer()) {
+ // The root layer is inside our pagination layer.
+ // FIXME: more work needed if there are nested pagination layers.
+ rootLayer->convertToLayerCoords(enclosingPaginationLayer(), offsetOfPaginationLayerFromRoot);
+ offsetOfPaginationLayerFromRoot = -offsetOfPaginationLayerFromRoot;
+ } else {
+ enclosingPaginationLayer()->convertToLayerCoords(rootLayer, offsetOfPaginationLayerFromRoot);
+ }
LayoutRect dirtyRectInFlowThread(dirtyRect);
dirtyRectInFlowThread.moveBy(-offsetOfPaginationLayerFromRoot);

Powered by Google App Engine
This is Rietveld 408576698