What is the corresponding keyboard keys to Google Glass touchpad actions?
android, bluetooth, google-glass, hid
Solution
The `KeyEvent`'s action you can intercept is `ACTION_DOWN`.
The key codes are:
- `KEYCODE_DPAD_CENTER` (tap)
- `KEYCODE_TAB` (horizontal swipes; `isShiftPressed()` returns `true` for backward [left] swipes and `false` for forward [right] swipes)
- `KEYCODE_CAMERA` (camera button)
- `KEYCODE_BACK` (swipe down, acts like back button)
There is no key code equivalent for a swipe up.
Problem
I used Settings.apk and Launcher2.apk to access to Android setting and paired Glass with my Bluetooth keyboard device. Now I can use arrow keys, escape and return to control my glass. If I only use left and right arrows I can not select to some items in Glass but I can select every thing by swipe forward and back on touchpad. Is there a keycode that can be directly mapped to touchpad action? Or does it needs special HID consumer report?