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

Unified Diff: ui/views/controls/button/custom_button.h

Issue 2607923002: MacViews: Handle Space and Return keys correctly for Buttons. (Closed)
Patch Set: Address review. Created 3 years, 12 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/controls/button/custom_button.h
diff --git a/ui/views/controls/button/custom_button.h b/ui/views/controls/button/custom_button.h
index 03a8b161b898a7ec7d2e44beac06839861adeb6b..968810c4bdebe08f22140570c03d9e6d2c091f1e 100644
--- a/ui/views/controls/button/custom_button.h
+++ b/ui/views/controls/button/custom_button.h
@@ -29,6 +29,14 @@ class VIEWS_EXPORT CustomButton : public Button, public gfx::AnimationDelegate {
NOTIFY_ON_RELEASE,
};
+ // An enum describing the events on which a button should be clicked for a
+ // given key event.
+ enum ClickAction {
+ CLICK_ON_PRESS,
tapted 2017/01/05 00:34:41 I toyed with buttons a bit manually, and realised
karandeepb 2017/01/05 10:50:08 Done.
+ CLICK_ON_RELEASE,
+ CLICK_NONE,
+ };
+
// The menu button's class name.
static const char kViewClassName[];
« no previous file with comments | « no previous file | ui/views/controls/button/custom_button.cc » ('j') | ui/views/controls/button/custom_button_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698