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

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

Issue 2106753004: Introduce bottom controls to CC and let it respond to scrolling (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: findbug Created 4 years, 4 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
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/layer_tree_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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_IMPL_H_ 5 #ifndef CC_TREES_LAYER_TREE_IMPL_H_
6 #define CC_TREES_LAYER_TREE_IMPL_H_ 6 #define CC_TREES_LAYER_TREE_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 bool top_controls_shrink_blink_size() const { 408 bool top_controls_shrink_blink_size() const {
409 return top_controls_shrink_blink_size_; 409 return top_controls_shrink_blink_size_;
410 } 410 }
411 bool SetCurrentTopControlsShownRatio(float ratio); 411 bool SetCurrentTopControlsShownRatio(float ratio);
412 float CurrentTopControlsShownRatio() const { 412 float CurrentTopControlsShownRatio() const {
413 return top_controls_shown_ratio_->Current(IsActiveTree()); 413 return top_controls_shown_ratio_->Current(IsActiveTree());
414 } 414 }
415 void set_top_controls_height(float top_controls_height); 415 void set_top_controls_height(float top_controls_height);
416 float top_controls_height() const { return top_controls_height_; } 416 float top_controls_height() const { return top_controls_height_; }
417 void PushTopControlsFromMainThread(float top_controls_shown_ratio); 417 void PushTopControlsFromMainThread(float top_controls_shown_ratio);
418 void set_bottom_controls_height(float bottom_controls_height);
419 float bottom_controls_height() const { return bottom_controls_height_; }
418 420
419 void SetPendingPageScaleAnimation( 421 void SetPendingPageScaleAnimation(
420 std::unique_ptr<PendingPageScaleAnimation> pending_animation); 422 std::unique_ptr<PendingPageScaleAnimation> pending_animation);
421 std::unique_ptr<PendingPageScaleAnimation> TakePendingPageScaleAnimation(); 423 std::unique_ptr<PendingPageScaleAnimation> TakePendingPageScaleAnimation();
422 424
423 void DidUpdateScrollOffset(int layer_id, int transform_id); 425 void DidUpdateScrollOffset(int layer_id, int transform_id);
424 void DidUpdateScrollState(int layer_id); 426 void DidUpdateScrollState(int layer_id);
425 427
426 void ScrollAnimationAbort(bool needs_completion); 428 void ScrollAnimationAbort(bool needs_completion);
427 429
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
538 UIResourceRequestQueue ui_resource_request_queue_; 540 UIResourceRequestQueue ui_resource_request_queue_;
539 541
540 bool have_scroll_event_handlers_; 542 bool have_scroll_event_handlers_;
541 EventListenerProperties event_listener_properties_[static_cast<size_t>( 543 EventListenerProperties event_listener_properties_[static_cast<size_t>(
542 EventListenerClass::kNumClasses)]; 544 EventListenerClass::kNumClasses)];
543 545
544 // Whether or not Blink's viewport size was shrunk by the height of the top 546 // Whether or not Blink's viewport size was shrunk by the height of the top
545 // controls at the time of the last layout. 547 // controls at the time of the last layout.
546 bool top_controls_shrink_blink_size_; 548 bool top_controls_shrink_blink_size_;
547 float top_controls_height_; 549 float top_controls_height_;
550 float bottom_controls_height_;
548 551
549 // The amount that the top controls are shown from 0 (hidden) to 1 (fully 552 // The amount that the top controls are shown from 0 (hidden) to 1 (fully
550 // shown). 553 // shown).
551 scoped_refptr<SyncedTopControls> top_controls_shown_ratio_; 554 scoped_refptr<SyncedTopControls> top_controls_shown_ratio_;
552 555
553 std::unique_ptr<PendingPageScaleAnimation> pending_page_scale_animation_; 556 std::unique_ptr<PendingPageScaleAnimation> pending_page_scale_animation_;
554 557
555 private: 558 private:
556 DISALLOW_COPY_AND_ASSIGN(LayerTreeImpl); 559 DISALLOW_COPY_AND_ASSIGN(LayerTreeImpl);
557 }; 560 };
558 561
559 } // namespace cc 562 } // namespace cc
560 563
561 #endif // CC_TREES_LAYER_TREE_IMPL_H_ 564 #endif // CC_TREES_LAYER_TREE_IMPL_H_
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/layer_tree_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698