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

Unified Diff: third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp

Issue 2295483003: CompositingInputsUpdater should do more clip parent analysis (Closed)
Patch Set: Created 4 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
« no previous file with comments | « third_party/WebKit/LayoutTests/compositing/overflow/clip-parent-of-non-scrolled-expected.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp
diff --git a/third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp b/third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp
index 46652d9eae9582bf4017fb8708d824a35d7b34db..6782b558f5d8b503c8eb9bf89a8567e21c14769c 100644
--- a/third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp
+++ b/third_party/WebKit/Source/core/layout/compositing/CompositingInputsUpdater.cpp
@@ -152,6 +152,12 @@ void CompositingInputsUpdater::updateRecursive(PaintLayer* layer, UpdateType upd
const PaintLayer* parentLayerOnClippingContainerChain = findParentLayerOnClippingContainerChain(layer);
const bool parentHasClipRelatedProperty = parentLayerOnClippingContainerChain->layoutObject()->hasClipRelatedProperty();
properties.clippingContainer = parentHasClipRelatedProperty ? parentLayerOnClippingContainerChain->layoutObject() : parentLayerOnClippingContainerChain->clippingContainer();
+
+ if (layer->layoutObject()->isOutOfFlowPositioned() && !layer->subtreeIsInvisible()) {
+ const PaintLayer* clippingLayer = properties.clippingContainer ? properties.clippingContainer->enclosingLayer() : layer->compositor()->rootLayer();
+ if (hasClippedStackingAncestor(layer, clippingLayer))
+ rareProperties.clipParent = clippingLayer;
+ }
}
if (info.lastScrollingAncestor) {
@@ -162,12 +168,6 @@ void CompositingInputsUpdater::updateRecursive(PaintLayer* layer, UpdateType upd
if (parentLayerOnContainingBlockChain->scrollsOverflow())
rareProperties.ancestorScrollingLayer = parentLayerOnContainingBlockChain;
- if (layer->layoutObject()->isOutOfFlowPositioned() && !layer->subtreeIsInvisible()) {
- const PaintLayer* clippingLayer = properties.clippingContainer ? properties.clippingContainer->enclosingLayer() : layer->compositor()->rootLayer();
- if (hasClippedStackingAncestor(layer, clippingLayer))
- rareProperties.clipParent = clippingLayer;
- }
-
if (layer->stackingNode()->isStacked()
&& rareProperties.ancestorScrollingLayer
&& !info.ancestorStackingContext->layoutObject()->isDescendantOf(rareProperties.ancestorScrollingLayer->layoutObject()))
« no previous file with comments | « third_party/WebKit/LayoutTests/compositing/overflow/clip-parent-of-non-scrolled-expected.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698