diff options
author | Jeff Brown <jeffbrown@google.com> | 2011-01-15 18:14:15 -0800 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2011-01-17 13:51:00 -0800 |
commit | cb1404e45639d20439d7700b06d57ca1a1aad1fa (patch) | |
tree | 1d9bb7c58ea0a9ae36c242602fca59d343e8a0cd /native/include | |
parent | e0dfee2b7075c1eac0db08d79d47381693d2f125 (diff) | |
download | frameworks_base-cb1404e45639d20439d7700b06d57ca1a1aad1fa.zip frameworks_base-cb1404e45639d20439d7700b06d57ca1a1aad1fa.tar.gz frameworks_base-cb1404e45639d20439d7700b06d57ca1a1aad1fa.tar.bz2 |
Add joystick support to framework.
Change-Id: I95374436708752e1a9cff3f85c5b9bc3e0987961
Diffstat (limited to 'native/include')
-rw-r--r-- | native/include/android/input.h | 3 | ||||
-rw-r--r-- | native/include/android/keycodes.h | 16 |
2 files changed, 19 insertions, 0 deletions
diff --git a/native/include/android/input.h b/native/include/android/input.h index e196686..bad363d 100644 --- a/native/include/android/input.h +++ b/native/include/android/input.h @@ -333,6 +333,7 @@ enum { AINPUT_SOURCE_CLASS_POINTER = 0x00000002, AINPUT_SOURCE_CLASS_NAVIGATION = 0x00000004, AINPUT_SOURCE_CLASS_POSITION = 0x00000008, + AINPUT_SOURCE_CLASS_JOYSTICK = 0x00000010, }; enum { @@ -340,10 +341,12 @@ enum { AINPUT_SOURCE_KEYBOARD = 0x00000100 | AINPUT_SOURCE_CLASS_BUTTON, AINPUT_SOURCE_DPAD = 0x00000200 | AINPUT_SOURCE_CLASS_BUTTON, + AINPUT_SOURCE_GAMEPAD = 0x00000400 | AINPUT_SOURCE_CLASS_BUTTON, AINPUT_SOURCE_TOUCHSCREEN = 0x00001000 | AINPUT_SOURCE_CLASS_POINTER, AINPUT_SOURCE_MOUSE = 0x00002000 | AINPUT_SOURCE_CLASS_POINTER, AINPUT_SOURCE_TRACKBALL = 0x00010000 | AINPUT_SOURCE_CLASS_NAVIGATION, AINPUT_SOURCE_TOUCHPAD = 0x00100000 | AINPUT_SOURCE_CLASS_POSITION, + AINPUT_SOURCE_JOYSTICK = 0x01000000 | AINPUT_SOURCE_CLASS_JOYSTICK, AINPUT_SOURCE_ANY = 0xffffff00, }; diff --git a/native/include/android/keycodes.h b/native/include/android/keycodes.h index b026a0c..c4a7eff 100644 --- a/native/include/android/keycodes.h +++ b/native/include/android/keycodes.h @@ -231,6 +231,22 @@ enum { AKEYCODE_PROG_YELLOW = 185, AKEYCODE_PROG_BLUE = 186, AKEYCODE_APP_SWITCH = 187, + AKEYCODE_BUTTON_1 = 188, + AKEYCODE_BUTTON_2 = 189, + AKEYCODE_BUTTON_3 = 190, + AKEYCODE_BUTTON_4 = 191, + AKEYCODE_BUTTON_5 = 192, + AKEYCODE_BUTTON_6 = 193, + AKEYCODE_BUTTON_7 = 194, + AKEYCODE_BUTTON_8 = 195, + AKEYCODE_BUTTON_9 = 196, + AKEYCODE_BUTTON_10 = 197, + AKEYCODE_BUTTON_11 = 198, + AKEYCODE_BUTTON_12 = 199, + AKEYCODE_BUTTON_13 = 200, + AKEYCODE_BUTTON_14 = 201, + AKEYCODE_BUTTON_15 = 202, + AKEYCODE_BUTTON_16 = 203, // NOTE: If you add a new keycode here you must also add it to several other files. // Refer to frameworks/base/core/java/android/view/KeyEvent.java for the full list. |