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

Unified Diff: cc/layers/scrollbar_layer_impl_base.cc

Issue 2803853007: Ignore rounding error between clip_layer_length_ and scroll_layer_length_ (Closed)
Patch Set: change to epsilon Created 3 years, 8 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/scrollbar_layer_impl_base.cc
diff --git a/cc/layers/scrollbar_layer_impl_base.cc b/cc/layers/scrollbar_layer_impl_base.cc
index a4981e95b2d75cbe9bf891152c788b6ac1da2985..bbd46676f7d51f32b21ac34da0078dfd6d1cc5df 100644
--- a/cc/layers/scrollbar_layer_impl_base.cc
+++ b/cc/layers/scrollbar_layer_impl_base.cc
@@ -66,7 +66,10 @@ bool ScrollbarLayerImplBase::CanScrollOrientation() const {
layer_tree_impl()->LayerByElementId(scroll_element_id_);
if (!scroll_layer)
return false;
+
return scroll_layer->user_scrollable(orientation()) &&
+ !MathUtil::IsFloatNearlyTheSame(clip_layer_length_,
enne (OOO) 2017/04/21 22:54:33 Can you leave a comment here about why you need th
+ scroll_layer_length_) &&
clip_layer_length_ < scroll_layer_length_;
}

Powered by Google App Engine
This is Rietveld 408576698