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

Unified Diff: ui/views/view.cc

Issue 108283008: Merge 241955 "Make extensions icons easier to target with gestures" (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1750/src/
Patch Set: Created 7 years 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 | « ui/views/view.h ('k') | ui/views/view_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/view.cc
===================================================================
--- ui/views/view.cc (revision 242152)
+++ ui/views/view.cc (working copy)
@@ -875,8 +875,8 @@
// |cur_view| is a suitable candidate for rect-based targeting.
// Check to see if it is the closest suitable candidate so far.
gfx::Point touch_center(rect.CenterPoint());
- int cur_dist = views::DistanceSquaredFromCenterLineToPoint(
- touch_center, cur_view_bounds);
+ int cur_dist = views::DistanceSquaredFromCenterToPoint(touch_center,
+ cur_view_bounds);
if (!rect_view || cur_dist < rect_view_distance) {
rect_view = cur_view;
rect_view_distance = cur_dist;
@@ -898,8 +898,8 @@
gfx::Rect local_bounds(GetLocalBounds());
if (views::PercentCoveredBy(local_bounds, rect) >= kRectTargetOverlap) {
gfx::Point touch_center(rect.CenterPoint());
- int cur_dist = views::DistanceSquaredFromCenterLineToPoint(touch_center,
- local_bounds);
+ int cur_dist = views::DistanceSquaredFromCenterToPoint(touch_center,
+ local_bounds);
if (!rect_view || cur_dist < rect_view_distance)
rect_view = this;
}
« no previous file with comments | « ui/views/view.h ('k') | ui/views/view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698