| Index: Source/core/rendering/svg/RenderSVGRoot.h
|
| diff --git a/Source/core/rendering/svg/RenderSVGRoot.h b/Source/core/rendering/svg/RenderSVGRoot.h
|
| index 0d8c998b11e09f9d6246dae9ba2ffaa1eb46136e..6e1fc8187b25bff9dbfee8f8d224d54b3f30d3b8 100644
|
| --- a/Source/core/rendering/svg/RenderSVGRoot.h
|
| +++ b/Source/core/rendering/svg/RenderSVGRoot.h
|
| @@ -53,7 +53,15 @@ public:
|
| virtual void setNeedsTransformUpdate() OVERRIDE { m_needsBoundariesOrTransformUpdate = true; }
|
|
|
| IntSize containerSize() const { return m_containerSize; }
|
| - void setContainerSize(const IntSize& containerSize) { m_containerSize = containerSize; }
|
| + void setContainerSize(const IntSize& containerSize)
|
| + {
|
| + // SVGImage::draw() does a view layout prior to painting,
|
| + // and we need that layout to know of the new size otherwise
|
| + // the rendering may be incorrectly using the old size.
|
| + if (m_containerSize != containerSize)
|
| + setNeedsLayout();
|
| + m_containerSize = containerSize;
|
| + }
|
|
|
| virtual bool hasRelativeIntrinsicLogicalWidth() const OVERRIDE;
|
| virtual bool hasRelativeLogicalHeight() const OVERRIDE;
|
|
|