Index: cc/animation/animation_host.h |
diff --git a/cc/animation/animation_host.h b/cc/animation/animation_host.h |
index 5839d599753d50fd138162b541bd1618cb1b4c3a..1edffb1453c7f0cdd99fc1bc02be95f8fc9228ad 100644 |
--- a/cc/animation/animation_host.h |
+++ b/cc/animation/animation_host.h |
@@ -13,7 +13,6 @@ |
#include "base/memory/ref_counted.h" |
#include "base/time/time.h" |
#include "cc/animation/animation.h" |
-#include "cc/animation/scroll_offset_animations_impl.h" |
#include "cc/base/cc_export.h" |
#include "cc/trees/mutator_host_client.h" |
#include "ui/gfx/geometry/box_f.h" |
@@ -30,6 +29,10 @@ class AnimationPlayer; |
class AnimationTimeline; |
class ElementAnimations; |
class LayerTreeHost; |
+class ScrollOffsetAnimations; |
+class ScrollOffsetAnimationsImpl; |
+ |
+struct ScrollOffsetAnimationUpdate; |
enum class ThreadInstance { MAIN, IMPL }; |
@@ -75,7 +78,9 @@ class CC_EXPORT AnimationHost { |
void SetNeedsCommit(); |
void SetNeedsRebuildPropertyTrees(); |
- void PushPropertiesTo(AnimationHost* host_impl); |
+ void PushPropertiesTo( |
+ AnimationHost* host_impl, |
+ base::TimeTicks frame_monotonic_time = base::TimeTicks()); |
void SetSupportsScrollAnimations(bool supports_scroll_animations); |
bool SupportsScrollAnimations() const; |
@@ -149,6 +154,11 @@ class CC_EXPORT AnimationHost { |
void ScrollAnimationAbort(bool needs_completion); |
+ // Adds an update to be made to impl-only animations during PushPropertiesTo. |
+ // This should only be called from the main thread. |
+ void AddScrollOffsetAnimationUpdate(ScrollOffsetAnimationUpdate); |
+ bool HasScrollOffsetAnimationUpdatesForTesting() const; |
loyso (OOO)
2016/05/06 01:04:38
It's better to have a general accessor:
ScrollOffs
ymalik
2016/05/06 05:41:49
Done.
|
+ |
// Registers the given element animations as active. An active element |
// animations is one that has a running animation that needs to be ticked. |
void DidActivateElementAnimations(ElementAnimations* element_animations); |
@@ -175,7 +185,8 @@ class CC_EXPORT AnimationHost { |
void PushTimelinesToImplThread(AnimationHost* host_impl) const; |
void RemoveTimelinesFromImplThread(AnimationHost* host_impl) const; |
- void PushPropertiesToImplThread(AnimationHost* host_impl); |
+ void PushPropertiesToImplThread(AnimationHost* host_impl, |
+ base::TimeTicks frame_monotonic_time); |
void EraseTimeline(scoped_refptr<AnimationTimeline> timeline); |
@@ -189,6 +200,7 @@ class CC_EXPORT AnimationHost { |
MutatorHostClient* mutator_host_client_; |
+ std::unique_ptr<ScrollOffsetAnimations> scroll_offset_animations_; |
std::unique_ptr<ScrollOffsetAnimationsImpl> scroll_offset_animations_impl_; |
const ThreadInstance thread_instance_; |