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

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

Issue 204183002: Remove CompositableValue. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@opacity
Patch Set: Created 6 years, 9 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
« no previous file with comments | « Source/core/animation/Interpolation.cpp ('k') | Source/core/animation/KeyframeEffectModel.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 109
110 virtual bool isKeyframeEffectModel() const OVERRIDE { return true; } 110 virtual bool isKeyframeEffectModel() const OVERRIDE { return true; }
111 111
112 PropertySet properties() const; 112 PropertySet properties() const;
113 113
114 class PropertySpecificKeyframe { 114 class PropertySpecificKeyframe {
115 public: 115 public:
116 PropertySpecificKeyframe(double offset, PassRefPtr<TimingFunction> easin g, const AnimatableValue*, CompositeOperation); 116 PropertySpecificKeyframe(double offset, PassRefPtr<TimingFunction> easin g, const AnimatableValue*, CompositeOperation);
117 double offset() const { return m_offset; } 117 double offset() const { return m_offset; }
118 TimingFunction* easing() const { return m_easing.get(); } 118 TimingFunction* easing() const { return m_easing.get(); }
119 const CompositableValue* value() const { return m_value.get(); } 119 const AnimatableValue* value() const { return m_value.get(); }
120 PassOwnPtr<PropertySpecificKeyframe> cloneWithOffset(double offset) cons t; 120 PassOwnPtr<PropertySpecificKeyframe> cloneWithOffset(double offset) cons t;
121 private: 121 private:
122 // Used by cloneWithOffset(). 122 // Used by cloneWithOffset().
123 PropertySpecificKeyframe(double offset, PassRefPtr<TimingFunction> easin g, PassRefPtr<CompositableValue>); 123 PropertySpecificKeyframe(double offset, PassRefPtr<TimingFunction> easin g, PassRefPtr<AnimatableValue>);
124 double m_offset; 124 double m_offset;
125 RefPtr<TimingFunction> m_easing; 125 RefPtr<TimingFunction> m_easing;
126 RefPtr<CompositableValue> m_value; 126 RefPtr<AnimatableValue> m_value;
127 }; 127 };
128 128
129 class PropertySpecificKeyframeGroup { 129 class PropertySpecificKeyframeGroup {
130 public: 130 public:
131 void appendKeyframe(PassOwnPtr<PropertySpecificKeyframe>); 131 void appendKeyframe(PassOwnPtr<PropertySpecificKeyframe>);
132 const PropertySpecificKeyframeVector& keyframes() const { return m_keyfr ames; } 132 const PropertySpecificKeyframeVector& keyframes() const { return m_keyfr ames; }
133 private: 133 private:
134 PropertySpecificKeyframeVector m_keyframes; 134 PropertySpecificKeyframeVector m_keyframes;
135 void removeRedundantKeyframes(); 135 void removeRedundantKeyframes();
136 void addSyntheticKeyframeIfRequired(); 136 void addSyntheticKeyframeIfRequired();
(...skipping 28 matching lines...) Expand all
165 mutable RefPtr<InterpolationEffect> m_interpolationEffect; 165 mutable RefPtr<InterpolationEffect> m_interpolationEffect;
166 166
167 friend class KeyframeEffectModelTest; 167 friend class KeyframeEffectModelTest;
168 }; 168 };
169 169
170 DEFINE_TYPE_CASTS(KeyframeEffectModel, AnimationEffect, value, value->isKeyframe EffectModel(), value.isKeyframeEffectModel()); 170 DEFINE_TYPE_CASTS(KeyframeEffectModel, AnimationEffect, value, value->isKeyframe EffectModel(), value.isKeyframeEffectModel());
171 171
172 } // namespace WebCore 172 } // namespace WebCore
173 173
174 #endif // KeyframeEffectModel_h 174 #endif // KeyframeEffectModel_h
OLDNEW
« no previous file with comments | « Source/core/animation/Interpolation.cpp ('k') | Source/core/animation/KeyframeEffectModel.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698