| 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 <list> | 8 #include <list> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 #include "cc/input/input_handler.h" | 22 #include "cc/input/input_handler.h" |
| 23 #include "cc/input/layer_scroll_offset_delegate.h" | 23 #include "cc/input/layer_scroll_offset_delegate.h" |
| 24 #include "cc/input/top_controls_manager_client.h" | 24 #include "cc/input/top_controls_manager_client.h" |
| 25 #include "cc/layers/layer_lists.h" | 25 #include "cc/layers/layer_lists.h" |
| 26 #include "cc/layers/render_pass_sink.h" | 26 #include "cc/layers/render_pass_sink.h" |
| 27 #include "cc/output/begin_frame_args.h" | 27 #include "cc/output/begin_frame_args.h" |
| 28 #include "cc/output/managed_memory_policy.h" | 28 #include "cc/output/managed_memory_policy.h" |
| 29 #include "cc/output/output_surface_client.h" | 29 #include "cc/output/output_surface_client.h" |
| 30 #include "cc/output/renderer.h" | 30 #include "cc/output/renderer.h" |
| 31 #include "cc/quads/render_pass.h" | 31 #include "cc/quads/render_pass.h" |
| 32 #include "cc/resources/eviction_tile_priority_queue.h" |
| 33 #include "cc/resources/raster_tile_priority_queue.h" |
| 32 #include "cc/resources/resource_provider.h" | 34 #include "cc/resources/resource_provider.h" |
| 33 #include "cc/resources/tile_manager.h" | 35 #include "cc/resources/tile_manager.h" |
| 34 #include "cc/scheduler/draw_result.h" | 36 #include "cc/scheduler/draw_result.h" |
| 35 #include "skia/ext/refptr.h" | 37 #include "skia/ext/refptr.h" |
| 36 #include "third_party/skia/include/core/SkColor.h" | 38 #include "third_party/skia/include/core/SkColor.h" |
| 37 #include "ui/gfx/rect.h" | 39 #include "ui/gfx/rect.h" |
| 38 | 40 |
| 39 namespace cc { | 41 namespace cc { |
| 40 | 42 |
| 41 class CompletionEvent; | 43 class CompletionEvent; |
| (...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 // excludes the URL bar and non-overlay scrollbars and is in DIP (and | 228 // excludes the URL bar and non-overlay scrollbars and is in DIP (and |
| 227 // invariant relative to page scale). | 229 // invariant relative to page scale). |
| 228 gfx::SizeF UnscaledScrollableViewportSize() const; | 230 gfx::SizeF UnscaledScrollableViewportSize() const; |
| 229 float VerticalAdjust() const; | 231 float VerticalAdjust() const; |
| 230 | 232 |
| 231 // RendererClient implementation. | 233 // RendererClient implementation. |
| 232 virtual void SetFullRootLayerDamage() OVERRIDE; | 234 virtual void SetFullRootLayerDamage() OVERRIDE; |
| 233 virtual void RunOnDemandRasterTask(Task* on_demand_raster_task) OVERRIDE; | 235 virtual void RunOnDemandRasterTask(Task* on_demand_raster_task) OVERRIDE; |
| 234 | 236 |
| 235 // TileManagerClient implementation. | 237 // TileManagerClient implementation. |
| 236 virtual const std::vector<PictureLayerImpl*>& GetPictureLayers() OVERRIDE; | 238 virtual const std::vector<PictureLayerImpl*>& GetPictureLayers() |
| 239 const OVERRIDE; |
| 237 virtual void NotifyReadyToActivate() OVERRIDE; | 240 virtual void NotifyReadyToActivate() OVERRIDE; |
| 238 virtual void NotifyTileStateChanged(const Tile* tile) OVERRIDE; | 241 virtual void NotifyTileStateChanged(const Tile* tile) OVERRIDE; |
| 242 virtual TilePriorityQueue* RebuildRasterQueue( |
| 243 TreePriority tree_priority) OVERRIDE; |
| 244 virtual TilePriorityQueue* RebuildEvictionQueue( |
| 245 TreePriority tree_prirority) OVERRIDE; |
| 239 | 246 |
| 240 // ScrollbarAnimationControllerClient implementation. | 247 // ScrollbarAnimationControllerClient implementation. |
| 241 virtual void PostDelayedScrollbarFade(const base::Closure& start_fade, | 248 virtual void PostDelayedScrollbarFade(const base::Closure& start_fade, |
| 242 base::TimeDelta delay) OVERRIDE; | 249 base::TimeDelta delay) OVERRIDE; |
| 243 virtual void SetNeedsScrollbarAnimationFrame() OVERRIDE; | 250 virtual void SetNeedsScrollbarAnimationFrame() OVERRIDE; |
| 244 | 251 |
| 245 // OutputSurfaceClient implementation. | 252 // OutputSurfaceClient implementation. |
| 246 virtual void DeferredInitialize() OVERRIDE; | 253 virtual void DeferredInitialize() OVERRIDE; |
| 247 virtual void ReleaseGL() OVERRIDE; | 254 virtual void ReleaseGL() OVERRIDE; |
| 248 virtual void CommitVSyncParameters(base::TimeTicks timebase, | 255 virtual void CommitVSyncParameters(base::TimeTicks timebase, |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 458 // When a SwapPromiseMonitor is created on the impl thread, it calls | 465 // When a SwapPromiseMonitor is created on the impl thread, it calls |
| 459 // InsertSwapPromiseMonitor() to register itself with LayerTreeHostImpl. | 466 // InsertSwapPromiseMonitor() to register itself with LayerTreeHostImpl. |
| 460 // When the monitor is destroyed, it calls RemoveSwapPromiseMonitor() | 467 // When the monitor is destroyed, it calls RemoveSwapPromiseMonitor() |
| 461 // to unregister itself. | 468 // to unregister itself. |
| 462 void InsertSwapPromiseMonitor(SwapPromiseMonitor* monitor); | 469 void InsertSwapPromiseMonitor(SwapPromiseMonitor* monitor); |
| 463 void RemoveSwapPromiseMonitor(SwapPromiseMonitor* monitor); | 470 void RemoveSwapPromiseMonitor(SwapPromiseMonitor* monitor); |
| 464 | 471 |
| 465 void RegisterPictureLayerImpl(PictureLayerImpl* layer); | 472 void RegisterPictureLayerImpl(PictureLayerImpl* layer); |
| 466 void UnregisterPictureLayerImpl(PictureLayerImpl* layer); | 473 void UnregisterPictureLayerImpl(PictureLayerImpl* layer); |
| 467 | 474 |
| 475 void GetPairedPictureLayers(std::vector<PairedPictureLayer>* layers) const; |
| 476 |
| 468 protected: | 477 protected: |
| 469 LayerTreeHostImpl( | 478 LayerTreeHostImpl( |
| 470 const LayerTreeSettings& settings, | 479 const LayerTreeSettings& settings, |
| 471 LayerTreeHostImplClient* client, | 480 LayerTreeHostImplClient* client, |
| 472 Proxy* proxy, | 481 Proxy* proxy, |
| 473 RenderingStatsInstrumentation* rendering_stats_instrumentation, | 482 RenderingStatsInstrumentation* rendering_stats_instrumentation, |
| 474 SharedBitmapManager* manager, | 483 SharedBitmapManager* manager, |
| 475 int id); | 484 int id); |
| 476 | 485 |
| 477 gfx::SizeF ComputeInnerViewportContainerSize() const; | 486 gfx::SizeF ComputeInnerViewportContainerSize() const; |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 690 | 699 |
| 691 SharedBitmapManager* shared_bitmap_manager_; | 700 SharedBitmapManager* shared_bitmap_manager_; |
| 692 int id_; | 701 int id_; |
| 693 | 702 |
| 694 std::set<SwapPromiseMonitor*> swap_promise_monitor_; | 703 std::set<SwapPromiseMonitor*> swap_promise_monitor_; |
| 695 | 704 |
| 696 size_t transfer_buffer_memory_limit_; | 705 size_t transfer_buffer_memory_limit_; |
| 697 | 706 |
| 698 std::vector<PictureLayerImpl*> picture_layers_; | 707 std::vector<PictureLayerImpl*> picture_layers_; |
| 699 | 708 |
| 709 RasterTilePriorityQueue raster_queue_; |
| 710 EvictionTilePriorityQueue eviction_queue_; |
| 711 |
| 700 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 712 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
| 701 }; | 713 }; |
| 702 | 714 |
| 703 } // namespace cc | 715 } // namespace cc |
| 704 | 716 |
| 705 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 717 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| OLD | NEW |