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

Unified Diff: ui/views/rect_based_targeting_utils.h

Issue 32463003: Modify hit test masks for tabs and tab close buttons (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: HitTestSource moved Created 7 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: ui/views/rect_based_targeting_utils.h
diff --git a/ui/views/rect_based_targeting_utils.h b/ui/views/rect_based_targeting_utils.h
index e3f9d115b4c70253cfaccac23a8aa030a4c79773..9f1a96ef1b8e9b8c936bd3bef1fba3fdc048699e 100644
--- a/ui/views/rect_based_targeting_utils.h
+++ b/ui/views/rect_based_targeting_utils.h
@@ -14,6 +14,16 @@ class Rect;
namespace views {
+// Specifies the source of the region used in a hit test.
+// HIT_TEST_SOURCE_MOUSE indicates the hit test is being performed with a
+// single point and HIT_TEST_SOURCE_TOUCH indicates the hit test is being
+// performed with a rect larger than a single point. This value can be used,
+// for example, to add extra padding or change the shape of the hit test mask.
+enum HitTestSource {
Ben Goodger (Google) 2013/11/04 20:14:04 just go ahead and inline this into View now, as yo
tdanderson 2013/11/04 20:36:07 Done.
+ HIT_TEST_SOURCE_MOUSE,
+ HIT_TEST_SOURCE_TOUCH
+};
+
// Returns true if |rect| is 1x1.
VIEWS_EXPORT bool UsePointBasedTargeting(const gfx::Rect& rect);

Powered by Google App Engine
This is Rietveld 408576698