Index: cc/trees/layer_tree_host_impl.h |
diff --git a/cc/trees/layer_tree_host_impl.h b/cc/trees/layer_tree_host_impl.h |
index ae69b0173c724fb6a48686df1368d6c2832ffa20..f42d71c55de3ae9fc8e9655118ec700f3107af89 100644 |
--- a/cc/trees/layer_tree_host_impl.h |
+++ b/cc/trees/layer_tree_host_impl.h |
@@ -32,6 +32,7 @@ |
#include "cc/resources/resource_provider.h" |
#include "cc/resources/tile_manager.h" |
#include "cc/scheduler/draw_swap_readback_result.h" |
+#include "cc/scheduler/frame_source.h" |
#include "skia/ext/refptr.h" |
#include "third_party/skia/include/core/SkColor.h" |
#include "ui/gfx/rect.h" |
@@ -64,13 +65,10 @@ class LayerTreeHostImplClient { |
public: |
virtual void UpdateRendererCapabilitiesOnImplThread() = 0; |
virtual void DidLoseOutputSurfaceOnImplThread() = 0; |
- virtual void CommitVSyncParameters(base::TimeTicks timebase, |
- base::TimeDelta interval) = 0; |
virtual void SetEstimatedParentDrawTime(base::TimeDelta draw_time) = 0; |
virtual void SetMaxSwapsPendingOnImplThread(int max) = 0; |
virtual void DidSwapBuffersOnImplThread() = 0; |
virtual void DidSwapBuffersCompleteOnImplThread() = 0; |
- virtual void BeginFrame(const BeginFrameArgs& args) = 0; |
virtual void OnCanDrawStateChanged(bool can_draw) = 0; |
virtual void NotifyReadyToActivate() = 0; |
// Please call these 3 functions through |
@@ -110,6 +108,7 @@ class CC_EXPORT LayerTreeHostImpl |
public OutputSurfaceClient, |
public TopControlsManagerClient, |
public ScrollbarAnimationControllerClient, |
+ public BaseFrameSource, |
public base::SupportsWeakPtr<LayerTreeHostImpl> { |
public: |
static scoped_ptr<LayerTreeHostImpl> Create( |
@@ -182,7 +181,6 @@ class CC_EXPORT LayerTreeHostImpl |
virtual void UpdateAnimationState(bool start_ready_animations); |
void ActivateAnimations(); |
void MainThreadHasStoppedFlinging(); |
- void UpdateBackgroundAnimateTicking(bool should_background_tick); |
void DidAnimateScrollOffset(); |
void SetViewportDamage(const gfx::Rect& damage_rect); |
@@ -258,6 +256,14 @@ class CC_EXPORT LayerTreeHostImpl |
virtual void SetTreeActivationCallback(const base::Closure& callback) |
OVERRIDE; |
+ // FrameSource implementation. |
+ virtual void SetNeedsBeginFrame(bool needs_begin_frame) OVERRIDE; |
+ virtual void SetSink(FrameSink* sink) OVERRIDE; |
+ virtual void SetTimeBaseAndInterval(base::TimeTicks timebase, |
+ base::TimeDelta interval) OVERRIDE; |
+ virtual scoped_ptr<base::Value> FrameSourceAsValue() const OVERRIDE; |
+ virtual std::string FrameSourceType() const OVERRIDE; |
+ |
// Called from LayerTreeImpl. |
void OnCanDrawStateChangedForTree(); |
@@ -278,7 +284,6 @@ class CC_EXPORT LayerTreeHostImpl |
const RendererCapabilitiesImpl& GetRendererCapabilities() const; |
virtual bool SwapBuffers(const FrameData& frame); |
- void SetNeedsBeginFrame(bool enable); |
virtual void WillBeginImplFrame(const BeginFrameArgs& args); |
void DidModifyTilePriorities(); |
@@ -601,9 +606,6 @@ class CC_EXPORT LayerTreeHostImpl |
scoped_ptr<PageScaleAnimation> page_scale_animation_; |
- // This is used for ticking animations slowly when hidden. |
- scoped_ptr<LayerTreeHostImplTimeSourceAdapter> time_source_client_adapter_; |
- |
scoped_ptr<FrameRateCounter> fps_counter_; |
scoped_ptr<PaintTimeCounter> paint_time_counter_; |
scoped_ptr<MemoryHistory> memory_history_; |