Index: Source/core/rendering/RenderLayer.cpp |
diff --git a/Source/core/rendering/RenderLayer.cpp b/Source/core/rendering/RenderLayer.cpp |
index aa8d0e1601e68c17665463eacacb33799dc2366d..323d1957feaafe1d7f55fdb751baf80aa8b2de2a 100644 |
--- a/Source/core/rendering/RenderLayer.cpp |
+++ b/Source/core/rendering/RenderLayer.cpp |
@@ -3941,6 +3941,15 @@ inline bool RenderLayer::needsCompositingLayersRebuiltForFilters(const RenderSty |
return false; |
} |
+inline bool RenderLayer::needsCompositingLayersRebuiltForBlending(const RenderStyle* oldStyle, const RenderStyle* newStyle) const |
+{ |
+ ASSERT(newStyle); |
+ if (!hasCompositedLayerMapping()) |
+ return false; |
+ return (shouldIsolateCompositedDescendants() && !stackingNode()->isStackingContext()) |
+ || (oldStyle && (oldStyle->hasBlendMode() != newStyle->hasBlendMode())); |
+} |
+ |
void RenderLayer::updateFilters(const RenderStyle* oldStyle, const RenderStyle* newStyle) |
{ |
if (!hasOrHadFilters(oldStyle, newStyle)) |
@@ -3987,7 +3996,8 @@ void RenderLayer::styleChanged(StyleDifference, const RenderStyle* oldStyle) |
if (compositor()->updateLayerCompositingState(this) |
|| needsCompositingLayersRebuiltForClip(oldStyle, newStyle) |
|| needsCompositingLayersRebuiltForOverflow(oldStyle, newStyle) |
- || needsCompositingLayersRebuiltForFilters(oldStyle, newStyle, didPaintWithFilters)) |
+ || needsCompositingLayersRebuiltForFilters(oldStyle, newStyle, didPaintWithFilters) |
+ || needsCompositingLayersRebuiltForBlending(oldStyle, newStyle)) |
compositor()->setCompositingLayersNeedRebuild(); |
else if (hasCompositedLayerMapping()) |
compositedLayerMapping()->updateGraphicsLayerGeometry(); |