| OLD | NEW |
| 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 CC_ANIMATION_ANIMATION_PLAYER_H_ | 5 #ifndef CC_ANIMATION_ANIMATION_PLAYER_H_ |
| 6 #define CC_ANIMATION_ANIMATION_PLAYER_H_ | 6 #define CC_ANIMATION_ANIMATION_PLAYER_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/containers/linked_list.h" | 10 #include "base/containers/linked_list.h" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 layer_animation_delegate_ = delegate; | 62 layer_animation_delegate_ = delegate; |
| 63 } | 63 } |
| 64 | 64 |
| 65 void AttachLayer(int layer_id); | 65 void AttachLayer(int layer_id); |
| 66 void DetachLayer(); | 66 void DetachLayer(); |
| 67 | 67 |
| 68 void AddAnimation(scoped_ptr<Animation> animation); | 68 void AddAnimation(scoped_ptr<Animation> animation); |
| 69 void PauseAnimation(int animation_id, double time_offset); | 69 void PauseAnimation(int animation_id, double time_offset); |
| 70 void RemoveAnimation(int animation_id); | 70 void RemoveAnimation(int animation_id); |
| 71 void AbortAnimation(int animation_id); | 71 void AbortAnimation(int animation_id); |
| 72 void AbortAnimations(Animation::TargetProperty target_property); | 72 void AbortAnimations(TargetProperty::Type target_property); |
| 73 | 73 |
| 74 void PushPropertiesTo(AnimationPlayer* player_impl); | 74 void PushPropertiesTo(AnimationPlayer* player_impl); |
| 75 | 75 |
| 76 // AnimationDelegate routing. | 76 // AnimationDelegate routing. |
| 77 void NotifyAnimationStarted(base::TimeTicks monotonic_time, | 77 void NotifyAnimationStarted(base::TimeTicks monotonic_time, |
| 78 Animation::TargetProperty target_property, | 78 TargetProperty::Type target_property, |
| 79 int group); | 79 int group); |
| 80 void NotifyAnimationFinished(base::TimeTicks monotonic_time, | 80 void NotifyAnimationFinished(base::TimeTicks monotonic_time, |
| 81 Animation::TargetProperty target_property, | 81 TargetProperty::Type target_property, |
| 82 int group); | 82 int group); |
| 83 void NotifyAnimationAborted(base::TimeTicks monotonic_time, | 83 void NotifyAnimationAborted(base::TimeTicks monotonic_time, |
| 84 Animation::TargetProperty target_property, | 84 TargetProperty::Type target_property, |
| 85 int group); | 85 int group); |
| 86 | 86 |
| 87 // Whether this player has animations waiting to get sent to LAC. | 87 // Whether this player has animations waiting to get sent to LAC. |
| 88 bool has_pending_animations_for_testing() const { | 88 bool has_pending_animations_for_testing() const { |
| 89 return !animations_.empty(); | 89 return !animations_.empty(); |
| 90 } | 90 } |
| 91 | 91 |
| 92 private: | 92 private: |
| 93 friend class base::RefCounted<AnimationPlayer>; | 93 friend class base::RefCounted<AnimationPlayer>; |
| 94 | 94 |
| (...skipping 21 matching lines...) Expand all Loading... |
| 116 | 116 |
| 117 int id_; | 117 int id_; |
| 118 int layer_id_; | 118 int layer_id_; |
| 119 | 119 |
| 120 DISALLOW_COPY_AND_ASSIGN(AnimationPlayer); | 120 DISALLOW_COPY_AND_ASSIGN(AnimationPlayer); |
| 121 }; | 121 }; |
| 122 | 122 |
| 123 } // namespace cc | 123 } // namespace cc |
| 124 | 124 |
| 125 #endif // CC_ANIMATION_ANIMATION_PLAYER_H_ | 125 #endif // CC_ANIMATION_ANIMATION_PLAYER_H_ |
| OLD | NEW |