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

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

Issue 1775013003: Implement -webkit-box-reflect as a filter. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: make msvc dbg happy Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/layout/compositing/CompositingInputsUpdater.h" 5 #include "core/layout/compositing/CompositingInputsUpdater.h"
6 6
7 #include "core/layout/LayoutBlock.h" 7 #include "core/layout/LayoutBlock.h"
8 #include "core/layout/compositing/CompositedLayerMapping.h" 8 #include "core/layout/compositing/CompositedLayerMapping.h"
9 #include "core/layout/compositing/PaintLayerCompositor.h" 9 #include "core/layout/compositing/PaintLayerCompositor.h"
10 #include "core/paint/PaintLayer.h" 10 #include "core/paint/PaintLayer.h"
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 // See https://codereview.chromium.org/13912020/ 119 // See https://codereview.chromium.org/13912020/
120 if (properties.clippedAbsoluteBoundingBox.isEmpty()) 120 if (properties.clippedAbsoluteBoundingBox.isEmpty())
121 properties.clippedAbsoluteBoundingBox.setSize(IntSize(1, 1)); 121 properties.clippedAbsoluteBoundingBox.setSize(IntSize(1, 1));
122 122
123 IntRect clipRect = pixelSnappedIntRect(layer->clipper().backgroundCl ipRect(ClipRectsContext(m_rootLayer, AbsoluteClipRects)).rect()); 123 IntRect clipRect = pixelSnappedIntRect(layer->clipper().backgroundCl ipRect(ClipRectsContext(m_rootLayer, AbsoluteClipRects)).rect());
124 properties.clippedAbsoluteBoundingBox.intersect(clipRect); 124 properties.clippedAbsoluteBoundingBox.intersect(clipRect);
125 125
126 const PaintLayer* parent = layer->parent(); 126 const PaintLayer* parent = layer->parent();
127 rareProperties.opacityAncestor = parent->isTransparent() ? parent : parent->opacityAncestor(); 127 rareProperties.opacityAncestor = parent->isTransparent() ? parent : parent->opacityAncestor();
128 rareProperties.transformAncestor = parent->hasTransformRelatedProper ty() ? parent : parent->transformAncestor(); 128 rareProperties.transformAncestor = parent->hasTransformRelatedProper ty() ? parent : parent->transformAncestor();
129 rareProperties.filterAncestor = parent->hasFilter() ? parent : paren t->filterAncestor(); 129 rareProperties.filterAncestor = parent->hasFilterInducingProperty() ? parent : parent->filterAncestor();
130 bool layerIsFixedPosition = layer->layoutObject()->style()->position () == FixedPosition; 130 bool layerIsFixedPosition = layer->layoutObject()->style()->position () == FixedPosition;
131 rareProperties.nearestFixedPositionLayer = layerIsFixedPosition ? la yer : parent->nearestFixedPositionLayer(); 131 rareProperties.nearestFixedPositionLayer = layerIsFixedPosition ? la yer : parent->nearestFixedPositionLayer();
132 132
133 if (info.hasAncestorWithClipRelatedProperty) { 133 if (info.hasAncestorWithClipRelatedProperty) {
134 const PaintLayer* parentLayerOnClippingContainerChain = findPare ntLayerOnClippingContainerChain(layer); 134 const PaintLayer* parentLayerOnClippingContainerChain = findPare ntLayerOnClippingContainerChain(layer);
135 const bool parentHasClipRelatedProperty = parentLayerOnClippingC ontainerChain->layoutObject()->hasClipRelatedProperty(); 135 const bool parentHasClipRelatedProperty = parentLayerOnClippingC ontainerChain->layoutObject()->hasClipRelatedProperty();
136 properties.clippingContainer = parentHasClipRelatedProperty ? pa rentLayerOnClippingContainerChain->layoutObject() : parentLayerOnClippingContain erChain->clippingContainer(); 136 properties.clippingContainer = parentHasClipRelatedProperty ? pa rentLayerOnClippingContainerChain->layoutObject() : parentLayerOnClippingContain erChain->clippingContainer();
137 } 137 }
138 138
139 if (info.lastScrollingAncestor) { 139 if (info.lastScrollingAncestor) {
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 ASSERT(!layer->childNeedsCompositingInputsUpdate()); 194 ASSERT(!layer->childNeedsCompositingInputsUpdate());
195 ASSERT(!layer->needsCompositingInputsUpdate()); 195 ASSERT(!layer->needsCompositingInputsUpdate());
196 196
197 for (PaintLayer* child = layer->firstChild(); child; child = child->nextSibl ing()) 197 for (PaintLayer* child = layer->firstChild(); child; child = child->nextSibl ing())
198 assertNeedsCompositingInputsUpdateBitsCleared(child); 198 assertNeedsCompositingInputsUpdateBitsCleared(child);
199 } 199 }
200 200
201 #endif 201 #endif
202 202
203 } // namespace blink 203 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698