Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(43)

Side by Side Diff: cc/trees/layer_tree_host_impl.h

Issue 641873003: Made top controls work with virtual viewport pinch-to-zoom. (Chromium) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added BoundsForScrolling Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 477 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 488
489 protected: 489 protected:
490 LayerTreeHostImpl( 490 LayerTreeHostImpl(
491 const LayerTreeSettings& settings, 491 const LayerTreeSettings& settings,
492 LayerTreeHostImplClient* client, 492 LayerTreeHostImplClient* client,
493 Proxy* proxy, 493 Proxy* proxy,
494 RenderingStatsInstrumentation* rendering_stats_instrumentation, 494 RenderingStatsInstrumentation* rendering_stats_instrumentation,
495 SharedBitmapManager* manager, 495 SharedBitmapManager* manager,
496 int id); 496 int id);
497 497
498 void UpdateInnerViewportContainerSize(); 498 void UpdateViewportContainerSizes();
499 499
500 // Virtual for testing. 500 // Virtual for testing.
501 virtual void AnimateLayers(base::TimeTicks monotonic_time); 501 virtual void AnimateLayers(base::TimeTicks monotonic_time);
502 502
503 // Virtual for testing. 503 // Virtual for testing.
504 virtual base::TimeDelta LowFrequencyAnimationInterval() const; 504 virtual base::TimeDelta LowFrequencyAnimationInterval() const;
505 505
506 const AnimationRegistrar::AnimationControllerMap& 506 const AnimationRegistrar::AnimationControllerMap&
507 active_animation_controllers() const { 507 active_animation_controllers() const {
508 return animation_registrar_->active_animation_controllers(); 508 return animation_registrar_->active_animation_controllers();
(...skipping 18 matching lines...) Expand all
527 // Scroll by preferring to move the outer viewport first, only moving the 527 // Scroll by preferring to move the outer viewport first, only moving the
528 // inner if the outer is at its scroll extents. 528 // inner if the outer is at its scroll extents.
529 void ScrollViewportBy(gfx::Vector2dF scroll_delta); 529 void ScrollViewportBy(gfx::Vector2dF scroll_delta);
530 // Scroll by preferring to move the inner viewport first, only moving the 530 // Scroll by preferring to move the inner viewport first, only moving the
531 // outer if the inner is at its scroll extents. 531 // outer if the inner is at its scroll extents.
532 void ScrollViewportInnerFirst(gfx::Vector2dF scroll_delta); 532 void ScrollViewportInnerFirst(gfx::Vector2dF scroll_delta);
533 void AnimatePageScale(base::TimeTicks monotonic_time); 533 void AnimatePageScale(base::TimeTicks monotonic_time);
534 void AnimateScrollbars(base::TimeTicks monotonic_time); 534 void AnimateScrollbars(base::TimeTicks monotonic_time);
535 void AnimateTopControls(base::TimeTicks monotonic_time); 535 void AnimateTopControls(base::TimeTicks monotonic_time);
536 536
537 bool ShouldTopControlsConsumeScroll(const gfx::Vector2dF& scroll_delta) const;
538
537 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta( 539 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta(
538 LayerImpl* layer_impl, 540 LayerImpl* layer_impl,
539 float scale_from_viewport_to_screen_space, 541 float scale_from_viewport_to_screen_space,
540 const gfx::PointF& viewport_point, 542 const gfx::PointF& viewport_point,
541 const gfx::Vector2dF& viewport_delta); 543 const gfx::Vector2dF& viewport_delta);
542 544
543 void TrackDamageForAllSurfaces( 545 void TrackDamageForAllSurfaces(
544 LayerImpl* root_draw_layer, 546 LayerImpl* root_draw_layer,
545 const LayerImplList& render_surface_layer_list); 547 const LayerImplList& render_surface_layer_list);
546 548
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
709 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_; 711 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_;
710 712
711 bool requires_high_res_to_draw_; 713 bool requires_high_res_to_draw_;
712 714
713 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); 715 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl);
714 }; 716 };
715 717
716 } // namespace cc 718 } // namespace cc
717 719
718 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ 720 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698