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

Unified Diff: tools/viewer/sk_app/Window.h

Issue 1955293002: Add flexible keybinding/command system to sk_app (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Rebase Created 4 years, 7 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 | « tools/viewer/sk_app/CommandSet.cpp ('k') | tools/viewer/sk_app/win/Window_win.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/viewer/sk_app/Window.h
diff --git a/tools/viewer/sk_app/Window.h b/tools/viewer/sk_app/Window.h
index 56444a67b76639577e9b0e24a7b506c6bce1a54a..5a7c9b836095240189de16c618e6f2670fa04c9c 100644
--- a/tools/viewer/sk_app/Window.h
+++ b/tools/viewer/sk_app/Window.h
@@ -41,45 +41,45 @@ public:
void detach();
// input handling
- enum Key {
- kNONE_Key, //corresponds to android's UNKNOWN
-
- kLeftSoftKey_Key,
- kRightSoftKey_Key,
-
- kHome_Key, //!< the home key - added to match android
- kBack_Key, //!< (CLR)
- kSend_Key, //!< the green (talk) key
- kEnd_Key, //!< the red key
-
- k0_Key,
- k1_Key,
- k2_Key,
- k3_Key,
- k4_Key,
- k5_Key,
- k6_Key,
- k7_Key,
- k8_Key,
- k9_Key,
- kStar_Key, //!< the * key
- kHash_Key, //!< the # key
-
- kUp_Key,
- kDown_Key,
- kLeft_Key,
- kRight_Key,
-
- kOK_Key, //!< the center key
-
- kVolUp_Key, //!< volume up - match android
- kVolDown_Key, //!< volume down - same
- kPower_Key, //!< power button - same
- kCamera_Key, //!< camera - same
-
- kLast_Key = kCamera_Key
+ enum class Key {
+ kNONE, //corresponds to android's UNKNOWN
+
+ kLeftSoftKey,
+ kRightSoftKey,
+
+ kHome, //!< the home key - added to match android
+ kBack, //!< (CLR)
+ kSend, //!< the green (talk) key
+ kEnd, //!< the red key
+
+ k0,
+ k1,
+ k2,
+ k3,
+ k4,
+ k5,
+ k6,
+ k7,
+ k8,
+ k9,
+ kStar, //!< the * key
+ kHash, //!< the # key
+
+ kUp,
+ kDown,
+ kLeft,
+ kRight,
+
+ kOK, //!< the center key
+
+ kVolUp, //!< volume up - match android
+ kVolDown, //!< volume down - same
+ kPower, //!< power button - same
+ kCamera, //!< camera - same
+
+ kLast = kCamera
};
- static const int kKeyCount = kLast_Key + 1;
+ static const int kKeyCount = static_cast<int>(Key::kLast) + 1;
enum ModifierKeys {
kShift_ModifierKey = 1 << 0,
« no previous file with comments | « tools/viewer/sk_app/CommandSet.cpp ('k') | tools/viewer/sk_app/win/Window_win.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698