| 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_ANIMATION_H_ | 5 #ifndef CC_ANIMATION_ANIMATION_H_ |
| 6 #define CC_ANIMATION_ANIMATION_H_ | 6 #define CC_ANIMATION_ANIMATION_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 private: | 167 private: |
| 168 Animation(scoped_ptr<AnimationCurve> curve, | 168 Animation(scoped_ptr<AnimationCurve> curve, |
| 169 int animation_id, | 169 int animation_id, |
| 170 int group_id, | 170 int group_id, |
| 171 TargetProperty target_property); | 171 TargetProperty target_property); |
| 172 | 172 |
| 173 base::TimeDelta ConvertToActiveTime(base::TimeTicks monotonic_time) const; | 173 base::TimeDelta ConvertToActiveTime(base::TimeTicks monotonic_time) const; |
| 174 | 174 |
| 175 scoped_ptr<AnimationCurve> curve_; | 175 scoped_ptr<AnimationCurve> curve_; |
| 176 | 176 |
| 177 // IDs are not necessarily unique. | 177 // IDs must be unique. |
| 178 int id_; | 178 int id_; |
| 179 | 179 |
| 180 // Animations that must be run together are called 'grouped' and have the same | 180 // Animations that must be run together are called 'grouped' and have the same |
| 181 // group id. Grouped animations are guaranteed to start at the same time and | 181 // group id. Grouped animations are guaranteed to start at the same time and |
| 182 // no other animations may animate any of the group's target properties until | 182 // no other animations may animate any of the group's target properties until |
| 183 // all animations in the group have finished animating. Note: an active | 183 // all animations in the group have finished animating. |
| 184 // animation's group id and target property uniquely identify that animation. | |
| 185 int group_; | 184 int group_; |
| 186 | 185 |
| 187 TargetProperty target_property_; | 186 TargetProperty target_property_; |
| 188 RunState run_state_; | 187 RunState run_state_; |
| 189 double iterations_; | 188 double iterations_; |
| 190 double iteration_start_; | 189 double iteration_start_; |
| 191 base::TimeTicks start_time_; | 190 base::TimeTicks start_time_; |
| 192 Direction direction_; | 191 Direction direction_; |
| 193 double playback_rate_; | 192 double playback_rate_; |
| 194 FillMode fill_mode_; | 193 FillMode fill_mode_; |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 238 // longer affect any observers, and are deleted. | 237 // longer affect any observers, and are deleted. |
| 239 bool affects_active_observers_; | 238 bool affects_active_observers_; |
| 240 bool affects_pending_observers_; | 239 bool affects_pending_observers_; |
| 241 | 240 |
| 242 DISALLOW_COPY_AND_ASSIGN(Animation); | 241 DISALLOW_COPY_AND_ASSIGN(Animation); |
| 243 }; | 242 }; |
| 244 | 243 |
| 245 } // namespace cc | 244 } // namespace cc |
| 246 | 245 |
| 247 #endif // CC_ANIMATION_ANIMATION_H_ | 246 #endif // CC_ANIMATION_ANIMATION_H_ |
| OLD | NEW |