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_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_H_ |
6 #define CC_TREES_LAYER_TREE_HOST_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 class Layer; | 53 class Layer; |
54 class LayerTreeHostClient; | 54 class LayerTreeHostClient; |
55 class LayerTreeHostImpl; | 55 class LayerTreeHostImpl; |
56 class LayerTreeHostImplClient; | 56 class LayerTreeHostImplClient; |
57 class LayerTreeHostSingleThreadClient; | 57 class LayerTreeHostSingleThreadClient; |
58 class LayerTreeMutator; | 58 class LayerTreeMutator; |
59 class MutatorEvents; | 59 class MutatorEvents; |
60 class MutatorHost; | 60 class MutatorHost; |
61 struct PendingPageScaleAnimation; | 61 struct PendingPageScaleAnimation; |
62 class RenderingStatsInstrumentation; | 62 class RenderingStatsInstrumentation; |
| 63 struct ScrollBoundaryBehavior; |
63 class TaskGraphRunner; | 64 class TaskGraphRunner; |
64 class UIResourceManager; | 65 class UIResourceManager; |
65 struct RenderingStats; | 66 struct RenderingStats; |
66 struct ScrollAndScaleSet; | 67 struct ScrollAndScaleSet; |
67 | 68 |
68 class CC_EXPORT LayerTreeHost | 69 class CC_EXPORT LayerTreeHost |
69 : public NON_EXPORTED_BASE(viz::SurfaceReferenceOwner), | 70 : public NON_EXPORTED_BASE(viz::SurfaceReferenceOwner), |
70 public NON_EXPORTED_BASE(MutatorHostClient) { | 71 public NON_EXPORTED_BASE(MutatorHostClient) { |
71 public: | 72 public: |
72 struct CC_EXPORT InitParams { | 73 struct CC_EXPORT InitParams { |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 EventListenerClass event_class) const { | 285 EventListenerClass event_class) const { |
285 return event_listener_properties_[static_cast<size_t>(event_class)]; | 286 return event_listener_properties_[static_cast<size_t>(event_class)]; |
286 } | 287 } |
287 | 288 |
288 void SetViewportSize(const gfx::Size& device_viewport_size); | 289 void SetViewportSize(const gfx::Size& device_viewport_size); |
289 gfx::Size device_viewport_size() const { return device_viewport_size_; } | 290 gfx::Size device_viewport_size() const { return device_viewport_size_; } |
290 | 291 |
291 void SetBrowserControlsHeight(float height, bool shrink); | 292 void SetBrowserControlsHeight(float height, bool shrink); |
292 void SetBrowserControlsShownRatio(float ratio); | 293 void SetBrowserControlsShownRatio(float ratio); |
293 void SetBottomControlsHeight(float height); | 294 void SetBottomControlsHeight(float height); |
| 295 void SetScrollBoundaryBehavior( |
| 296 const ScrollBoundaryBehavior& scroll_boundary_behavior); |
294 | 297 |
295 void SetPageScaleFactorAndLimits(float page_scale_factor, | 298 void SetPageScaleFactorAndLimits(float page_scale_factor, |
296 float min_page_scale_factor, | 299 float min_page_scale_factor, |
297 float max_page_scale_factor); | 300 float max_page_scale_factor); |
298 float page_scale_factor() const { return page_scale_factor_; } | 301 float page_scale_factor() const { return page_scale_factor_; } |
299 float min_page_scale_factor() const { return min_page_scale_factor_; } | 302 float min_page_scale_factor() const { return min_page_scale_factor_; } |
300 float max_page_scale_factor() const { return max_page_scale_factor_; } | 303 float max_page_scale_factor() const { return max_page_scale_factor_; } |
301 | 304 |
302 void set_background_color(SkColor color) { background_color_ = color; } | 305 void set_background_color(SkColor color) { background_color_ = color; } |
303 SkColor background_color() const { return background_color_; } | 306 SkColor background_color() const { return background_color_; } |
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
589 viz::SurfaceSequenceGenerator surface_sequence_generator_; | 592 viz::SurfaceSequenceGenerator surface_sequence_generator_; |
590 uint32_t num_consecutive_frames_without_slow_paths_ = 0; | 593 uint32_t num_consecutive_frames_without_slow_paths_ = 0; |
591 | 594 |
592 scoped_refptr<Layer> root_layer_; | 595 scoped_refptr<Layer> root_layer_; |
593 | 596 |
594 ViewportLayers viewport_layers_; | 597 ViewportLayers viewport_layers_; |
595 | 598 |
596 float top_controls_height_ = 0.f; | 599 float top_controls_height_ = 0.f; |
597 float top_controls_shown_ratio_ = 0.f; | 600 float top_controls_shown_ratio_ = 0.f; |
598 bool browser_controls_shrink_blink_size_ = false; | 601 bool browser_controls_shrink_blink_size_ = false; |
| 602 ScrollBoundaryBehavior scroll_boundary_behavior_; |
599 | 603 |
600 float bottom_controls_height_ = 0.f; | 604 float bottom_controls_height_ = 0.f; |
601 | 605 |
602 float device_scale_factor_ = 1.f; | 606 float device_scale_factor_ = 1.f; |
603 float painted_device_scale_factor_ = 1.f; | 607 float painted_device_scale_factor_ = 1.f; |
604 float page_scale_factor_ = 1.f; | 608 float page_scale_factor_ = 1.f; |
605 float min_page_scale_factor_ = 1.f; | 609 float min_page_scale_factor_ = 1.f; |
606 float max_page_scale_factor_ = 1.f; | 610 float max_page_scale_factor_ = 1.f; |
607 gfx::ColorSpace raster_color_space_; | 611 gfx::ColorSpace raster_color_space_; |
608 | 612 |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
656 | 660 |
657 std::vector<std::pair<PaintImage, base::Callback<void(bool)>>> | 661 std::vector<std::pair<PaintImage, base::Callback<void(bool)>>> |
658 queued_image_decodes_; | 662 queued_image_decodes_; |
659 | 663 |
660 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 664 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
661 }; | 665 }; |
662 | 666 |
663 } // namespace cc | 667 } // namespace cc |
664 | 668 |
665 #endif // CC_TREES_LAYER_TREE_HOST_H_ | 669 #endif // CC_TREES_LAYER_TREE_HOST_H_ |
OLD | NEW |