OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. |
3 * | 3 * |
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
5 * | 5 * |
6 * Other contributors: | 6 * Other contributors: |
7 * Robert O'Callahan <roc+@cs.cmu.edu> | 7 * Robert O'Callahan <roc+@cs.cmu.edu> |
8 * David Baron <dbaron@fas.harvard.edu> | 8 * David Baron <dbaron@fas.harvard.edu> |
9 * Christian Biesinger <cbiesinger@web.de> | 9 * Christian Biesinger <cbiesinger@web.de> |
10 * Randall Jesup <rjesup@wgate.com> | 10 * Randall Jesup <rjesup@wgate.com> |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 | 103 |
104 using namespace HTMLNames; | 104 using namespace HTMLNames; |
105 | 105 |
106 RenderLayer::RenderLayer(RenderLayerModelObject* renderer) | 106 RenderLayer::RenderLayer(RenderLayerModelObject* renderer) |
107 : m_hasSelfPaintingLayerDescendant(false) | 107 : m_hasSelfPaintingLayerDescendant(false) |
108 , m_hasSelfPaintingLayerDescendantDirty(false) | 108 , m_hasSelfPaintingLayerDescendantDirty(false) |
109 , m_hasOutOfFlowPositionedDescendant(false) | 109 , m_hasOutOfFlowPositionedDescendant(false) |
110 , m_hasOutOfFlowPositionedDescendantDirty(true) | 110 , m_hasOutOfFlowPositionedDescendantDirty(true) |
111 , m_hasUnclippedDescendant(false) | 111 , m_hasUnclippedDescendant(false) |
112 , m_isUnclippedDescendant(false) | 112 , m_isUnclippedDescendant(false) |
| 113 , m_hasComplexClippedAncestor(false) |
113 , m_isRootLayer(renderer->isRenderView()) | 114 , m_isRootLayer(renderer->isRenderView()) |
114 , m_usedTransparency(false) | 115 , m_usedTransparency(false) |
115 , m_childLayerHasBlendMode(false) | 116 , m_childLayerHasBlendMode(false) |
116 , m_childLayerHasBlendModeStatusDirty(false) | 117 , m_childLayerHasBlendModeStatusDirty(false) |
117 , m_visibleContentStatusDirty(true) | 118 , m_visibleContentStatusDirty(true) |
118 , m_hasVisibleContent(false) | 119 , m_hasVisibleContent(false) |
119 , m_visibleDescendantStatusDirty(false) | 120 , m_visibleDescendantStatusDirty(false) |
120 , m_hasVisibleDescendant(false) | 121 , m_hasVisibleDescendant(false) |
121 , m_hasVisibleNonLayerContent(false) | 122 , m_hasVisibleNonLayerContent(false) |
122 , m_isPaginated(false) | 123 , m_isPaginated(false) |
(...skipping 1268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1391 if (child->stackingNode()->isNormalFlowOnly()) | 1392 if (child->stackingNode()->isNormalFlowOnly()) |
1392 m_stackingNode->dirtyNormalFlowList(); | 1393 m_stackingNode->dirtyNormalFlowList(); |
1393 | 1394 |
1394 if (!child->stackingNode()->isNormalFlowOnly() || child->firstChild()) { | 1395 if (!child->stackingNode()->isNormalFlowOnly() || child->firstChild()) { |
1395 // Dirty the z-order list in which we are contained. The ancestorStackin
gContainerNode() can be null in the | 1396 // Dirty the z-order list in which we are contained. The ancestorStackin
gContainerNode() can be null in the |
1396 // case where we're building up generated content layers. This is ok, si
nce the lists will start | 1397 // case where we're building up generated content layers. This is ok, si
nce the lists will start |
1397 // off dirty in that case anyway. | 1398 // off dirty in that case anyway. |
1398 child->stackingNode()->dirtyStackingContainerZOrderLists(); | 1399 child->stackingNode()->dirtyStackingContainerZOrderLists(); |
1399 } | 1400 } |
1400 | 1401 |
| 1402 child->updateHasComplexClippedAncestor(); |
1401 child->updateDescendantDependentFlags(); | 1403 child->updateDescendantDependentFlags(); |
1402 if (child->m_hasVisibleContent || child->m_hasVisibleDescendant) | 1404 if (child->m_hasVisibleContent || child->m_hasVisibleDescendant) |
1403 setAncestorChainHasVisibleDescendant(); | 1405 setAncestorChainHasVisibleDescendant(); |
1404 | 1406 |
1405 if (child->isSelfPaintingLayer() || child->hasSelfPaintingLayerDescendant()) | 1407 if (child->isSelfPaintingLayer() || child->hasSelfPaintingLayerDescendant()) |
1406 setAncestorChainHasSelfPaintingLayerDescendant(); | 1408 setAncestorChainHasSelfPaintingLayerDescendant(); |
1407 | 1409 |
1408 if (child->paintsWithBlendMode() || child->childLayerHasBlendMode()) | 1410 if (child->paintsWithBlendMode() || child->childLayerHasBlendMode()) |
1409 setAncestorChainBlendedDescendant(); | 1411 setAncestorChainBlendedDescendant(); |
1410 | 1412 |
(...skipping 596 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2007 // Ensure our lists are up-to-date. | 2009 // Ensure our lists are up-to-date. |
2008 m_stackingNode->updateLayerListsIfNeeded(); | 2010 m_stackingNode->updateLayerListsIfNeeded(); |
2009 | 2011 |
2010 LayoutPoint offsetFromRoot; | 2012 LayoutPoint offsetFromRoot; |
2011 convertToLayerCoords(paintingInfo.rootLayer, offsetFromRoot); | 2013 convertToLayerCoords(paintingInfo.rootLayer, offsetFromRoot); |
2012 | 2014 |
2013 IntRect rootRelativeBounds; | 2015 IntRect rootRelativeBounds; |
2014 bool rootRelativeBoundsComputed = false; | 2016 bool rootRelativeBoundsComputed = false; |
2015 | 2017 |
2016 // Apply clip-path to context. | 2018 // Apply clip-path to context. |
2017 bool hasClipPath = false; | 2019 bool needsContextRestore = false; |
2018 RenderStyle* style = renderer()->style(); | 2020 Vector<RenderSVGResourceClipper*> resourceClippers; |
2019 RenderSVGResourceClipper* resourceClipper = 0; | |
2020 ClipperContext clipperContext; | 2021 ClipperContext clipperContext; |
2021 if (renderer()->hasClipPath() && !context->paintingDisabled() && style) { | 2022 if (!context->paintingDisabled()) |
2022 ASSERT(style->clipPath()); | 2023 applyComplexClip(context, this, &clipperContext, paintingInfo, offsetFro
mRoot, &needsContextRestore, &rootRelativeBoundsComputed, &rootRelativeBounds, &
resourceClippers); |
2023 if (style->clipPath()->type() == ClipPathOperation::SHAPE) { | |
2024 hasClipPath = true; | |
2025 context->save(); | |
2026 ShapeClipPathOperation* clipPath = toShapeClipPathOperation(style->c
lipPath()); | |
2027 | |
2028 if (!rootRelativeBoundsComputed) { | |
2029 rootRelativeBounds = calculateLayerBounds(paintingInfo.rootLayer
, &offsetFromRoot, 0); | |
2030 rootRelativeBoundsComputed = true; | |
2031 } | |
2032 | |
2033 context->clipPath(clipPath->path(rootRelativeBounds), clipPath->wind
Rule()); | |
2034 } else if (style->clipPath()->type() == ClipPathOperation::REFERENCE) { | |
2035 ReferenceClipPathOperation* referenceClipPathOperation = toReference
ClipPathOperation(style->clipPath()); | |
2036 Document& document = renderer()->document(); | |
2037 // FIXME: It doesn't work with forward or external SVG references (h
ttps://bugs.webkit.org/show_bug.cgi?id=90405) | |
2038 Element* element = document.getElementById(referenceClipPathOperatio
n->fragment()); | |
2039 if (element && element->hasTagName(SVGNames::clipPathTag) && element
->renderer()) { | |
2040 if (!rootRelativeBoundsComputed) { | |
2041 rootRelativeBounds = calculateLayerBounds(paintingInfo.rootL
ayer, &offsetFromRoot, 0); | |
2042 rootRelativeBoundsComputed = true; | |
2043 } | |
2044 | |
2045 resourceClipper = toRenderSVGResourceClipper(toRenderSVGResource
Container(element->renderer())); | |
2046 if (!resourceClipper->applyClippingToContext(renderer(), rootRel
ativeBounds, | |
2047 paintingInfo.paintDirtyRect, context, clipperContext)) { | |
2048 // No need to post-apply the clipper if this failed. | |
2049 resourceClipper = 0; | |
2050 } | |
2051 } | |
2052 } | |
2053 } | |
2054 | 2024 |
2055 // Blending operations must be performed only with the nearest ancestor stac
king context. | 2025 // Blending operations must be performed only with the nearest ancestor stac
king context. |
2056 // Note that there is no need to create a transparency layer if we're painti
ng the root. | 2026 // Note that there is no need to create a transparency layer if we're painti
ng the root. |
2057 bool createTransparencyLayerForBlendMode = !renderer()->isRoot() && m_stacki
ngNode->isStackingContext() && m_childLayerHasBlendMode; | 2027 bool createTransparencyLayerForBlendMode = !renderer()->isRoot() && m_stacki
ngNode->isStackingContext() && m_childLayerHasBlendMode; |
2058 | 2028 |
2059 if (createTransparencyLayerForBlendMode) | 2029 if (createTransparencyLayerForBlendMode) |
2060 beginTransparencyLayers(context, paintingInfo.rootLayer, paintingInfo.pa
intDirtyRect, paintingInfo.paintBehavior); | 2030 beginTransparencyLayers(context, paintingInfo.rootLayer, paintingInfo.pa
intDirtyRect, paintingInfo.paintBehavior); |
2061 | 2031 |
2062 LayerPaintingInfo localPaintingInfo(paintingInfo); | 2032 LayerPaintingInfo localPaintingInfo(paintingInfo); |
2063 FilterEffectRendererHelper filterPainter(filterRenderer() && paintsWithFilte
rs()); | 2033 FilterEffectRendererHelper filterPainter(filterRenderer() && paintsWithFilte
rs()); |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2178 paintChildClippingMaskForFragments(layerFragments, context, localPaintin
gInfo, paintingRootForRenderer); | 2148 paintChildClippingMaskForFragments(layerFragments, context, localPaintin
gInfo, paintingRootForRenderer); |
2179 } | 2149 } |
2180 | 2150 |
2181 // End our transparency layer | 2151 // End our transparency layer |
2182 if ((haveTransparency || paintsWithBlendMode() || createTransparencyLayerFor
BlendMode) && m_usedTransparency && !(m_reflectionInfo && m_reflectionInfo->isPa
intingInsideReflection())) { | 2152 if ((haveTransparency || paintsWithBlendMode() || createTransparencyLayerFor
BlendMode) && m_usedTransparency && !(m_reflectionInfo && m_reflectionInfo->isPa
intingInsideReflection())) { |
2183 context->endLayer(); | 2153 context->endLayer(); |
2184 context->restore(); | 2154 context->restore(); |
2185 m_usedTransparency = false; | 2155 m_usedTransparency = false; |
2186 } | 2156 } |
2187 | 2157 |
2188 if (resourceClipper) | 2158 while (resourceClippers.size()) { |
2189 resourceClipper->postApplyStatefulResource(renderer(), context, clipperC
ontext); | 2159 resourceClippers.last()->postApplyStatefulResource(renderer(), context,
clipperContext); |
| 2160 resourceClippers.removeLast(); |
| 2161 } |
2190 | 2162 |
2191 if (hasClipPath) | 2163 if (needsContextRestore) |
2192 context->restore(); | 2164 context->restore(); |
2193 } | 2165 } |
2194 | 2166 |
| 2167 void RenderLayer::applyComplexClip(GraphicsContext* context, RenderLayer* curren
tLayer, ClipperContext* clipperContext, const LayerPaintingInfo& paintingInfo, c
onst LayoutPoint& offsetFromRoot, bool* needsContextRestore, bool* rootRelativeB
oundsComputed, IntRect* rootRelativeBounds, Vector<RenderSVGResourceClipper*>* r
esourceClippers) |
| 2168 { |
| 2169 bool isRecursing = currentLayer != this; |
| 2170 if (parent() && parent()->hasComplexClippedAncestor() && (hasCompositedLayer
Mapping() || isRecursing)) { |
| 2171 bool parentRelativeBoundsComputed = false; |
| 2172 IntRect parentRootRelativeBounds; |
| 2173 LayoutPoint delta; |
| 2174 convertToLayerCoords(parent(), delta); |
| 2175 LayoutPoint parentOffsetFromRoot = toPoint(offsetFromRoot - delta); |
| 2176 AffineTransform savedCTM; |
| 2177 if (hasTransform()) { |
| 2178 // Apply inverse transform to bring parent layer's clip into current
Layer's frame of reference. |
| 2179 // Can't use save/restore because clip must be preserved. |
| 2180 savedCTM = context->getCTM(); |
| 2181 // FIXME: Flattening to an affine transform at each recursion level
does not handle cascading |
| 2182 // 3D transforms correctly when preserves3D() == true. |
| 2183 context->concatCTM(transform()->inverse().toAffineTransform()); |
| 2184 } |
| 2185 parent()->applyComplexClip(context, currentLayer, clipperContext, painti
ngInfo, parentOffsetFromRoot, needsContextRestore, &parentRelativeBoundsComputed
, &parentRootRelativeBounds, resourceClippers); |
| 2186 if (hasTransform()) |
| 2187 context->setCTM(savedCTM); |
| 2188 } |
| 2189 |
| 2190 RenderStyle* style = renderer()->style(); |
| 2191 if (style && inContainingBlockChain(currentLayer, this)) { |
| 2192 if (renderer()->hasClipPath()) { |
| 2193 ASSERT(style->clipPath()); |
| 2194 if (style->clipPath()->type() == ClipPathOperation::SHAPE) { |
| 2195 if (!*needsContextRestore) { |
| 2196 // we have not yet saved the context in the current applyCli
pPath recursion chain |
| 2197 *needsContextRestore = true; |
| 2198 context->save(); |
| 2199 } |
| 2200 ShapeClipPathOperation* clipPath = static_cast<ShapeClipPathOper
ation*>(style->clipPath()); |
| 2201 if (!*rootRelativeBoundsComputed) { |
| 2202 *rootRelativeBounds = calculateLayerBounds(paintingInfo.root
Layer, &offsetFromRoot, 0); |
| 2203 *rootRelativeBoundsComputed = true; |
| 2204 } |
| 2205 context->clipPath(clipPath->path(*rootRelativeBounds), clipPath-
>windRule()); |
| 2206 } else if (style->clipPath()->type() == ClipPathOperation::REFERENCE
) { |
| 2207 ReferenceClipPathOperation* referenceClipPathOperation = static_
cast<ReferenceClipPathOperation*>(style->clipPath()); |
| 2208 Document& document = renderer()->document(); |
| 2209 // FIXME: It doesn't work with forward or external SVG reference
s (https://bugs.webkit.org/show_bug.cgi?id=90405) |
| 2210 Element* element = document.getElementById(referenceClipPathOper
ation->fragment()); |
| 2211 if (element && element->hasTagName(SVGNames::clipPathTag) && ele
ment->renderer()) { |
| 2212 if (!*rootRelativeBoundsComputed) { |
| 2213 *rootRelativeBounds = calculateLayerBounds(paintingInfo.
rootLayer, &offsetFromRoot, 0); |
| 2214 *rootRelativeBoundsComputed = true; |
| 2215 } |
| 2216 RenderSVGResourceClipper* resourceClipper = toRenderSVGResou
rceClipper(toRenderSVGResourceContainer(element->renderer())); |
| 2217 if (resourceClipper->applyClippingToContext(renderer(), *roo
tRelativeBounds, paintingInfo.paintDirtyRect, context, *clipperContext)) |
| 2218 resourceClippers->append(resourceClipper); |
| 2219 } |
| 2220 } |
| 2221 } |
| 2222 if (isRecursing && renderer()->hasOverflowClip() && style->hasBorderRadi
us()) { |
| 2223 // Propagate border radius clipping from ancestors. |
| 2224 // The border radius of currentLayer is skipped because it is alread
y taken care of by clipToRect |
| 2225 context->clipRoundedRect(style->getRoundedInnerBorderFor(LayoutRect(
offsetFromRoot, size()))); |
| 2226 } |
| 2227 } |
| 2228 } |
| 2229 |
2195 void RenderLayer::paintLayerByApplyingTransform(GraphicsContext* context, const
LayerPaintingInfo& paintingInfo, PaintLayerFlags paintFlags, const LayoutPoint&
translationOffset) | 2230 void RenderLayer::paintLayerByApplyingTransform(GraphicsContext* context, const
LayerPaintingInfo& paintingInfo, PaintLayerFlags paintFlags, const LayoutPoint&
translationOffset) |
2196 { | 2231 { |
2197 // This involves subtracting out the position of the layer in our current co
ordinate space, but preserving | 2232 // This involves subtracting out the position of the layer in our current co
ordinate space, but preserving |
2198 // the accumulated error for sub-pixel layout. | 2233 // the accumulated error for sub-pixel layout. |
2199 LayoutPoint delta; | 2234 LayoutPoint delta; |
2200 convertToLayerCoords(paintingInfo.rootLayer, delta); | 2235 convertToLayerCoords(paintingInfo.rootLayer, delta); |
2201 delta.moveBy(translationOffset); | 2236 delta.moveBy(translationOffset); |
2202 TransformationMatrix transform(renderableTransform(paintingInfo.paintBehavio
r)); | 2237 TransformationMatrix transform(renderableTransform(paintingInfo.paintBehavio
r)); |
2203 IntPoint roundedDelta = roundedIntPoint(delta); | 2238 IntPoint roundedDelta = roundedIntPoint(delta); |
2204 transform.translateRight(roundedDelta.x(), roundedDelta.y()); | 2239 transform.translateRight(roundedDelta.x(), roundedDelta.y()); |
(...skipping 1504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3709 // FIXME: Handle simple transforms. | 3744 // FIXME: Handle simple transforms. |
3710 if (paintsWithTransform(PaintBehaviorNormal)) | 3745 if (paintsWithTransform(PaintBehaviorNormal)) |
3711 return false; | 3746 return false; |
3712 | 3747 |
3713 // FIXME: Remove this check. | 3748 // FIXME: Remove this check. |
3714 // This function should not be called when layer-lists are dirty. | 3749 // This function should not be called when layer-lists are dirty. |
3715 // It is somehow getting triggered during style update. | 3750 // It is somehow getting triggered during style update. |
3716 if (m_stackingNode->zOrderListsDirty() || m_stackingNode->normalFlowListDirt
y()) | 3751 if (m_stackingNode->zOrderListsDirty() || m_stackingNode->normalFlowListDirt
y()) |
3717 return false; | 3752 return false; |
3718 | 3753 |
| 3754 if (hasComplexClippedAncestor()) |
| 3755 return false; |
| 3756 |
3719 // FIXME: We currently only check the immediate renderer, | 3757 // FIXME: We currently only check the immediate renderer, |
3720 // which will miss many cases. | 3758 // which will miss many cases. |
3721 if (renderer()->backgroundIsKnownToBeOpaqueInRect(localRect)) | 3759 if (renderer()->backgroundIsKnownToBeOpaqueInRect(localRect)) |
3722 return true; | 3760 return true; |
3723 | 3761 |
3724 // We can't consult child layers if we clip, since they might cover | 3762 // We can't consult child layers if we clip, since they might cover |
3725 // parts of the rect that are clipped out. | 3763 // parts of the rect that are clipped out. |
3726 if (renderer()->hasOverflowClip()) | 3764 if (renderer()->hasOverflowClip()) |
3727 return false; | 3765 return false; |
3728 | 3766 |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3889 // We need to reset the isUnclippedDescendant bit here because normally | 3927 // We need to reset the isUnclippedDescendant bit here because normally |
3890 // the "unclipped-ness" property is only updated in | 3928 // the "unclipped-ness" property is only updated in |
3891 // RenderLayerCompositor::updateCompositingRequirementsState(). However, | 3929 // RenderLayerCompositor::updateCompositingRequirementsState(). However, |
3892 // it is only updated for layers which are known to be out of flow. | 3930 // it is only updated for layers which are known to be out of flow. |
3893 // Since this is no longer out of flow, we have to explicitly ensure | 3931 // Since this is no longer out of flow, we have to explicitly ensure |
3894 // that it doesn't think it is unclipped. | 3932 // that it doesn't think it is unclipped. |
3895 setIsUnclippedDescendant(false); | 3933 setIsUnclippedDescendant(false); |
3896 } | 3934 } |
3897 } | 3935 } |
3898 | 3936 |
| 3937 void RenderLayer::updateHasComplexClippedAncestor() |
| 3938 { |
| 3939 bool hasComplexClip = renderer()->hasClipPath() |
| 3940 || (renderer()->hasOverflowClip() && renderer()->style()->hasBorderRadiu
s()) |
| 3941 || (parent() && parent()->hasComplexClippedAncestor()); |
| 3942 |
| 3943 if (hasComplexClip == hasComplexClippedAncestor()) |
| 3944 return; |
| 3945 |
| 3946 setHasComplexClippedAncestor(hasComplexClip); |
| 3947 |
| 3948 for (RenderLayer* child = firstChild(); child; child = child->nextSibling())
{ |
| 3949 child->updateHasComplexClippedAncestor(); |
| 3950 } |
| 3951 } |
| 3952 |
3899 static bool hasOrHadFilters(const RenderStyle* oldStyle, const RenderStyle* newS
tyle) | 3953 static bool hasOrHadFilters(const RenderStyle* oldStyle, const RenderStyle* newS
tyle) |
3900 { | 3954 { |
3901 ASSERT(newStyle); | 3955 ASSERT(newStyle); |
3902 return (oldStyle && oldStyle->hasFilter()) || newStyle->hasFilter(); | 3956 return (oldStyle && oldStyle->hasFilter()) || newStyle->hasFilter(); |
3903 } | 3957 } |
3904 | 3958 |
3905 inline bool RenderLayer::needsCompositingLayersRebuiltForClip(const RenderStyle*
oldStyle, const RenderStyle* newStyle) const | 3959 inline bool RenderLayer::needsCompositingLayersRebuiltForClip(const RenderStyle*
oldStyle, const RenderStyle* newStyle) const |
3906 { | 3960 { |
3907 ASSERT(newStyle); | 3961 ASSERT(newStyle); |
3908 return oldStyle && (oldStyle->clip() != newStyle->clip() || oldStyle->hasCli
p() != newStyle->hasClip()); | 3962 return oldStyle && (oldStyle->clip() != newStyle->clip() || oldStyle->hasCli
p() != newStyle->hasClip()); |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3977 updateReflectionInfo(oldStyle); | 4031 updateReflectionInfo(oldStyle); |
3978 | 4032 |
3979 if (RuntimeEnabledFeatures::cssCompositingEnabled()) | 4033 if (RuntimeEnabledFeatures::cssCompositingEnabled()) |
3980 updateBlendMode(); | 4034 updateBlendMode(); |
3981 | 4035 |
3982 updateDescendantDependentFlags(); | 4036 updateDescendantDependentFlags(); |
3983 updateTransform(); | 4037 updateTransform(); |
3984 | 4038 |
3985 bool didPaintWithFilters = false; | 4039 bool didPaintWithFilters = false; |
3986 | 4040 |
| 4041 updateHasComplexClippedAncestor(); |
| 4042 |
3987 if (paintsWithFilters()) | 4043 if (paintsWithFilters()) |
3988 didPaintWithFilters = true; | 4044 didPaintWithFilters = true; |
3989 updateFilters(oldStyle, renderer()->style()); | 4045 updateFilters(oldStyle, renderer()->style()); |
3990 | 4046 |
3991 const RenderStyle* newStyle = renderer()->style(); | 4047 const RenderStyle* newStyle = renderer()->style(); |
3992 if (compositor()->updateLayerCompositingState(this) | 4048 if (compositor()->updateLayerCompositingState(this) |
3993 || needsCompositingLayersRebuiltForClip(oldStyle, newStyle) | 4049 || needsCompositingLayersRebuiltForClip(oldStyle, newStyle) |
3994 || needsCompositingLayersRebuiltForOverflow(oldStyle, newStyle) | 4050 || needsCompositingLayersRebuiltForOverflow(oldStyle, newStyle) |
3995 || needsCompositingLayersRebuiltForFilters(oldStyle, newStyle, didPaintW
ithFilters)) | 4051 || needsCompositingLayersRebuiltForFilters(oldStyle, newStyle, didPaintW
ithFilters)) |
3996 compositor()->setCompositingLayersNeedRebuild(); | 4052 compositor()->setCompositingLayersNeedRebuild(); |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4165 } | 4221 } |
4166 } | 4222 } |
4167 | 4223 |
4168 void showLayerTree(const WebCore::RenderObject* renderer) | 4224 void showLayerTree(const WebCore::RenderObject* renderer) |
4169 { | 4225 { |
4170 if (!renderer) | 4226 if (!renderer) |
4171 return; | 4227 return; |
4172 showLayerTree(renderer->enclosingLayer()); | 4228 showLayerTree(renderer->enclosingLayer()); |
4173 } | 4229 } |
4174 #endif | 4230 #endif |
OLD | NEW |