Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(655)

Unified Diff: third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h

Issue 2496583002: Refactor CSS property mapping for SMIL Animation (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h
diff --git a/third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h b/third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h
index d5ddacf79e61fd54d5f6ca02fdbe18c18a51cf38..2bea1a749043a8adad510a47653c70acc2ce3976 100644
--- a/third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h
+++ b/third_party/WebKit/Source/core/svg/SVGAnimatedTypeAnimator.h
@@ -21,6 +21,7 @@
#ifndef SVGAnimatedTypeAnimator_h
#define SVGAnimatedTypeAnimator_h
+#include "core/CSSPropertyNames.h"
#include "core/svg/properties/SVGPropertyInfo.h"
#include "platform/heap/Handle.h"
#include "wtf/text/WTFString.h"
@@ -39,18 +40,18 @@ class SVGAnimatedTypeAnimator final {
SVGAnimatedTypeAnimator(SVGAnimationElement*);
void clear();
- void reset(SVGElement* contextElement);
+ void reset(const SVGElement&);
SVGPropertyBase* createAnimatedValue() const;
SVGPropertyBase* createPropertyForAnimation(const String&) const;
- void setContextElement(SVGElement* contextElement) {
- m_contextElement = contextElement;
- }
AnimatedPropertyType type() const { return m_type; }
+ CSSPropertyID cssProperty() const { return m_cssProperty; }
bool isAnimatingSVGDom() const { return m_animatedProperty; }
- bool isAnimatingCSSProperty() const { return !m_animatedProperty; }
+ bool isAnimatingCSSProperty() const {
+ return m_cssProperty != CSSPropertyInvalid;
+ }
DECLARE_TRACE();
@@ -59,9 +60,9 @@ class SVGAnimatedTypeAnimator final {
SVGPropertyBase* createPropertyForCSSAnimation(const String&) const;
Member<SVGAnimationElement> m_animationElement;
- Member<SVGElement> m_contextElement;
Member<SVGAnimatedPropertyBase> m_animatedProperty;
AnimatedPropertyType m_type;
+ CSSPropertyID m_cssProperty;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698