summaryrefslogtreecommitdiff
path: root/Source/WebCore/svg/SVGAnimatedRect.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/svg/SVGAnimatedRect.h')
-rw-r--r--Source/WebCore/svg/SVGAnimatedRect.h31
1 files changed, 14 insertions, 17 deletions
diff --git a/Source/WebCore/svg/SVGAnimatedRect.h b/Source/WebCore/svg/SVGAnimatedRect.h
index c369ec8ea..c8fce4bed 100644
--- a/Source/WebCore/svg/SVGAnimatedRect.h
+++ b/Source/WebCore/svg/SVGAnimatedRect.h
@@ -17,10 +17,8 @@
* Boston, MA 02110-1301, USA.
*/
-#ifndef SVGAnimatedRect_h
-#define SVGAnimatedRect_h
+#pragma once
-#if ENABLE(SVG)
#include "SVGAnimatedPropertyMacros.h"
#include "SVGAnimatedPropertyTearOff.h"
#include "SVGAnimatedTypeAnimator.h"
@@ -28,11 +26,13 @@
namespace WebCore {
-typedef SVGAnimatedPropertyTearOff<FloatRect> SVGAnimatedRect;
+class SVGRect;
+
+using SVGAnimatedRect = SVGAnimatedPropertyTearOff<SVGRect>;
// Helper macros to declare/define a SVGAnimatedRect object
#define DECLARE_ANIMATED_RECT(UpperProperty, LowerProperty) \
-DECLARE_ANIMATED_PROPERTY(SVGAnimatedRect, FloatRect, UpperProperty, LowerProperty)
+DECLARE_ANIMATED_PROPERTY(SVGAnimatedRect, FloatRect, UpperProperty, LowerProperty, )
#define DEFINE_ANIMATED_RECT(OwnerType, DOMAttribute, UpperProperty, LowerProperty) \
DEFINE_ANIMATED_PROPERTY(AnimatedRect, OwnerType, DOMAttribute, DOMAttribute.localName(), UpperProperty, LowerProperty)
@@ -43,21 +43,18 @@ class SVGAnimatedRectAnimator final : public SVGAnimatedTypeAnimator {
public:
SVGAnimatedRectAnimator(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;
static bool parseSVGRect(const String&, FloatRect&);
};
} // namespace WebCore
-
-#endif // ENABLE(SVG)
-#endif