summaryrefslogtreecommitdiff
path: root/src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp')
-rw-r--r--src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp31
1 files changed, 25 insertions, 6 deletions
diff --git a/src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp b/src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp
index 23292991d6..10da742a3f 100644
--- a/src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp
+++ b/src/3rdparty/webkit/WebCore/svg/SVGCircleElement.cpp
@@ -2,8 +2,6 @@
Copyright (C) 2004, 2005, 2006, 2008 Nikolas Zimmermann <zimmermann@kde.org>
2004, 2005, 2006, 2007 Rob Buis <buis@kde.org>
- This file is part of the KDE project
-
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
@@ -38,10 +36,9 @@ SVGCircleElement::SVGCircleElement(const QualifiedName& tagName, Document* doc)
, SVGTests()
, SVGLangSpace()
, SVGExternalResourcesRequired()
- , m_cx(this, SVGNames::cxAttr, LengthModeWidth)
- , m_cy(this, SVGNames::cyAttr, LengthModeHeight)
- , m_r(this, SVGNames::rAttr, LengthModeOther)
- , m_externalResourcesRequired(this, SVGNames::externalResourcesRequiredAttr, false)
+ , m_cx(LengthModeWidth)
+ , m_cy(LengthModeHeight)
+ , m_r(LengthModeOther)
{
}
@@ -86,6 +83,28 @@ void SVGCircleElement::svgAttributeChanged(const QualifiedName& attrName)
renderer()->setNeedsLayout(true);
}
+void SVGCircleElement::synchronizeProperty(const QualifiedName& attrName)
+{
+ SVGStyledTransformableElement::synchronizeProperty(attrName);
+
+ if (attrName == anyQName()) {
+ synchronizeCx();
+ synchronizeCy();
+ synchronizeR();
+ synchronizeExternalResourcesRequired();
+ return;
+ }
+
+ if (attrName == SVGNames::cxAttr)
+ synchronizeCx();
+ else if (attrName == SVGNames::cyAttr)
+ synchronizeCy();
+ else if (attrName == SVGNames::rAttr)
+ synchronizeR();
+ else if (SVGExternalResourcesRequired::isKnownAttribute(attrName))
+ synchronizeExternalResourcesRequired();
+}
+
Path SVGCircleElement::toPathData() const
{
return Path::createCircle(FloatPoint(cx().value(this), cy().value(this)), r().value(this));