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

Unified Diff: cc/layers/painted_scrollbar_layer.cc

Issue 2384063007: Fix scrollbar overflow with ScaleToEnclosingRectSafe (Closed)
Patch Set: With comment Created 4 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
« no previous file with comments | « no previous file | ui/gfx/geometry/rect.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/painted_scrollbar_layer.cc
diff --git a/cc/layers/painted_scrollbar_layer.cc b/cc/layers/painted_scrollbar_layer.cc
index ec705b800ac418bc5044ece7310f51bfdddeaf68..6cfe92d925783772bdebdf21bc87808d9d7bfe28 100644
--- a/cc/layers/painted_scrollbar_layer.cc
+++ b/cc/layers/painted_scrollbar_layer.cc
@@ -133,7 +133,7 @@ gfx::Rect PaintedScrollbarLayer::ScrollbarLayerRectToContentRect(
const gfx::Rect& layer_rect) const {
// Don't intersect with the bounds as in LayerRectToContentRect() because
// layer_rect here might be in coordinates of the containing layer.
- gfx::Rect expanded_rect = gfx::ScaleToEnclosingRect(
+ gfx::Rect expanded_rect = gfx::ScaleToEnclosingRectSafe(
layer_rect, internal_contents_scale_, internal_contents_scale_);
// We should never return a rect bigger than the content bounds.
gfx::Size clamped_size = expanded_rect.size();
« no previous file with comments | « no previous file | ui/gfx/geometry/rect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698