OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 #include "cc/test/animation_test_common.h" | 5 #include "cc/test/animation_test_common.h" |
6 | 6 |
7 #include "cc/keyframed_animation_curve.h" | 7 #include "cc/keyframed_animation_curve.h" |
8 #include "cc/layer.h" | 8 #include "cc/layer.h" |
9 #include "cc/layer_animation_controller.h" | 9 #include "cc/layer_animation_controller.h" |
10 #include "cc/layer_impl.h" | 10 #include "cc/layer_impl.h" |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 void FakeLayerAnimationValueObserver::OnOpacityAnimated(float opacity) | 158 void FakeLayerAnimationValueObserver::OnOpacityAnimated(float opacity) |
159 { | 159 { |
160 m_opacity = opacity; | 160 m_opacity = opacity; |
161 } | 161 } |
162 | 162 |
163 void FakeLayerAnimationValueObserver::OnTransformAnimated(const gfx::Transform&
transform) | 163 void FakeLayerAnimationValueObserver::OnTransformAnimated(const gfx::Transform&
transform) |
164 { | 164 { |
165 m_transform = transform; | 165 m_transform = transform; |
166 } | 166 } |
167 | 167 |
| 168 bool FakeLayerAnimationValueObserver::IsActive() const |
| 169 { |
| 170 return true; |
| 171 } |
| 172 |
168 scoped_ptr<cc::AnimationCurve> FakeFloatTransition::clone() const | 173 scoped_ptr<cc::AnimationCurve> FakeFloatTransition::clone() const |
169 { | 174 { |
170 return make_scoped_ptr(new FakeFloatTransition(*this)).PassAs<cc::AnimationC
urve>(); | 175 return make_scoped_ptr(new FakeFloatTransition(*this)).PassAs<cc::AnimationC
urve>(); |
171 } | 176 } |
172 | 177 |
173 int addOpacityTransitionToController(cc::LayerAnimationController& controller, d
ouble duration, float startOpacity, float endOpacity, bool useTimingFunction) | 178 int addOpacityTransitionToController(cc::LayerAnimationController& controller, d
ouble duration, float startOpacity, float endOpacity, bool useTimingFunction) |
174 { | 179 { |
175 return addOpacityTransition(controller, duration, startOpacity, endOpacity,
useTimingFunction); | 180 return addOpacityTransition(controller, duration, startOpacity, endOpacity,
useTimingFunction); |
176 } | 181 } |
177 | 182 |
(...skipping 16 matching lines...) Expand all Loading... |
194 { | 199 { |
195 return addAnimatedTransform(layer, duration, deltaX, deltaY); | 200 return addAnimatedTransform(layer, duration, deltaX, deltaY); |
196 } | 201 } |
197 | 202 |
198 int addAnimatedTransformToLayer(cc::LayerImpl& layer, double duration, int delta
X, int deltaY) | 203 int addAnimatedTransformToLayer(cc::LayerImpl& layer, double duration, int delta
X, int deltaY) |
199 { | 204 { |
200 return addAnimatedTransform(*layer.layerAnimationController(), duration, del
taX, deltaY); | 205 return addAnimatedTransform(*layer.layerAnimationController(), duration, del
taX, deltaY); |
201 } | 206 } |
202 | 207 |
203 } // namespace cc | 208 } // namespace cc |
OLD | NEW |