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

Unified Diff: cc/trees/layer_tree_impl.cc

Issue 2884423003: Use scroll-boundary-behavior to control overscroll-refresh/glow on android. (Closed)
Patch Set: Rebase Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/trees/layer_tree_impl.h ('k') | content/browser/android/overscroll_controller_android.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_impl.cc
diff --git a/cc/trees/layer_tree_impl.cc b/cc/trees/layer_tree_impl.cc
index d0d582ec14b051308657eefb4542e353c6477602..70d89a01900f1569aa6d09cbf321df89f3b0e9ed 100644
--- a/cc/trees/layer_tree_impl.cc
+++ b/cc/trees/layer_tree_impl.cc
@@ -425,6 +425,8 @@ void LayerTreeImpl::PushPropertiesTo(LayerTreeImpl* target_tree) {
target_tree->set_bottom_controls_height(bottom_controls_height_);
target_tree->PushBrowserControls(nullptr);
+ target_tree->set_scroll_boundary_behavior(scroll_boundary_behavior_);
+
// The page scale factor update can affect scrolling which requires that
// these ids are set, so this must be before PushPageScaleFactorAndLimits.
target_tree->SetViewportLayersFromIds(viewport_layer_ids_);
@@ -818,6 +820,11 @@ void LayerTreeImpl::set_bottom_controls_height(float bottom_controls_height) {
host_impl_->UpdateViewportContainerSizes();
}
+void LayerTreeImpl::set_scroll_boundary_behavior(
+ const ScrollBoundaryBehavior& behavior) {
+ scroll_boundary_behavior_ = behavior;
+}
+
bool LayerTreeImpl::ClampBrowserControlsShownRatio() {
float ratio = top_controls_shown_ratio_->Current(true);
ratio = std::max(ratio, 0.f);
« no previous file with comments | « cc/trees/layer_tree_impl.h ('k') | content/browser/android/overscroll_controller_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698