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

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

Issue 1303173007: Oilpan: Unship Oilpan from CSSValues 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 ConstantStyleInterpolation_h 5 #ifndef ConstantStyleInterpolation_h
6 #define ConstantStyleInterpolation_h 6 #define ConstantStyleInterpolation_h
7 7
8 #include "core/animation/StyleInterpolation.h" 8 #include "core/animation/StyleInterpolation.h"
9 #include "core/css/resolver/StyleBuilder.h" 9 #include "core/css/resolver/StyleBuilder.h"
10 10
11 namespace blink { 11 namespace blink {
12 12
13 class ConstantStyleInterpolation : public StyleInterpolation { 13 class ConstantStyleInterpolation : public StyleInterpolation {
14 public: 14 public:
15 static PassRefPtrWillBeRawPtr<ConstantStyleInterpolation> create(CSSValue* v alue, CSSPropertyID id) 15 static PassRefPtrWillBeRawPtr<ConstantStyleInterpolation> create(CSSValue* v alue, CSSPropertyID id)
16 { 16 {
17 return adoptRefWillBeNoop(new ConstantStyleInterpolation(value, id)); 17 return adoptRefWillBeNoop(new ConstantStyleInterpolation(value, id));
18 } 18 }
19 19
20 void apply(StyleResolverState& state) const override 20 void apply(StyleResolverState& state) const override
21 { 21 {
22 StyleBuilder::applyProperty(m_id, state, m_value.get()); 22 StyleBuilder::applyProperty(m_id, state, m_value.get());
23 } 23 }
24 24
25 DEFINE_INLINE_VIRTUAL_TRACE() 25 DEFINE_INLINE_VIRTUAL_TRACE()
26 { 26 {
27 StyleInterpolation::trace(visitor); 27 StyleInterpolation::trace(visitor);
28 visitor->trace(m_value);
29 } 28 }
30 29
31 private: 30 private:
32 ConstantStyleInterpolation(CSSValue* value, CSSPropertyID id) 31 ConstantStyleInterpolation(CSSValue* value, CSSPropertyID id)
33 : StyleInterpolation(InterpolableList::create(0), InterpolableList::crea te(0), id) 32 : StyleInterpolation(InterpolableList::create(0), InterpolableList::crea te(0), id)
34 , m_value(value) 33 , m_value(value)
35 { } 34 { }
36 35
37 RefPtrWillBeMember<CSSValue> m_value; 36 RefPtr<CSSValue> m_value;
38 }; 37 };
39 38
40 } 39 }
41 40
42 #endif 41 #endif
OLDNEW
« no previous file with comments | « Source/core/animation/ColorStyleInterpolationTest.cpp ('k') | Source/core/animation/DeferredLegacyStyleInterpolation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698