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

Side by Side Diff: cc/animation/animation_host.h

Issue 1584743002: CC Animation: Replace AnimiationEventsVector with AnimiationEvents class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 11 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 | « cc/animation/animation_events.cc ('k') | cc/animation/animation_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_HOST_H_ 5 #ifndef CC_ANIMATION_ANIMATION_HOST_H_
6 #define CC_ANIMATION_ANIMATION_HOST_H_ 6 #define CC_ANIMATION_ANIMATION_HOST_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/containers/scoped_ptr_hash_map.h" 10 #include "base/containers/scoped_ptr_hash_map.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "base/time/time.h" 14 #include "base/time/time.h"
15 #include "cc/animation/animation_events.h" 15 #include "cc/animation/animation.h"
16 #include "cc/base/cc_export.h" 16 #include "cc/base/cc_export.h"
17 #include "cc/trees/mutator_host_client.h" 17 #include "cc/trees/mutator_host_client.h"
18 #include "ui/gfx/geometry/box_f.h"
19 #include "ui/gfx/geometry/vector2d_f.h"
18 20
19 namespace gfx { 21 namespace gfx {
20 class ScrollOffset; 22 class ScrollOffset;
21 } 23 }
22 24
23 namespace cc { 25 namespace cc {
24 26
27 class AnimationEvents;
25 class AnimationPlayer; 28 class AnimationPlayer;
26 class AnimationRegistrar; 29 class AnimationRegistrar;
27 class AnimationTimeline; 30 class AnimationTimeline;
28 class ElementAnimations; 31 class ElementAnimations;
29 class LayerAnimationController; 32 class LayerAnimationController;
30 class LayerTreeHost; 33 class LayerTreeHost;
31 34
32 enum class ThreadInstance { MAIN, IMPL }; 35 enum class ThreadInstance { MAIN, IMPL };
33 36
34 typedef std::vector<scoped_refptr<AnimationTimeline>> AnimationTimelineList; 37 typedef std::vector<scoped_refptr<AnimationTimeline>> AnimationTimelineList;
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 return animation_registrar_.get(); 84 return animation_registrar_.get();
82 } 85 }
83 86
84 void SetSupportsScrollAnimations(bool supports_scroll_animations); 87 void SetSupportsScrollAnimations(bool supports_scroll_animations);
85 bool SupportsScrollAnimations() const; 88 bool SupportsScrollAnimations() const;
86 bool NeedsAnimateLayers() const; 89 bool NeedsAnimateLayers() const;
87 90
88 bool ActivateAnimations(); 91 bool ActivateAnimations();
89 bool AnimateLayers(base::TimeTicks monotonic_time); 92 bool AnimateLayers(base::TimeTicks monotonic_time);
90 bool UpdateAnimationState(bool start_ready_animations, 93 bool UpdateAnimationState(bool start_ready_animations,
91 AnimationEventsVector* events); 94 AnimationEvents* events);
92 95
93 scoped_ptr<AnimationEventsVector> CreateEvents(); 96 scoped_ptr<AnimationEvents> CreateEvents();
94 void SetAnimationEvents(scoped_ptr<AnimationEventsVector> events); 97 void SetAnimationEvents(scoped_ptr<AnimationEvents> events);
95 98
96 bool ScrollOffsetAnimationWasInterrupted(int layer_id) const; 99 bool ScrollOffsetAnimationWasInterrupted(int layer_id) const;
97 100
98 bool IsAnimatingFilterProperty(int layer_id, LayerTreeType tree_type) const; 101 bool IsAnimatingFilterProperty(int layer_id, LayerTreeType tree_type) const;
99 bool IsAnimatingOpacityProperty(int layer_id, LayerTreeType tree_type) const; 102 bool IsAnimatingOpacityProperty(int layer_id, LayerTreeType tree_type) const;
100 bool IsAnimatingTransformProperty(int layer_id, 103 bool IsAnimatingTransformProperty(int layer_id,
101 LayerTreeType tree_type) const; 104 LayerTreeType tree_type) const;
102 105
103 bool HasPotentiallyRunningFilterAnimation(int layer_id, 106 bool HasPotentiallyRunningFilterAnimation(int layer_id,
104 LayerTreeType tree_type) const; 107 LayerTreeType tree_type) const;
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 scoped_ptr<ScrollOffsetAnimations> scroll_offset_animations_; 177 scoped_ptr<ScrollOffsetAnimations> scroll_offset_animations_;
175 178
176 const ThreadInstance thread_instance_; 179 const ThreadInstance thread_instance_;
177 180
178 DISALLOW_COPY_AND_ASSIGN(AnimationHost); 181 DISALLOW_COPY_AND_ASSIGN(AnimationHost);
179 }; 182 };
180 183
181 } // namespace cc 184 } // namespace cc
182 185
183 #endif // CC_ANIMATION_ANIMATION_HOST_H_ 186 #endif // CC_ANIMATION_ANIMATION_HOST_H_
OLDNEW
« no previous file with comments | « cc/animation/animation_events.cc ('k') | cc/animation/animation_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698