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 #ifndef CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ | 5 #ifndef CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ |
6 #define CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ | 6 #define CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/hash_tables.h" | 9 #include "base/hash_tables.h" |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 | 86 |
87 void SetAnimationRegistrar(AnimationRegistrar* registrar); | 87 void SetAnimationRegistrar(AnimationRegistrar* registrar); |
88 AnimationRegistrar* animation_registrar() { return registrar_; } | 88 AnimationRegistrar* animation_registrar() { return registrar_; } |
89 | 89 |
90 void AddObserver(LayerAnimationValueObserver* observer); | 90 void AddObserver(LayerAnimationValueObserver* observer); |
91 void RemoveObserver(LayerAnimationValueObserver* observer); | 91 void RemoveObserver(LayerAnimationValueObserver* observer); |
92 | 92 |
93 protected: | 93 protected: |
94 friend class base::RefCounted<LayerAnimationController>; | 94 friend class base::RefCounted<LayerAnimationController>; |
95 | 95 |
96 LayerAnimationController(int id); | 96 explicit LayerAnimationController(int id); |
97 virtual ~LayerAnimationController(); | 97 virtual ~LayerAnimationController(); |
98 | 98 |
99 private: | 99 private: |
100 typedef base::hash_set<int> TargetProperties; | 100 typedef base::hash_set<int> TargetProperties; |
101 | 101 |
102 void PushNewAnimationsToImplThread( | 102 void PushNewAnimationsToImplThread( |
103 LayerAnimationController* controller_impl) const; | 103 LayerAnimationController* controller_impl) const; |
104 void RemoveAnimationsCompletedOnMainThread( | 104 void RemoveAnimationsCompletedOnMainThread( |
105 LayerAnimationController* controller_impl) const; | 105 LayerAnimationController* controller_impl) const; |
106 void PushPropertiesToImplThread( | 106 void PushPropertiesToImplThread( |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
145 double last_tick_time_; | 145 double last_tick_time_; |
146 | 146 |
147 ObserverList<LayerAnimationValueObserver> observers_; | 147 ObserverList<LayerAnimationValueObserver> observers_; |
148 | 148 |
149 DISALLOW_COPY_AND_ASSIGN(LayerAnimationController); | 149 DISALLOW_COPY_AND_ASSIGN(LayerAnimationController); |
150 }; | 150 }; |
151 | 151 |
152 } // namespace cc | 152 } // namespace cc |
153 | 153 |
154 #endif // CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ | 154 #endif // CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ |
OLD | NEW |