OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef SVGStrokeDasharrayStyleInterpolation_h | 5 #ifndef SVGStrokeDasharrayStyleInterpolation_h |
6 #define SVGStrokeDasharrayStyleInterpolation_h | 6 #define SVGStrokeDasharrayStyleInterpolation_h |
7 | 7 |
8 #include "core/animation/StyleInterpolation.h" | 8 #include "core/animation/StyleInterpolation.h" |
9 #include "core/css/CSSPrimitiveValue.h" | 9 #include "core/css/CSSPrimitiveValue.h" |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 class CSSValueList; | 13 class CSSValueList; |
14 | 14 |
15 class SVGStrokeDasharrayStyleInterpolation : public StyleInterpolation { | 15 class SVGStrokeDasharrayStyleInterpolation : public StyleInterpolation { |
16 public: | 16 public: |
17 static PassRefPtrWillBeRawPtr<SVGStrokeDasharrayStyleInterpolation> maybeCre
ate(const CSSValue& start, const CSSValue& end, CSSPropertyID); | 17 static PassRefPtrWillBeRawPtr<SVGStrokeDasharrayStyleInterpolation> maybeCre
ate(const CSSValue& start, const CSSValue& end, CSSPropertyID); |
18 | 18 |
19 virtual void apply(StyleResolverState&) const override; | 19 virtual void apply(StyleResolverState&) const override; |
20 | 20 |
21 virtual void trace(Visitor* visitor) override | 21 virtual void trace(Visitor* visitor) override |
22 { | 22 { |
23 StyleInterpolation::trace(visitor); | 23 StyleInterpolation::trace(visitor); |
24 } | 24 } |
25 | 25 |
26 private: | 26 private: |
27 SVGStrokeDasharrayStyleInterpolation(PassOwnPtrWillBeRawPtr<InterpolableValu
e> start, PassOwnPtrWillBeRawPtr<InterpolableValue> end, CSSPropertyID id, const
Vector<CSSPrimitiveValue::UnitType>& types) | 27 SVGStrokeDasharrayStyleInterpolation(PassOwnPtrWillBeRawPtr<InterpolableValu
e> start, PassOwnPtrWillBeRawPtr<InterpolableValue> end, CSSPropertyID id) |
28 : StyleInterpolation(start, end, id) | 28 : StyleInterpolation(start, end, id) |
29 , m_types(types) | |
30 { } | 29 { } |
31 | 30 |
32 static bool canCreateFrom(const CSSValue&); | 31 static bool canCreateFrom(const CSSValue&); |
33 static PassRefPtrWillBeRawPtr<CSSValueList> interpolableValueToStrokeDasharr
ay(const InterpolableValue&, const Vector<CSSPrimitiveValue::UnitType>&); | 32 static PassRefPtrWillBeRawPtr<CSSValueList> interpolableValueToStrokeDasharr
ay(const InterpolableValue&); |
34 | |
35 Vector<CSSPrimitiveValue::UnitType> m_types; | |
36 | 33 |
37 friend class AnimationSVGStrokeDasharrayStyleInterpolationTest; | 34 friend class AnimationSVGStrokeDasharrayStyleInterpolationTest; |
38 }; | 35 }; |
39 | 36 |
40 } | 37 } |
41 | 38 |
42 #endif // SVGStrokeDasharrayStyleInterpolation_h | 39 #endif // SVGStrokeDasharrayStyleInterpolation_h |
OLD | NEW |