| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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_TREES_LAYER_TREE_HOST_IMPL_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| 6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 public ScrollbarAnimationControllerClient, | 135 public ScrollbarAnimationControllerClient, |
| 136 public base::SupportsWeakPtr<LayerTreeHostImpl> { | 136 public base::SupportsWeakPtr<LayerTreeHostImpl> { |
| 137 public: | 137 public: |
| 138 static scoped_ptr<LayerTreeHostImpl> Create( | 138 static scoped_ptr<LayerTreeHostImpl> Create( |
| 139 const LayerTreeSettings& settings, | 139 const LayerTreeSettings& settings, |
| 140 LayerTreeHostImplClient* client, | 140 LayerTreeHostImplClient* client, |
| 141 Proxy* proxy, | 141 Proxy* proxy, |
| 142 RenderingStatsInstrumentation* rendering_stats_instrumentation, | 142 RenderingStatsInstrumentation* rendering_stats_instrumentation, |
| 143 SharedBitmapManager* shared_bitmap_manager, | 143 SharedBitmapManager* shared_bitmap_manager, |
| 144 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager, | 144 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager, |
| 145 TaskGraphRunner* task_graph_runner, |
| 145 int id); | 146 int id); |
| 146 ~LayerTreeHostImpl() override; | 147 ~LayerTreeHostImpl() override; |
| 147 | 148 |
| 148 // InputHandler implementation | 149 // InputHandler implementation |
| 149 void BindToClient(InputHandlerClient* client) override; | 150 void BindToClient(InputHandlerClient* client) override; |
| 150 InputHandler::ScrollStatus ScrollBegin( | 151 InputHandler::ScrollStatus ScrollBegin( |
| 151 const gfx::Point& viewport_point, | 152 const gfx::Point& viewport_point, |
| 152 InputHandler::ScrollInputType type) override; | 153 InputHandler::ScrollInputType type) override; |
| 153 InputHandler::ScrollStatus ScrollAnimated( | 154 InputHandler::ScrollStatus ScrollAnimated( |
| 154 const gfx::Point& viewport_point, | 155 const gfx::Point& viewport_point, |
| (...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 524 } | 525 } |
| 525 | 526 |
| 526 protected: | 527 protected: |
| 527 LayerTreeHostImpl( | 528 LayerTreeHostImpl( |
| 528 const LayerTreeSettings& settings, | 529 const LayerTreeSettings& settings, |
| 529 LayerTreeHostImplClient* client, | 530 LayerTreeHostImplClient* client, |
| 530 Proxy* proxy, | 531 Proxy* proxy, |
| 531 RenderingStatsInstrumentation* rendering_stats_instrumentation, | 532 RenderingStatsInstrumentation* rendering_stats_instrumentation, |
| 532 SharedBitmapManager* shared_bitmap_manager, | 533 SharedBitmapManager* shared_bitmap_manager, |
| 533 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager, | 534 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager, |
| 535 TaskGraphRunner* task_graph_runner, |
| 534 int id); | 536 int id); |
| 535 | 537 |
| 536 // Virtual for testing. | 538 // Virtual for testing. |
| 537 virtual void AnimateLayers(base::TimeTicks monotonic_time); | 539 virtual void AnimateLayers(base::TimeTicks monotonic_time); |
| 538 | 540 |
| 539 bool is_likely_to_require_a_draw() const { | 541 bool is_likely_to_require_a_draw() const { |
| 540 return is_likely_to_require_a_draw_; | 542 return is_likely_to_require_a_draw_; |
| 541 } | 543 } |
| 542 | 544 |
| 543 LayerTreeHostImplClient* client_; | 545 LayerTreeHostImplClient* client_; |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 727 | 729 |
| 728 RenderingStatsInstrumentation* rendering_stats_instrumentation_; | 730 RenderingStatsInstrumentation* rendering_stats_instrumentation_; |
| 729 MicroBenchmarkControllerImpl micro_benchmark_controller_; | 731 MicroBenchmarkControllerImpl micro_benchmark_controller_; |
| 730 scoped_ptr<TaskGraphRunner> single_thread_synchronous_task_graph_runner_; | 732 scoped_ptr<TaskGraphRunner> single_thread_synchronous_task_graph_runner_; |
| 731 | 733 |
| 732 // Optional callback to notify of new tree activations. | 734 // Optional callback to notify of new tree activations. |
| 733 base::Closure tree_activation_callback_; | 735 base::Closure tree_activation_callback_; |
| 734 | 736 |
| 735 SharedBitmapManager* shared_bitmap_manager_; | 737 SharedBitmapManager* shared_bitmap_manager_; |
| 736 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager_; | 738 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager_; |
| 739 TaskGraphRunner* task_graph_runner_; |
| 737 int id_; | 740 int id_; |
| 738 | 741 |
| 739 std::set<SwapPromiseMonitor*> swap_promise_monitor_; | 742 std::set<SwapPromiseMonitor*> swap_promise_monitor_; |
| 740 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_; | 743 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_; |
| 741 | 744 |
| 742 bool requires_high_res_to_draw_; | 745 bool requires_high_res_to_draw_; |
| 743 bool is_likely_to_require_a_draw_; | 746 bool is_likely_to_require_a_draw_; |
| 744 | 747 |
| 745 scoped_ptr<FrameTimingTracker> frame_timing_tracker_; | 748 scoped_ptr<FrameTimingTracker> frame_timing_tracker_; |
| 746 | 749 |
| 747 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 750 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
| 748 }; | 751 }; |
| 749 | 752 |
| 750 } // namespace cc | 753 } // namespace cc |
| 751 | 754 |
| 752 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 755 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| OLD | NEW |