Index: Source/WebCore/rendering/svg/RenderSVGInline.cpp |
=================================================================== |
--- Source/WebCore/rendering/svg/RenderSVGInline.cpp (revision 118874) |
+++ Source/WebCore/rendering/svg/RenderSVGInline.cpp (working copy) |
@@ -124,9 +124,24 @@ |
{ |
RenderInline::addChild(child, beforeChild); |
if (RenderSVGText* textRenderer = RenderSVGText::locateRenderSVGTextAncestor(this)) |
- textRenderer->layoutAttributesChanged(child); |
+ textRenderer->subtreeChildWasAdded(child); |
} |
+void RenderSVGInline::removeChild(RenderObject* child) |
+{ |
+ RenderSVGText* textRenderer = child->isSVGInlineText() ? RenderSVGText::locateRenderSVGTextAncestor(this) : 0; |
+ if (!textRenderer) { |
+ RenderInline::removeChild(child); |
+ return; |
+ } |
+ |
+ RenderSVGInlineText* text = toRenderSVGInlineText(child); |
+ Vector<SVGTextLayoutAttributes*, 2> affectedAttributes; |
+ textRenderer->subtreeChildWillBeRemoved(text, affectedAttributes); |
+ RenderInline::removeChild(child); |
+ textRenderer->subtreeChildWasRemoved(affectedAttributes); |
} |
+} |
+ |
#endif // ENABLE(SVG) |