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

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

Issue 556993002: Revert "Don't layout when isSelfPaintingLayer() changes" (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 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 | « LayoutTests/TestExpectations ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderLayerModelObject.cpp
diff --git a/Source/core/rendering/RenderLayerModelObject.cpp b/Source/core/rendering/RenderLayerModelObject.cpp
index e340de3fd4ebb33283c95641b5379b1fb386d4aa..947731dcd94047c9164f167cafa75e8f20f95f73 100644
--- a/Source/core/rendering/RenderLayerModelObject.cpp
+++ b/Source/core/rendering/RenderLayerModelObject.cpp
@@ -104,6 +104,8 @@ void RenderLayerModelObject::styleWillChange(StyleDifference diff, const RenderS
void RenderLayerModelObject::styleDidChange(StyleDifference diff, const RenderStyle* oldStyle)
{
bool hadTransform = hasTransform();
+ bool hadLayer = hasLayer();
+ bool layerWasSelfPainting = hadLayer && layer()->isSelfPaintingLayer();
RenderObject::styleDidChange(diff, oldStyle);
updateFromStyle();
@@ -136,7 +138,10 @@ void RenderLayerModelObject::styleDidChange(StyleDifference diff, const RenderSt
// FIXME: Ideally we shouldn't need this setter but we can't easily infer an overflow-only layer
// from the style.
layer()->setLayerType(type);
+
layer()->styleChanged(diff, oldStyle);
+ if (hadLayer && layer()->isSelfPaintingLayer() != layerWasSelfPainting)
+ setChildNeedsLayout();
}
if (FrameView *frameView = view()->frameView()) {
« no previous file with comments | « LayoutTests/TestExpectations ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698