summaryrefslogtreecommitdiff
path: root/Source/WebCore/svg/SVGAnimatedLength.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/svg/SVGAnimatedLength.h')
-rw-r--r--Source/WebCore/svg/SVGAnimatedLength.h29
1 files changed, 12 insertions, 17 deletions
diff --git a/Source/WebCore/svg/SVGAnimatedLength.h b/Source/WebCore/svg/SVGAnimatedLength.h
index e17a66d15..14a3460c7 100644
--- a/Source/WebCore/svg/SVGAnimatedLength.h
+++ b/Source/WebCore/svg/SVGAnimatedLength.h
@@ -17,21 +17,19 @@
* Boston, MA 02110-1301, USA.
*/
-#ifndef SVGAnimatedLength_h
-#define SVGAnimatedLength_h
+#pragma once
-#if ENABLE(SVG)
#include "SVGAnimatedPropertyTearOff.h"
#include "SVGAnimatedTypeAnimator.h"
#include "SVGLength.h"
namespace WebCore {
-typedef SVGAnimatedPropertyTearOff<SVGLength> SVGAnimatedLength;
+using SVGAnimatedLength = SVGAnimatedPropertyTearOff<SVGLength>;
// Helper macros to declare/define a SVGAnimatedLength object
#define DECLARE_ANIMATED_LENGTH(UpperProperty, LowerProperty) \
-DECLARE_ANIMATED_PROPERTY(SVGAnimatedLength, SVGLength, UpperProperty, LowerProperty)
+DECLARE_ANIMATED_PROPERTY(SVGAnimatedLength, SVGLengthValue, UpperProperty, LowerProperty, )
#define DEFINE_ANIMATED_LENGTH(OwnerType, DOMAttribute, UpperProperty, LowerProperty) \
DEFINE_ANIMATED_PROPERTY(AnimatedLength, OwnerType, DOMAttribute, DOMAttribute.localName(), UpperProperty, LowerProperty)
@@ -42,22 +40,19 @@ class SVGAnimatedLengthAnimator final : public SVGAnimatedTypeAnimator {
public:
SVGAnimatedLengthAnimator(SVGAnimationElement*, SVGElement*);
- virtual std::unique_ptr<SVGAnimatedType> constructFromString(const String&) override;
- virtual std::unique_ptr<SVGAnimatedType> startAnimValAnimation(const SVGElementAnimatedPropertyList&) override;
- virtual void stopAnimValAnimation(const SVGElementAnimatedPropertyList&) override;
- virtual void resetAnimValToBaseVal(const SVGElementAnimatedPropertyList&, SVGAnimatedType*) override;
- virtual void animValWillChange(const SVGElementAnimatedPropertyList&) override;
- virtual void animValDidChange(const SVGElementAnimatedPropertyList&) override;
+ std::unique_ptr<SVGAnimatedType> constructFromString(const String&) override;
+ std::unique_ptr<SVGAnimatedType> startAnimValAnimation(const SVGElementAnimatedPropertyList&) override;
+ void stopAnimValAnimation(const SVGElementAnimatedPropertyList&) override;
+ void resetAnimValToBaseVal(const SVGElementAnimatedPropertyList&, SVGAnimatedType&) override;
+ void animValWillChange(const SVGElementAnimatedPropertyList&) override;
+ void animValDidChange(const SVGElementAnimatedPropertyList&) override;
- virtual void addAnimatedTypes(SVGAnimatedType*, SVGAnimatedType*) override;
- virtual void calculateAnimatedValue(float percentage, unsigned repeatCount, SVGAnimatedType*, SVGAnimatedType*, SVGAnimatedType*, SVGAnimatedType*) override;
- virtual float calculateDistance(const String& fromString, const String& toString) override;
+ void addAnimatedTypes(SVGAnimatedType*, SVGAnimatedType*) override;
+ void calculateAnimatedValue(float percentage, unsigned repeatCount, SVGAnimatedType*, SVGAnimatedType*, SVGAnimatedType*, SVGAnimatedType*) override;
+ float calculateDistance(const String& fromString, const String& toString) override;
private:
SVGLengthMode m_lengthMode;
};
} // namespace WebCore
-
-#endif // ENABLE(SVG)
-#endif