diff options
Diffstat (limited to 'Source/WebCore/svg/SVGElement.cpp')
-rw-r--r-- | Source/WebCore/svg/SVGElement.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/WebCore/svg/SVGElement.cpp b/Source/WebCore/svg/SVGElement.cpp index c1ffe858d..c80b257da 100644 --- a/Source/WebCore/svg/SVGElement.cpp +++ b/Source/WebCore/svg/SVGElement.cpp @@ -173,12 +173,14 @@ void SVGElement::setXmlbase(const String& value, ExceptionCode&) void SVGElement::removedFrom(ContainerNode* rootParent) { - if (rootParent->inDocument()) { + bool wasInDocument = rootParent->inDocument(); + + StyledElement::removedFrom(rootParent); + + if (wasInDocument) { document()->accessSVGExtensions()->removeAllAnimationElementsFromTarget(this); document()->accessSVGExtensions()->removeAllElementReferencesForTarget(this); } - - StyledElement::removedFrom(rootParent); } SVGSVGElement* SVGElement::ownerSVGElement() const |