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

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

Issue 926963003: InlinedVisitor: Migrate animation to use inlined tracing (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 StyleInterpolation_h 5 #ifndef StyleInterpolation_h
6 #define StyleInterpolation_h 6 #define StyleInterpolation_h
7 7
8 #include "core/CSSPropertyNames.h" 8 #include "core/CSSPropertyNames.h"
9 #include "core/animation/Interpolation.h" 9 #include "core/animation/Interpolation.h"
10 10
(...skipping 20 matching lines...) Expand all
31 // (1) a CSSValue (and applied via StyleBuilder::applyProperty) 31 // (1) a CSSValue (and applied via StyleBuilder::applyProperty)
32 // (2) an AnimatableValue (and applied via // AnimatedStyleBuilder::applyPro perty) 32 // (2) an AnimatableValue (and applied via // AnimatedStyleBuilder::applyPro perty)
33 // (3) a custom value that is inserted directly into the StyleResolverState. 33 // (3) a custom value that is inserted directly into the StyleResolverState.
34 virtual void apply(StyleResolverState&) const = 0; 34 virtual void apply(StyleResolverState&) const = 0;
35 35
36 virtual bool isStyleInterpolation() const override final { return true; } 36 virtual bool isStyleInterpolation() const override final { return true; }
37 virtual bool isDeferredLegacyStyleInterpolation() const { return false; } 37 virtual bool isDeferredLegacyStyleInterpolation() const { return false; }
38 38
39 CSSPropertyID id() const { return m_id; } 39 CSSPropertyID id() const { return m_id; }
40 40
41 virtual void trace(Visitor* visitor) override 41 DEFINE_INLINE_VIRTUAL_TRACE()
42 { 42 {
43 Interpolation::trace(visitor); 43 Interpolation::trace(visitor);
44 } 44 }
45 45
46 protected: 46 protected:
47 CSSPropertyID m_id; 47 CSSPropertyID m_id;
48 48
49 StyleInterpolation(PassOwnPtrWillBeRawPtr<InterpolableValue> start, PassOwnP trWillBeRawPtr<InterpolableValue> end, CSSPropertyID id) 49 StyleInterpolation(PassOwnPtrWillBeRawPtr<InterpolableValue> start, PassOwnP trWillBeRawPtr<InterpolableValue> end, CSSPropertyID id)
50 : Interpolation(start, end) 50 : Interpolation(start, end)
51 , m_id(id) 51 , m_id(id)
52 { 52 {
53 } 53 }
54 }; 54 };
55 55
56 DEFINE_TYPE_CASTS(StyleInterpolation, Interpolation, value, value->isStyleInterp olation(), value.isStyleInterpolation()); 56 DEFINE_TYPE_CASTS(StyleInterpolation, Interpolation, value, value->isStyleInterp olation(), value.isStyleInterpolation());
57 57
58 } 58 }
59 59
60 #endif 60 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698