summaryrefslogtreecommitdiffstats
path: root/libs/ui
diff options
context:
space:
mode:
authorKenny Root <kroot@google.com>2010-10-21 17:21:56 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-10-21 17:21:56 -0700
commita209aa866e5f1101064896c618e5d36cbce48470 (patch)
tree8fa5d7d4439a70c22fa5815b29f6cefdbfc0a893 /libs/ui
parent1e207d67fb21c1e33f70b471150c2629759873ba (diff)
parentbd3f24e7f1043fd04204b94f32136829d0c96514 (diff)
downloadframeworks_native-a209aa866e5f1101064896c618e5d36cbce48470.zip
frameworks_native-a209aa866e5f1101064896c618e5d36cbce48470.tar.gz
frameworks_native-a209aa866e5f1101064896c618e5d36cbce48470.tar.bz2
am d7cd560a: am 1d79a9d9: Use correct size of GAMEPAD_KEYCODES
Merge commit 'd7cd560af506f75d07034c136bea09b409b4d408' * commit 'd7cd560af506f75d07034c136bea09b409b4d408': Use correct size of GAMEPAD_KEYCODES
Diffstat (limited to 'libs/ui')
-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 97a7528..bc08e0a 100644
--- a/libs/ui/EventHub.cpp
+++ b/libs/ui/EventHub.cpp
@@ -839,7 +839,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;