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 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
463 void ReleaseTreeResources(); | 463 void ReleaseTreeResources(); |
464 void EnforceZeroBudget(bool zero_budget); | 464 void EnforceZeroBudget(bool zero_budget); |
465 | 465 |
466 void AnimatePageScale(base::TimeTicks monotonic_time); | 466 void AnimatePageScale(base::TimeTicks monotonic_time); |
467 void AnimateScrollbars(base::TimeTicks monotonic_time); | 467 void AnimateScrollbars(base::TimeTicks monotonic_time); |
468 void AnimateTopControls(base::TimeTicks monotonic_time); | 468 void AnimateTopControls(base::TimeTicks monotonic_time); |
469 | 469 |
470 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta( | 470 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta( |
471 LayerImpl* layer_impl, | 471 LayerImpl* layer_impl, |
472 float scale_from_viewport_to_screen_space, | 472 float scale_from_viewport_to_screen_space, |
473 gfx::PointF viewport_point, | 473 const gfx::PointF& viewport_point, |
474 gfx::Vector2dF viewport_delta); | 474 gfx::Vector2dF viewport_delta); |
475 | 475 |
476 void UpdateMaxScrollOffset(); | 476 void UpdateMaxScrollOffset(); |
477 void TrackDamageForAllSurfaces( | 477 void TrackDamageForAllSurfaces( |
478 LayerImpl* root_draw_layer, | 478 LayerImpl* root_draw_layer, |
479 const LayerImplList& render_surface_layer_list); | 479 const LayerImplList& render_surface_layer_list); |
480 | 480 |
481 void UpdateTileManagerMemoryPolicy(const ManagedMemoryPolicy& policy); | 481 void UpdateTileManagerMemoryPolicy(const ManagedMemoryPolicy& policy); |
482 | 482 |
483 // Returns false if the frame should not be displayed. This function should | 483 // Returns false if the frame should not be displayed. This function should |
484 // only be called from PrepareToDraw, as DidDrawAllLayers must be called | 484 // only be called from PrepareToDraw, as DidDrawAllLayers must be called |
485 // if this helper function is called. | 485 // if this helper function is called. |
486 bool CalculateRenderPasses(FrameData* frame); | 486 bool CalculateRenderPasses(FrameData* frame); |
487 | 487 |
488 void SendReleaseResourcesRecursive(LayerImpl* current); | 488 void SendReleaseResourcesRecursive(LayerImpl* current); |
489 bool EnsureRenderSurfaceLayerList(); | 489 bool EnsureRenderSurfaceLayerList(); |
490 void ClearCurrentlyScrollingLayer(); | 490 void ClearCurrentlyScrollingLayer(); |
491 | 491 |
492 bool HandleMouseOverScrollbar(LayerImpl* layer_impl, | 492 bool HandleMouseOverScrollbar(LayerImpl* layer_impl, |
493 gfx::PointF device_viewport_point); | 493 const gfx::PointF& device_viewport_point); |
494 | 494 |
495 void AnimateScrollbarsRecursive(LayerImpl* layer, | 495 void AnimateScrollbarsRecursive(LayerImpl* layer, |
496 base::TimeTicks time); | 496 base::TimeTicks time); |
497 | 497 |
498 void UpdateCurrentFrameTime(base::TimeTicks* ticks, base::Time* now) const; | 498 void UpdateCurrentFrameTime(base::TimeTicks* ticks, base::Time* now) const; |
499 | 499 |
500 LayerImpl* FindScrollLayerForDeviceViewportPoint( | 500 LayerImpl* FindScrollLayerForDeviceViewportPoint( |
501 gfx::PointF device_viewport_point, | 501 const gfx::PointF& device_viewport_point, |
502 InputHandler::ScrollInputType type, | 502 InputHandler::ScrollInputType type, |
503 LayerImpl* layer_hit_by_point, | 503 LayerImpl* layer_hit_by_point, |
504 bool* scroll_on_main_thread) const; | 504 bool* scroll_on_main_thread) const; |
505 float DeviceSpaceDistanceToLayer(gfx::PointF device_viewport_point, | 505 float DeviceSpaceDistanceToLayer(const gfx::PointF& device_viewport_point, |
506 LayerImpl* layer_impl); | 506 LayerImpl* layer_impl); |
507 void StartScrollbarAnimationRecursive(LayerImpl* layer, base::TimeTicks time); | 507 void StartScrollbarAnimationRecursive(LayerImpl* layer, base::TimeTicks time); |
508 void SetManagedMemoryPolicy(const ManagedMemoryPolicy& policy, | 508 void SetManagedMemoryPolicy(const ManagedMemoryPolicy& policy, |
509 bool zero_budget); | 509 bool zero_budget); |
510 void EnforceManagedMemoryPolicy(const ManagedMemoryPolicy& policy); | 510 void EnforceManagedMemoryPolicy(const ManagedMemoryPolicy& policy); |
511 | 511 |
512 void DidInitializeVisibleTile(); | 512 void DidInitializeVisibleTile(); |
513 | 513 |
514 void MarkUIResourceNotEvicted(UIResourceId uid); | 514 void MarkUIResourceNotEvicted(UIResourceId uid); |
515 | 515 |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
651 int id_; | 651 int id_; |
652 | 652 |
653 std::set<SwapPromiseMonitor*> swap_promise_monitor_; | 653 std::set<SwapPromiseMonitor*> swap_promise_monitor_; |
654 | 654 |
655 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 655 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
656 }; | 656 }; |
657 | 657 |
658 } // namespace cc | 658 } // namespace cc |
659 | 659 |
660 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 660 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
OLD | NEW |