summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorKenny Root <kroot@google.com>2010-10-21 16:22:58 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-10-21 16:22:58 -0700
commitd7cd560af506f75d07034c136bea09b409b4d408 (patch)
tree61396a3535fda841a646106c67410fe798ba7dea /libs
parent044fcd64fe999dca0f986dfce9cb3b5b1da77f44 (diff)
parent1d79a9d9f85f932a1fd6dcddba335450b65ba4e6 (diff)
downloadframeworks_base-d7cd560af506f75d07034c136bea09b409b4d408.zip
frameworks_base-d7cd560af506f75d07034c136bea09b409b4d408.tar.gz
frameworks_base-d7cd560af506f75d07034c136bea09b409b4d408.tar.bz2
am 1d79a9d9: Use correct size of GAMEPAD_KEYCODES
Merge commit '1d79a9d9f85f932a1fd6dcddba335450b65ba4e6' into gingerbread-plus-aosp * commit '1d79a9d9f85f932a1fd6dcddba335450b65ba4e6': Use correct size of GAMEPAD_KEYCODES
Diffstat (limited to 'libs')
-rw-r--r--libs/ui/EventHub.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/ui/EventHub.cpp b/libs/ui/EventHub.cpp
index 944731d..5c618fb 100644
--- a/libs/ui/EventHub.cpp
+++ b/libs/ui/EventHub.cpp
@@ -818,7 +818,7 @@ int EventHub::openDevice(const char *deviceName) {
}
// See if this device has a gamepad.
- for (size_t i = 0; i < sizeof(GAMEPAD_KEYCODES); i++) {
+ for (size_t i = 0; i < sizeof(GAMEPAD_KEYCODES)/sizeof(GAMEPAD_KEYCODES[0]); i++) {
if (hasKeycodeLocked(device, GAMEPAD_KEYCODES[i])) {
device->classes |= INPUT_DEVICE_CLASS_GAMEPAD;
break;