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

Unified Diff: cc/layers/layer_impl.cc

Issue 655783004: Hide scrollbars when their dimensions are not scrollable. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: cc/layers/layer_impl.cc
diff --git a/cc/layers/layer_impl.cc b/cc/layers/layer_impl.cc
index 98923df0a170abeabfd867b594d51ad5aa24296b..a3617722518b87a80ebeba4743cc2d61e4587c33 100644
--- a/cc/layers/layer_impl.cc
+++ b/cc/layers/layer_impl.cc
@@ -390,6 +390,11 @@ void LayerImpl::SetScrollClipLayer(int scroll_clip_layer_id) {
scroll_clip_layer_ = layer_tree_impl()->LayerById(scroll_clip_layer_id);
}
+bool LayerImpl::user_scrollable(ScrollbarOrientation orientation) const {
+ return (orientation == HORIZONTAL) ? user_scrollable_horizontal_
+ : user_scrollable_vertical_;
+}
+
void LayerImpl::ApplySentScrollDeltasFromAbortedCommit() {
// Pending tree never has sent scroll deltas
DCHECK(layer_tree_impl()->IsActiveTree());

Powered by Google App Engine
This is Rietveld 408576698