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

Side by Side Diff: Source/core/animation/IntegerOptionalIntegerSVGInterpolation.h

Issue 1276183004: Oilpan: Unship oilpan from temporary animation objects (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 IntegerOptionalIntegerSVGInterpolation_h 5 #ifndef IntegerOptionalIntegerSVGInterpolation_h
6 #define IntegerOptionalIntegerSVGInterpolation_h 6 #define IntegerOptionalIntegerSVGInterpolation_h
7 7
8 #include "core/animation/SVGInterpolation.h" 8 #include "core/animation/SVGInterpolation.h"
9 #include "core/svg/SVGIntegerOptionalInteger.h" 9 #include "core/svg/SVGIntegerOptionalInteger.h"
10 #include "platform/heap/Handle.h" 10 #include "platform/heap/Handle.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 class SVGIntegerOptionalInteger; 14 class SVGIntegerOptionalInteger;
15 15
16 class IntegerOptionalIntegerSVGInterpolation : public SVGInterpolation { 16 class IntegerOptionalIntegerSVGInterpolation : public SVGInterpolation {
17 public: 17 public:
18 static PassRefPtrWillBeRawPtr<IntegerOptionalIntegerSVGInterpolation> create (SVGPropertyBase* start, SVGPropertyBase* end, PassRefPtrWillBeRawPtr<SVGAnimate dPropertyBase> attribute, int min) 18 static PassRefPtr<IntegerOptionalIntegerSVGInterpolation> create(SVGProperty Base* start, SVGPropertyBase* end, PassRefPtrWillBeRawPtr<SVGAnimatedPropertyBas e> attribute, int min)
19 { 19 {
20 return adoptRefWillBeNoop(new IntegerOptionalIntegerSVGInterpolation(toI nterpolableValue(start), toInterpolableValue(end), attribute, min)); 20 return adoptRef(new IntegerOptionalIntegerSVGInterpolation(toInterpolabl eValue(start), toInterpolableValue(end), attribute, min));
21 } 21 }
22 22
23 PassRefPtrWillBeRawPtr<SVGPropertyBase> interpolatedValue(SVGElement&) const final 23 PassRefPtrWillBeRawPtr<SVGPropertyBase> interpolatedValue(SVGElement&) const final
24 { 24 {
25 return fromInterpolableValue(*m_cachedValue, m_min); 25 return fromInterpolableValue(*m_cachedValue, m_min);
26 } 26 }
27 27
28 DEFINE_INLINE_VIRTUAL_TRACE()
29 {
30 SVGInterpolation::trace(visitor);
31 }
32
33 private: 28 private:
34 IntegerOptionalIntegerSVGInterpolation(PassOwnPtrWillBeRawPtr<InterpolableVa lue> start, PassOwnPtrWillBeRawPtr<InterpolableValue> end, PassRefPtrWillBeRawPt r<SVGAnimatedPropertyBase> attribute, int min) 29 IntegerOptionalIntegerSVGInterpolation(PassOwnPtr<InterpolableValue> start, PassOwnPtr<InterpolableValue> end, PassRefPtrWillBeRawPtr<SVGAnimatedPropertyBas e> attribute, int min)
35 : SVGInterpolation(start, end, attribute) 30 : SVGInterpolation(start, end, attribute)
36 , m_min(min) 31 , m_min(min)
37 { 32 {
38 } 33 }
39 34
40 static PassOwnPtrWillBeRawPtr<InterpolableValue> toInterpolableValue(SVGProp ertyBase*); 35 static PassOwnPtr<InterpolableValue> toInterpolableValue(SVGPropertyBase*);
41 36
42 static PassRefPtrWillBeRawPtr<SVGIntegerOptionalInteger> fromInterpolableVal ue(const InterpolableValue&, int); 37 static PassRefPtrWillBeRawPtr<SVGIntegerOptionalInteger> fromInterpolableVal ue(const InterpolableValue&, int);
43 38
44 const int m_min; 39 const int m_min;
45 }; 40 };
46 41
47 } 42 }
48 43
49 #endif // IntegerOptionalIntegerSVGInterpolation_h 44 #endif // IntegerOptionalIntegerSVGInterpolation_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698