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 ScrollAnimatorCompositorCoordinator_h | 5 #ifndef ScrollAnimatorCompositorCoordinator_h |
6 #define ScrollAnimatorCompositorCoordinator_h | 6 #define ScrollAnimatorCompositorCoordinator_h |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include "base/gtest_prod_util.h" | 9 #include "base/gtest_prod_util.h" |
10 #include "cc/animation/animation_curve.h" | 10 #include "cc/animation/animation_curve.h" |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 void CompositorAnimationFinished(int group_id); | 141 void CompositorAnimationFinished(int group_id); |
142 // Returns true if the compositor player was attached to a new layer. | 142 // Returns true if the compositor player was attached to a new layer. |
143 bool ReattachCompositorPlayerIfNeeded(CompositorAnimationTimeline*); | 143 bool ReattachCompositorPlayerIfNeeded(CompositorAnimationTimeline*); |
144 | 144 |
145 // CompositorAnimationDelegate implementation. | 145 // CompositorAnimationDelegate implementation. |
146 void NotifyAnimationStarted(double monotonic_time, int group) override; | 146 void NotifyAnimationStarted(double monotonic_time, int group) override; |
147 void NotifyAnimationFinished(double monotonic_time, int group) override; | 147 void NotifyAnimationFinished(double monotonic_time, int group) override; |
148 void NotifyAnimationAborted(double monotonic_time, int group) override; | 148 void NotifyAnimationAborted(double monotonic_time, int group) override; |
149 void NotifyAnimationTakeover(double monotonic_time, | 149 void NotifyAnimationTakeover(double monotonic_time, |
150 double animation_start_time, | 150 double animation_start_time, |
151 std::unique_ptr<cc::AnimationCurve>) override{}; | 151 std::unique_ptr<cc::AnimationCurve>) override {} |
152 | 152 |
153 // CompositorAnimationPlayerClient implementation. | 153 // CompositorAnimationPlayerClient implementation. |
154 CompositorAnimationPlayer* CompositorPlayer() const override; | 154 CompositorAnimationPlayer* CompositorPlayer() const override; |
155 | 155 |
156 friend class Internals; | 156 friend class Internals; |
157 // TODO(ymalik): Tests are added as friends to access m_RunState. Use the | 157 // TODO(ymalik): Tests are added as friends to access m_RunState. Use the |
158 // runStateForTesting accessor instead. | 158 // runStateForTesting accessor instead. |
159 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, MainThreadStates); | 159 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, MainThreadStates); |
160 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, AnimatedScrollTakeover); | 160 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, AnimatedScrollTakeover); |
161 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, CancellingAnimationResetsState); | 161 FRIEND_TEST_ALL_PREFIXES(ScrollAnimatorTest, CancellingAnimationResetsState); |
(...skipping 19 matching lines...) Expand all Loading... |
181 bool HasImplOnlyAnimationUpdate() const; | 181 bool HasImplOnlyAnimationUpdate() const; |
182 void UpdateImplOnlyCompositorAnimations(); | 182 void UpdateImplOnlyCompositorAnimations(); |
183 // Accesses compositing state and should only be called when in or after | 183 // Accesses compositing state and should only be called when in or after |
184 // DocumentLifecycle::LifecycleState::CompositingClean. | 184 // DocumentLifecycle::LifecycleState::CompositingClean. |
185 void TakeOverImplOnlyScrollOffsetAnimation(); | 185 void TakeOverImplOnlyScrollOffsetAnimation(); |
186 }; | 186 }; |
187 | 187 |
188 } // namespace blink | 188 } // namespace blink |
189 | 189 |
190 #endif // ScrollAnimatorCompositorCoordinator_h | 190 #endif // ScrollAnimatorCompositorCoordinator_h |
OLD | NEW |