Files | |
file | input.h |
file | keycodes.h |
Macros | |
#define | AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT 8 |
Typedefs | |
typedef struct AInputEvent | AInputEvent |
typedef struct AInputQueue | AInputQueue |
Functions | |
int32_t | AInputEvent_getType (const AInputEvent *event) |
int32_t | AInputEvent_getDeviceId (const AInputEvent *event) |
int32_t | AInputEvent_getSource (const AInputEvent *event) |
int32_t | AKeyEvent_getAction (const AInputEvent *key_event) |
int32_t | AKeyEvent_getFlags (const AInputEvent *key_event) |
int32_t | AKeyEvent_getKeyCode (const AInputEvent *key_event) |
int32_t | AKeyEvent_getScanCode (const AInputEvent *key_event) |
int32_t | AKeyEvent_getMetaState (const AInputEvent *key_event) |
int32_t | AKeyEvent_getRepeatCount (const AInputEvent *key_event) |
int64_t | AKeyEvent_getDownTime (const AInputEvent *key_event) |
int64_t | AKeyEvent_getEventTime (const AInputEvent *key_event) |
int32_t | AMotionEvent_getAction (const AInputEvent *motion_event) |
int32_t | AMotionEvent_getFlags (const AInputEvent *motion_event) |
int32_t | AMotionEvent_getMetaState (const AInputEvent *motion_event) |
int32_t | AMotionEvent_getButtonState (const AInputEvent *motion_event) |
int32_t | AMotionEvent_getEdgeFlags (const AInputEvent *motion_event) |
int64_t | AMotionEvent_getDownTime (const AInputEvent *motion_event) |
int64_t | AMotionEvent_getEventTime (const AInputEvent *motion_event) |
float | AMotionEvent_getXOffset (const AInputEvent *motion_event) |
float | AMotionEvent_getYOffset (const AInputEvent *motion_event) |
float | AMotionEvent_getXPrecision (const AInputEvent *motion_event) |
float | AMotionEvent_getYPrecision (const AInputEvent *motion_event) |
size_t | AMotionEvent_getPointerCount (const AInputEvent *motion_event) |
int32_t | AMotionEvent_getPointerId (const AInputEvent *motion_event, size_t pointer_index) |
int32_t | AMotionEvent_getToolType (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getRawX (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getRawY (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getX (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getY (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getPressure (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getSize (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getTouchMajor (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getTouchMinor (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getToolMajor (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getToolMinor (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getOrientation (const AInputEvent *motion_event, size_t pointer_index) |
float | AMotionEvent_getAxisValue (const AInputEvent *motion_event, int32_t axis, size_t pointer_index) |
size_t | AMotionEvent_getHistorySize (const AInputEvent *motion_event) |
int64_t | AMotionEvent_getHistoricalEventTime (const AInputEvent *motion_event, size_t history_index) |
float | AMotionEvent_getHistoricalRawX (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalRawY (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalX (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalY (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalPressure (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalSize (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalTouchMajor (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalTouchMinor (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalToolMajor (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalToolMinor (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalOrientation (const AInputEvent *motion_event, size_t pointer_index, size_t history_index) |
float | AMotionEvent_getHistoricalAxisValue (const AInputEvent *motion_event, int32_t axis, size_t pointer_index, size_t history_index) |
void | AInputQueue_attachLooper (AInputQueue *queue, ALooper *looper, int ident, ALooper_callbackFunc callback, void *data) |
void | AInputQueue_detachLooper (AInputQueue *queue) |
int32_t | AInputQueue_hasEvents (AInputQueue *queue) |
int32_t | AInputQueue_getEvent (AInputQueue *queue, AInputEvent **outEvent) |
int32_t | AInputQueue_preDispatchEvent (AInputQueue *queue, AInputEvent *event) |
void | AInputQueue_finishEvent (AInputQueue *queue, AInputEvent *event, int handled) |
#define AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT 8 |
Bit shift for the action bits holding the pointer index as defined by AMOTION_EVENT_ACTION_POINTER_INDEX_MASK.
typedef struct AInputEvent AInputEvent |
Input events.
Input events are opaque structures. Use the provided accessors functions to read their properties.
typedef struct AInputQueue AInputQueue |
Input queue
An input queue is the facility through which you retrieve input events.
anonymous enum |
Motion event edge touch flags.
anonymous enum |
Constants that identify each individual axis of a motion event.
Enumerator | |
---|---|
AMOTION_EVENT_AXIS_X |
Axis constant: X axis of a motion event.
|
AMOTION_EVENT_AXIS_Y |
Axis constant: Y axis of a motion event.
|
AMOTION_EVENT_AXIS_PRESSURE |
Axis constant: Pressure axis of a motion event.
|
AMOTION_EVENT_AXIS_SIZE |
Axis constant: Size axis of a motion event.
|
AMOTION_EVENT_AXIS_TOUCH_MAJOR |
Axis constant: TouchMajor axis of a motion event.
|
AMOTION_EVENT_AXIS_TOUCH_MINOR |
Axis constant: TouchMinor axis of a motion event.
When the touch is circular, the major and minor axis lengths will be equal to one another. |
AMOTION_EVENT_AXIS_TOOL_MAJOR |
Axis constant: ToolMajor axis of a motion event.
When the touch is circular, the major and minor axis lengths will be equal to one another. The tool size may be larger than the touch size since the tool may not be fully in contact with the touch sensor. |
AMOTION_EVENT_AXIS_TOOL_MINOR |
Axis constant: ToolMinor axis of a motion event.
When the touch is circular, the major and minor axis lengths will be equal to one another. The tool size may be larger than the touch size since the tool may not be fully in contact with the touch sensor. |
AMOTION_EVENT_AXIS_ORIENTATION |
Axis constant: Orientation axis of a motion event.
|
AMOTION_EVENT_AXIS_VSCROLL |
Axis constant: Vertical Scroll axis of a motion event.
This axis should be used to scroll views vertically. |
AMOTION_EVENT_AXIS_HSCROLL |
Axis constant: Horizontal Scroll axis of a motion event.
This axis should be used to scroll views horizontally. |
AMOTION_EVENT_AXIS_Z |
Axis constant: Z axis of a motion event.
|
AMOTION_EVENT_AXIS_RX |
Axis constant: X Rotation axis of a motion event.
|
AMOTION_EVENT_AXIS_RY |
Axis constant: Y Rotation axis of a motion event.
|
AMOTION_EVENT_AXIS_RZ |
Axis constant: Z Rotation axis of a motion event.
|
AMOTION_EVENT_AXIS_HAT_X |
Axis constant: Hat X axis of a motion event.
|
AMOTION_EVENT_AXIS_HAT_Y |
Axis constant: Hat Y axis of a motion event.
|
AMOTION_EVENT_AXIS_LTRIGGER |
Axis constant: Left Trigger axis of a motion event.
|
AMOTION_EVENT_AXIS_RTRIGGER |
Axis constant: Right Trigger axis of a motion event.
|
AMOTION_EVENT_AXIS_THROTTLE |
Axis constant: Throttle axis of a motion event.
|
AMOTION_EVENT_AXIS_RUDDER |
Axis constant: Rudder axis of a motion event.
|
AMOTION_EVENT_AXIS_WHEEL |
Axis constant: Wheel axis of a motion event.
|
AMOTION_EVENT_AXIS_GAS |
Axis constant: Gas axis of a motion event.
|
AMOTION_EVENT_AXIS_BRAKE |
Axis constant: Brake axis of a motion event.
|
AMOTION_EVENT_AXIS_DISTANCE |
Axis constant: Distance axis of a motion event.
|
AMOTION_EVENT_AXIS_TILT |
Axis constant: Tilt axis of a motion event.
|
AMOTION_EVENT_AXIS_GENERIC_1 |
Axis constant: Generic 1 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_2 |
Axis constant: Generic 2 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_3 |
Axis constant: Generic 3 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_4 |
Axis constant: Generic 4 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_5 |
Axis constant: Generic 5 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_6 |
Axis constant: Generic 6 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_7 |
Axis constant: Generic 7 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_8 |
Axis constant: Generic 8 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_9 |
Axis constant: Generic 9 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_10 |
Axis constant: Generic 10 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_11 |
Axis constant: Generic 11 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_12 |
Axis constant: Generic 12 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_13 |
Axis constant: Generic 13 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_14 |
Axis constant: Generic 14 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_15 |
Axis constant: Generic 15 axis of a motion event. The interpretation of a generic axis is device-specific. |
AMOTION_EVENT_AXIS_GENERIC_16 |
Axis constant: Generic 16 axis of a motion event. The interpretation of a generic axis is device-specific. |
anonymous enum |
Constants that identify buttons that are associated with motion events. Refer to the documentation on the MotionEvent class for descriptions of each button.
Enumerator | |
---|---|
AMOTION_EVENT_BUTTON_PRIMARY |
primary |
AMOTION_EVENT_BUTTON_SECONDARY |
secondary |
AMOTION_EVENT_BUTTON_TERTIARY |
tertiary |
AMOTION_EVENT_BUTTON_BACK |
back |
AMOTION_EVENT_BUTTON_FORWARD |
forward |
anonymous enum |
Constants that identify tool types. Refer to the documentation on the MotionEvent class for descriptions of each tool type.
Enumerator | |
---|---|
AMOTION_EVENT_TOOL_TYPE_UNKNOWN |
unknown |
AMOTION_EVENT_TOOL_TYPE_FINGER |
finger |
AMOTION_EVENT_TOOL_TYPE_STYLUS |
stylus |
AMOTION_EVENT_TOOL_TYPE_MOUSE |
mouse |
AMOTION_EVENT_TOOL_TYPE_ERASER |
eraser |
anonymous enum |
Input source masks.
Refer to the documentation on android.view.InputDevice for more details about input sources and their correct interpretation.
anonymous enum |
Input sources.
anonymous enum |
anonymous enum |
Constants used to retrieve information about the range of motion for a particular coordinate of a motion event.
Refer to the documentation on android.view.InputDevice for more details about input sources and their correct interpretation.
anonymous enum |
Key codes.
Enumerator | |
---|---|
AKEYCODE_UNKNOWN |
Unknown key code. |
AKEYCODE_SOFT_LEFT |
Soft Left key. Usually situated below the display on phones and used as a multi-function feature key for selecting a software defined function shown on the bottom left of the display. |
AKEYCODE_SOFT_RIGHT |
Soft Right key. Usually situated below the display on phones and used as a multi-function feature key for selecting a software defined function shown on the bottom right of the display. |
AKEYCODE_HOME |
Home key. This key is handled by the framework and is never delivered to applications. |
AKEYCODE_BACK |
Back key. |
AKEYCODE_CALL |
Call key. |
AKEYCODE_ENDCALL |
End Call key. |
AKEYCODE_0 |
'0' key. |
AKEYCODE_1 |
'1' key. |
AKEYCODE_2 |
'2' key. |
AKEYCODE_3 |
'3' key. |
AKEYCODE_4 |
'4' key. |
AKEYCODE_5 |
'5' key. |
AKEYCODE_6 |
'6' key. |
AKEYCODE_7 |
'7' key. |
AKEYCODE_8 |
'8' key. |
AKEYCODE_9 |
'9' key. |
AKEYCODE_STAR |
'*' key. |
AKEYCODE_POUND |
'#' key. |
AKEYCODE_DPAD_UP |
Directional Pad Up key. May also be synthesized from trackball motions. |
AKEYCODE_DPAD_DOWN |
Directional Pad Down key. May also be synthesized from trackball motions. |
AKEYCODE_DPAD_LEFT |
Directional Pad Left key. May also be synthesized from trackball motions. |
AKEYCODE_DPAD_RIGHT |
Directional Pad Right key. May also be synthesized from trackball motions. |
AKEYCODE_DPAD_CENTER |
Directional Pad Center key. May also be synthesized from trackball motions. |
AKEYCODE_VOLUME_UP |
Volume Up key. Adjusts the speaker volume up. |
AKEYCODE_VOLUME_DOWN |
Volume Down key. Adjusts the speaker volume down. |
AKEYCODE_POWER |
Power key. |
AKEYCODE_CAMERA |
Camera key. Used to launch a camera application or take pictures. |
AKEYCODE_CLEAR |
Clear key. |
AKEYCODE_A |
'A' key. |
AKEYCODE_B |
'B' key. |
AKEYCODE_C |
'C' key. |
AKEYCODE_D |
'D' key. |
AKEYCODE_E |
'E' key. |
AKEYCODE_F |
'F' key. |
AKEYCODE_G |
'G' key. |
AKEYCODE_H |
'H' key. |
AKEYCODE_I |
'I' key. |
AKEYCODE_J |
'J' key. |
AKEYCODE_K |
'K' key. |
AKEYCODE_L |
'L' key. |
AKEYCODE_M |
'M' key. |
AKEYCODE_N |
'N' key. |
AKEYCODE_O |
'O' key. |
AKEYCODE_P |
'P' key. |
AKEYCODE_Q |
'Q' key. |
AKEYCODE_R |
'R' key. |
AKEYCODE_S |
'S' key. |
AKEYCODE_T |
'T' key. |
AKEYCODE_U |
'U' key. |
AKEYCODE_V |
'V' key. |
AKEYCODE_W |
'W' key. |
AKEYCODE_X |
'X' key. |
AKEYCODE_Y |
'Y' key. |
AKEYCODE_Z |
'Z' key. |
AKEYCODE_COMMA |
',' key. |
AKEYCODE_PERIOD |
'.' key. |
AKEYCODE_ALT_LEFT |
Left Alt modifier key. |
AKEYCODE_ALT_RIGHT |
Right Alt modifier key. |
AKEYCODE_SHIFT_LEFT |
Left Shift modifier key. |
AKEYCODE_SHIFT_RIGHT |
Right Shift modifier key. |
AKEYCODE_TAB |
Tab key. |
AKEYCODE_SPACE |
Space key. |
AKEYCODE_SYM |
Symbol modifier key. Used to enter alternate symbols. |
AKEYCODE_EXPLORER |
Explorer special function key. Used to launch a browser application. |
AKEYCODE_ENVELOPE |
Envelope special function key. Used to launch a mail application. |
AKEYCODE_ENTER |
Enter key. |
AKEYCODE_DEL |
Backspace key. Deletes characters before the insertion point, unlike AKEYCODE_FORWARD_DEL. |
AKEYCODE_GRAVE |
'`' (backtick) key. |
AKEYCODE_MINUS |
'-'. |
AKEYCODE_EQUALS |
'=' key. |
AKEYCODE_LEFT_BRACKET |
'[' key. |
AKEYCODE_RIGHT_BRACKET |
']' key. |
AKEYCODE_BACKSLASH |
'\' key. |
AKEYCODE_SEMICOLON |
';' key. |
AKEYCODE_APOSTROPHE |
''' (apostrophe) key. |
AKEYCODE_SLASH |
'/' key. |
AKEYCODE_AT |
'@' key. |
AKEYCODE_NUM |
Number modifier key. Used to enter numeric symbols. This key is not AKEYCODE_NUM_LOCK; it is more like AKEYCODE_ALT_LEFT. |
AKEYCODE_HEADSETHOOK |
Headset Hook key. Used to hang up calls and stop media. |
AKEYCODE_FOCUS |
Camera Focus key. Used to focus the camera. |
AKEYCODE_PLUS |
'+' key. |
AKEYCODE_MENU |
Menu key. |
AKEYCODE_NOTIFICATION |
Notification key. |
AKEYCODE_SEARCH |
Search key. |
AKEYCODE_MEDIA_PLAY_PAUSE |
Play/Pause media key. |
AKEYCODE_MEDIA_STOP |
Stop media key. |
AKEYCODE_MEDIA_NEXT |
Play Next media key. |
AKEYCODE_MEDIA_PREVIOUS |
Play Previous media key. |
AKEYCODE_MEDIA_REWIND |
Rewind media key. |
AKEYCODE_MEDIA_FAST_FORWARD |
Fast Forward media key. |
AKEYCODE_MUTE |
Mute key. Mutes the microphone, unlike AKEYCODE_VOLUME_MUTE. |
AKEYCODE_PAGE_UP |
Page Up key. |
AKEYCODE_PAGE_DOWN |
Page Down key. |
AKEYCODE_PICTSYMBOLS |
Picture Symbols modifier key. Used to switch symbol sets (Emoji, Kao-moji). |
AKEYCODE_SWITCH_CHARSET |
Switch Charset modifier key. Used to switch character sets (Kanji, Katakana). |
AKEYCODE_BUTTON_A |
A Button key. On a game controller, the A button should be either the button labeled A or the first button on the bottom row of controller buttons. |
AKEYCODE_BUTTON_B |
B Button key. On a game controller, the B button should be either the button labeled B or the second button on the bottom row of controller buttons. |
AKEYCODE_BUTTON_C |
C Button key. On a game controller, the C button should be either the button labeled C or the third button on the bottom row of controller buttons. |
AKEYCODE_BUTTON_X |
X Button key. On a game controller, the X button should be either the button labeled X or the first button on the upper row of controller buttons. |
AKEYCODE_BUTTON_Y |
Y Button key. On a game controller, the Y button should be either the button labeled Y or the second button on the upper row of controller buttons. |
AKEYCODE_BUTTON_Z |
Z Button key. On a game controller, the Z button should be either the button labeled Z or the third button on the upper row of controller buttons. |
AKEYCODE_BUTTON_L1 |
L1 Button key. On a game controller, the L1 button should be either the button labeled L1 (or L) or the top left trigger button. |
AKEYCODE_BUTTON_R1 |
R1 Button key. On a game controller, the R1 button should be either the button labeled R1 (or R) or the top right trigger button. |
AKEYCODE_BUTTON_L2 |
L2 Button key. On a game controller, the L2 button should be either the button labeled L2 or the bottom left trigger button. |
AKEYCODE_BUTTON_R2 |
R2 Button key. On a game controller, the R2 button should be either the button labeled R2 or the bottom right trigger button. |
AKEYCODE_BUTTON_THUMBL |
Left Thumb Button key. On a game controller, the left thumb button indicates that the left (or only) joystick is pressed. |
AKEYCODE_BUTTON_THUMBR |
Right Thumb Button key. On a game controller, the right thumb button indicates that the right joystick is pressed. |
AKEYCODE_BUTTON_START |
Start Button key. On a game controller, the button labeled Start. |
AKEYCODE_BUTTON_SELECT |
Select Button key. On a game controller, the button labeled Select. |
AKEYCODE_BUTTON_MODE |
Mode Button key. On a game controller, the button labeled Mode. |
AKEYCODE_ESCAPE |
Escape key. |
AKEYCODE_FORWARD_DEL |
Forward Delete key. Deletes characters ahead of the insertion point, unlike AKEYCODE_DEL. |
AKEYCODE_CTRL_LEFT |
Left Control modifier key. |
AKEYCODE_CTRL_RIGHT |
Right Control modifier key. |
AKEYCODE_CAPS_LOCK |
Caps Lock key. |
AKEYCODE_SCROLL_LOCK |
Scroll Lock key. |
AKEYCODE_META_LEFT |
Left Meta modifier key. |
AKEYCODE_META_RIGHT |
Right Meta modifier key. |
AKEYCODE_FUNCTION |
Function modifier key. |
AKEYCODE_SYSRQ |
System Request / Print Screen key. |
AKEYCODE_BREAK |
Break / Pause key. |
AKEYCODE_MOVE_HOME |
Home Movement key. Used for scrolling or moving the cursor around to the start of a line or to the top of a list. |
AKEYCODE_MOVE_END |
End Movement key. Used for scrolling or moving the cursor around to the end of a line or to the bottom of a list. |
AKEYCODE_INSERT |
Insert key. Toggles insert / overwrite edit mode. |
AKEYCODE_FORWARD |
Forward key. Navigates forward in the history stack. Complement of AKEYCODE_BACK. |
AKEYCODE_MEDIA_PLAY |
Play media key. |
AKEYCODE_MEDIA_PAUSE |
Pause media key. |
AKEYCODE_MEDIA_CLOSE |
Close media key. May be used to close a CD tray, for example. |
AKEYCODE_MEDIA_EJECT |
Eject media key. May be used to eject a CD tray, for example. |
AKEYCODE_MEDIA_RECORD |
Record media key. |
AKEYCODE_F1 |
F1 key. |
AKEYCODE_F2 |
F2 key. |
AKEYCODE_F3 |
F3 key. |
AKEYCODE_F4 |
F4 key. |
AKEYCODE_F5 |
F5 key. |
AKEYCODE_F6 |
F6 key. |
AKEYCODE_F7 |
F7 key. |
AKEYCODE_F8 |
F8 key. |
AKEYCODE_F9 |
F9 key. |
AKEYCODE_F10 |
F10 key. |
AKEYCODE_F11 |
F11 key. |
AKEYCODE_F12 |
F12 key. |
AKEYCODE_NUM_LOCK |
Num Lock key. This is the Num Lock key; it is different from AKEYCODE_NUM. This key alters the behavior of other keys on the numeric keypad. |
AKEYCODE_NUMPAD_0 |
Numeric keypad '0' key. |
AKEYCODE_NUMPAD_1 |
Numeric keypad '1' key. |
AKEYCODE_NUMPAD_2 |
Numeric keypad '2' key. |
AKEYCODE_NUMPAD_3 |
Numeric keypad '3' key. |
AKEYCODE_NUMPAD_4 |
Numeric keypad '4' key. |
AKEYCODE_NUMPAD_5 |
Numeric keypad '5' key. |
AKEYCODE_NUMPAD_6 |
Numeric keypad '6' key. |
AKEYCODE_NUMPAD_7 |
Numeric keypad '7' key. |
AKEYCODE_NUMPAD_8 |
Numeric keypad '8' key. |
AKEYCODE_NUMPAD_9 |
Numeric keypad '9' key. |
AKEYCODE_NUMPAD_DIVIDE |
Numeric keypad '/' key (for division). |
AKEYCODE_NUMPAD_MULTIPLY |
Numeric keypad '*' key (for multiplication). |
AKEYCODE_NUMPAD_SUBTRACT |
Numeric keypad '-' key (for subtraction). |
AKEYCODE_NUMPAD_ADD |
Numeric keypad '+' key (for addition). |
AKEYCODE_NUMPAD_DOT |
Numeric keypad '.' key (for decimals or digit grouping). |
AKEYCODE_NUMPAD_COMMA |
Numeric keypad ',' key (for decimals or digit grouping). |
AKEYCODE_NUMPAD_ENTER |
Numeric keypad Enter key. |
AKEYCODE_NUMPAD_EQUALS |
Numeric keypad '=' key. |
AKEYCODE_NUMPAD_LEFT_PAREN |
Numeric keypad '(' key. |
AKEYCODE_NUMPAD_RIGHT_PAREN |
Numeric keypad ')' key. |
AKEYCODE_VOLUME_MUTE |
Volume Mute key. Mutes the speaker, unlike AKEYCODE_MUTE. This key should normally be implemented as a toggle such that the first press mutes the speaker and the second press restores the original volume. |
AKEYCODE_INFO |
Info key. Common on TV remotes to show additional information related to what is currently being viewed. |
AKEYCODE_CHANNEL_UP |
Channel up key. On TV remotes, increments the television channel. |
AKEYCODE_CHANNEL_DOWN |
Channel down key. On TV remotes, decrements the television channel. |
AKEYCODE_ZOOM_IN |
Zoom in key. |
AKEYCODE_ZOOM_OUT |
Zoom out key. |
AKEYCODE_TV |
TV key. On TV remotes, switches to viewing live TV. |
AKEYCODE_WINDOW |
Window key. On TV remotes, toggles picture-in-picture mode or other windowing functions. |
AKEYCODE_GUIDE |
Guide key. On TV remotes, shows a programming guide. |
AKEYCODE_DVR |
DVR key. On some TV remotes, switches to a DVR mode for recorded shows. |
AKEYCODE_BOOKMARK |
Bookmark key. On some TV remotes, bookmarks content or web pages. |
AKEYCODE_CAPTIONS |
Toggle captions key. Switches the mode for closed-captioning text, for example during television shows. |
AKEYCODE_SETTINGS |
Settings key. Starts the system settings activity. |
AKEYCODE_TV_POWER |
TV power key. On TV remotes, toggles the power on a television screen. |
AKEYCODE_TV_INPUT |
TV input key. On TV remotes, switches the input on a television screen. |
AKEYCODE_STB_POWER |
Set-top-box power key. On TV remotes, toggles the power on an external Set-top-box. |
AKEYCODE_STB_INPUT |
Set-top-box input key. On TV remotes, switches the input mode on an external Set-top-box. |
AKEYCODE_AVR_POWER |
A/V Receiver power key. On TV remotes, toggles the power on an external A/V Receiver. |
AKEYCODE_AVR_INPUT |
A/V Receiver input key. On TV remotes, switches the input mode on an external A/V Receiver. |
AKEYCODE_PROG_RED |
Red "programmable" key. On TV remotes, acts as a contextual/programmable key. |
AKEYCODE_PROG_GREEN |
Green "programmable" key. On TV remotes, actsas a contextual/programmable key. |
AKEYCODE_PROG_YELLOW |
Yellow "programmable" key. On TV remotes, acts as a contextual/programmable key. |
AKEYCODE_PROG_BLUE |
Blue "programmable" key. On TV remotes, acts as a contextual/programmable key. |
AKEYCODE_APP_SWITCH |
App switch key. Should bring up the application switcher dialog. |
AKEYCODE_BUTTON_1 |
Generic Game Pad Button #1. |
AKEYCODE_BUTTON_2 |
Generic Game Pad Button #2. |
AKEYCODE_BUTTON_3 |
Generic Game Pad Button #3. |
AKEYCODE_BUTTON_4 |
Generic Game Pad Button #4. |
AKEYCODE_BUTTON_5 |
Generic Game Pad Button #5. |
AKEYCODE_BUTTON_6 |
Generic Game Pad Button #6. |
AKEYCODE_BUTTON_7 |
Generic Game Pad Button #7. |
AKEYCODE_BUTTON_8 |
Generic Game Pad Button #8. |
AKEYCODE_BUTTON_9 |
Generic Game Pad Button #9. |
AKEYCODE_BUTTON_10 |
Generic Game Pad Button #10. |
AKEYCODE_BUTTON_11 |
Generic Game Pad Button #11. |
AKEYCODE_BUTTON_12 |
Generic Game Pad Button #12. |
AKEYCODE_BUTTON_13 |
Generic Game Pad Button #13. |
AKEYCODE_BUTTON_14 |
Generic Game Pad Button #14. |
AKEYCODE_BUTTON_15 |
Generic Game Pad Button #15. |
AKEYCODE_BUTTON_16 |
Generic Game Pad Button #16. |
AKEYCODE_LANGUAGE_SWITCH |
Language Switch key. Toggles the current input language such as switching between English and Japanese on a QWERTY keyboard. On some devices, the same function may be performed by pressing Shift+Spacebar. |
AKEYCODE_MANNER_MODE |
Manner Mode key. Toggles silent or vibrate mode on and off to make the device behave more politely in certain settings such as on a crowded train. On some devices, the key may only operate when long-pressed. |
AKEYCODE_3D_MODE |
3D Mode key. Toggles the display between 2D and 3D mode. |
AKEYCODE_CONTACTS |
Contacts special function key. Used to launch an address book application. |
AKEYCODE_CALENDAR |
Calendar special function key. Used to launch a calendar application. |
AKEYCODE_MUSIC |
Music special function key. Used to launch a music player application. |
AKEYCODE_CALCULATOR |
Calculator special function key. Used to launch a calculator application. |
AKEYCODE_ZENKAKU_HANKAKU |
Japanese full-width / half-width key. |
AKEYCODE_EISU |
Japanese alphanumeric key. |
AKEYCODE_MUHENKAN |
Japanese non-conversion key. |
AKEYCODE_HENKAN |
Japanese conversion key. |
AKEYCODE_KATAKANA_HIRAGANA |
Japanese katakana / hiragana key. |
AKEYCODE_YEN |
Japanese Yen key. |
AKEYCODE_RO |
Japanese Ro key. |
AKEYCODE_KANA |
Japanese kana key. |
AKEYCODE_ASSIST |
Assist key. Launches the global assist activity. Not delivered to applications. |
AKEYCODE_BRIGHTNESS_DOWN |
Brightness Down key. Adjusts the screen brightness down. |
AKEYCODE_BRIGHTNESS_UP |
Brightness Up key. Adjusts the screen brightness up. |
AKEYCODE_MEDIA_AUDIO_TRACK |
Audio Track key. Switches the audio tracks. |
AKEYCODE_SLEEP |
Sleep key. Puts the device to sleep. Behaves somewhat like AKEYCODE_POWER but it has no effect if the device is already asleep. |
AKEYCODE_WAKEUP |
Wakeup key. Wakes up the device. Behaves somewhat like AKEYCODE_POWER but it has no effect if the device is already awake. |
AKEYCODE_PAIRING |
Pairing key. Initiates peripheral pairing mode. Useful for pairing remote control devices or game controllers, especially if no other input mode is available. |
AKEYCODE_MEDIA_TOP_MENU |
Media Top Menu key. Goes to the top of media menu. |
AKEYCODE_11 |
'11' key. |
AKEYCODE_12 |
'12' key. |
AKEYCODE_LAST_CHANNEL |
Last Channel key. Goes to the last viewed channel. |
AKEYCODE_TV_DATA_SERVICE |
TV data service key. Displays data services like weather, sports. |
AKEYCODE_VOICE_ASSIST |
Voice Assist key. Launches the global voice assist activity. Not delivered to applications. |
AKEYCODE_TV_RADIO_SERVICE |
Radio key. Toggles TV service / Radio service. |
AKEYCODE_TV_TELETEXT |
Teletext key. Displays Teletext service. |
AKEYCODE_TV_NUMBER_ENTRY |
Number entry key. Initiates to enter multi-digit channel nubmber when each digit key is assigned for selecting separate channel. Corresponds to Number Entry Mode (0x1D) of CEC User Control Code. |
AKEYCODE_TV_TERRESTRIAL_ANALOG |
Analog Terrestrial key. Switches to analog terrestrial broadcast service. |
AKEYCODE_TV_TERRESTRIAL_DIGITAL |
Digital Terrestrial key. Switches to digital terrestrial broadcast service. |
AKEYCODE_TV_SATELLITE |
Satellite key. Switches to digital satellite broadcast service. |
AKEYCODE_TV_SATELLITE_BS |
BS key. Switches to BS digital satellite broadcasting service available in Japan. |
AKEYCODE_TV_SATELLITE_CS |
CS key. Switches to CS digital satellite broadcasting service available in Japan. |
AKEYCODE_TV_SATELLITE_SERVICE |
BS/CS key. Toggles between BS and CS digital satellite services. |
AKEYCODE_TV_NETWORK |
Toggle Network key. Toggles selecting broacast services. |
AKEYCODE_TV_ANTENNA_CABLE |
Antenna/Cable key. Toggles broadcast input source between antenna and cable. |
AKEYCODE_TV_INPUT_HDMI_1 |
HDMI #1 key. Switches to HDMI input #1. |
AKEYCODE_TV_INPUT_HDMI_2 |
HDMI #2 key. Switches to HDMI input #2. |
AKEYCODE_TV_INPUT_HDMI_3 |
HDMI #3 key. Switches to HDMI input #3. |
AKEYCODE_TV_INPUT_HDMI_4 |
HDMI #4 key. Switches to HDMI input #4. |
AKEYCODE_TV_INPUT_COMPOSITE_1 |
Composite #1 key. Switches to composite video input #1. |
AKEYCODE_TV_INPUT_COMPOSITE_2 |
Composite #2 key. Switches to composite video input #2. |
AKEYCODE_TV_INPUT_COMPONENT_1 |
Component #1 key. Switches to component video input #1. |
AKEYCODE_TV_INPUT_COMPONENT_2 |
Component #2 key. Switches to component video input #2. |
AKEYCODE_TV_INPUT_VGA_1 |
VGA #1 key. Switches to VGA (analog RGB) input #1. |
AKEYCODE_TV_AUDIO_DESCRIPTION |
Audio description key. Toggles audio description off / on. |
AKEYCODE_TV_AUDIO_DESCRIPTION_MIX_UP |
Audio description mixing volume up key. Louden audio description volume as compared with normal audio volume. |
AKEYCODE_TV_AUDIO_DESCRIPTION_MIX_DOWN |
Audio description mixing volume down key. Lessen audio description volume as compared with normal audio volume. |
AKEYCODE_TV_ZOOM_MODE |
Zoom mode key. Changes Zoom mode (Normal, Full, Zoom, Wide-zoom, etc.) |
AKEYCODE_TV_CONTENTS_MENU |
Contents menu key. Goes to the title list. Corresponds to Contents Menu (0x0B) of CEC User Control Code |
AKEYCODE_TV_MEDIA_CONTEXT_MENU |
Media context menu key. Goes to the context menu of media contents. Corresponds to Media Context-sensitive Menu (0x11) of CEC User Control Code. |
AKEYCODE_TV_TIMER_PROGRAMMING |
Timer programming key. Goes to the timer recording menu. Corresponds to Timer Programming (0x54) of CEC User Control Code. |
AKEYCODE_HELP |
Help key. |
anonymous enum |
Key states (may be returned by queries about the current state of a particular key code, scan code or switch).
anonymous enum |
Meta key / modifer state.
anonymous enum |
anonymous enum |
Key event actions.
anonymous enum |
Key event flags.
anonymous enum |
Motion event actions
anonymous enum |
Motion event flags.
int32_t AInputEvent_getDeviceId | ( | const AInputEvent * | event | ) |
Get the id for the device that an input event came from.
Input events can be generated by multiple different input devices. Use the input device id to obtain information about the input device that was responsible for generating a particular event.
An input device id of 0 indicates that the event didn't come from a physical device; other numbers are arbitrary and you shouldn't depend on the values. Use the provided input device query API to obtain information about input devices.
int32_t AInputEvent_getSource | ( | const AInputEvent * | event | ) |
Get the input event source.
int32_t AInputEvent_getType | ( | const AInputEvent * | event | ) |
Input event accessors.
Note that most functions can only be used on input events that are of a given type. Calling these functions on input events of other types will yield undefined behavior.Get the input event type.
void AInputQueue_attachLooper | ( | AInputQueue * | queue, |
ALooper * | looper, | ||
int | ident, | ||
ALooper_callbackFunc | callback, | ||
void * | data | ||
) |
Add this input queue to a looper for processing. See ALooper_addFd() for information on the ident, callback, and data params.
void AInputQueue_detachLooper | ( | AInputQueue * | queue | ) |
Remove the input queue from the looper it is currently attached to.
void AInputQueue_finishEvent | ( | AInputQueue * | queue, |
AInputEvent * | event, | ||
int | handled | ||
) |
Report that dispatching has finished with the given event. This must be called after receiving an event with AInputQueue_get_event().
int32_t AInputQueue_getEvent | ( | AInputQueue * | queue, |
AInputEvent ** | outEvent | ||
) |
Returns the next available event from the queue. Returns a negative value if no events are available or an error has occurred.
int32_t AInputQueue_hasEvents | ( | AInputQueue * | queue | ) |
Returns true if there are one or more events available in the input queue. Returns 1 if the queue has events; 0 if it does not have events; and a negative value if there is an error.
int32_t AInputQueue_preDispatchEvent | ( | AInputQueue * | queue, |
AInputEvent * | event | ||
) |
Sends the key for standard pre-dispatching – that is, possibly deliver it to the current IME to be consumed before the app. Returns 0 if it was not pre-dispatched, meaning you can process it right now. If non-zero is returned, you must abandon the current event processing and allow the event to appear again in the event queue (if it does not get consumed during pre-dispatching).
int32_t AKeyEvent_getAction | ( | const AInputEvent * | key_event | ) |
Get the key event action.
int64_t AKeyEvent_getDownTime | ( | const AInputEvent * | key_event | ) |
Get the time of the most recent key down event, in the java.lang.System.nanoTime() time base. If this is a down event, this will be the same as eventTime. Note that when chording keys, this value is the down time of the most recently pressed key, which may not be the same physical key of this event.
int64_t AKeyEvent_getEventTime | ( | const AInputEvent * | key_event | ) |
Get the time this event occurred, in the java.lang.System.nanoTime() time base.
int32_t AKeyEvent_getFlags | ( | const AInputEvent * | key_event | ) |
Get the key event flags.
int32_t AKeyEvent_getKeyCode | ( | const AInputEvent * | key_event | ) |
Get the key code of the key event. This is the physical key that was pressed, not the Unicode character.
int32_t AKeyEvent_getMetaState | ( | const AInputEvent * | key_event | ) |
Get the meta key state.
int32_t AKeyEvent_getRepeatCount | ( | const AInputEvent * | key_event | ) |
Get the repeat count of the event. For both key up an key down events, this is the number of times the key has repeated with the first down starting at 0 and counting up from there. For multiple key events, this is the number of down/up pairs that have occurred.
int32_t AKeyEvent_getScanCode | ( | const AInputEvent * | key_event | ) |
Get the hardware key id of this key event. These values are not reliable and vary from device to device.
int32_t AMotionEvent_getAction | ( | const AInputEvent * | motion_event | ) |
Get the combined motion event action code and pointer index.
float AMotionEvent_getAxisValue | ( | const AInputEvent * | motion_event, |
int32_t | axis, | ||
size_t | pointer_index | ||
) |
Get the value of the request axis for the given pointer index.
int32_t AMotionEvent_getButtonState | ( | const AInputEvent * | motion_event | ) |
Get the button state of all buttons that are pressed.
int64_t AMotionEvent_getDownTime | ( | const AInputEvent * | motion_event | ) |
Get the time when the user originally pressed down to start a stream of position events, in the java.lang.System.nanoTime() time base.
int32_t AMotionEvent_getEdgeFlags | ( | const AInputEvent * | motion_event | ) |
Get a bitfield indicating which edges, if any, were touched by this motion event. For touch events, clients can use this to determine if the user's finger was touching the edge of the display.
int64_t AMotionEvent_getEventTime | ( | const AInputEvent * | motion_event | ) |
Get the time when this specific event was generated, in the java.lang.System.nanoTime() time base.
int32_t AMotionEvent_getFlags | ( | const AInputEvent * | motion_event | ) |
Get the motion event flags.
float AMotionEvent_getHistoricalAxisValue | ( | const AInputEvent * | motion_event, |
int32_t | axis, | ||
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical value of the request axis for the given pointer index that occurred between this event and the previous motion event.
int64_t AMotionEvent_getHistoricalEventTime | ( | const AInputEvent * | motion_event, |
size_t | history_index | ||
) |
Get the time that a historical movement occurred between this event and the previous event, in the java.lang.System.nanoTime() time base.
float AMotionEvent_getHistoricalOrientation | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical orientation of the touch area and tool area in radians clockwise from vertical for the given pointer index that occurred between this event and the previous motion event. An angle of 0 degrees indicates that the major axis of contact is oriented upwards, is perfectly circular or is of unknown orientation. A positive angle indicates that the major axis of contact is oriented to the right. A negative angle indicates that the major axis of contact is oriented to the left. The full range is from -PI/2 radians (finger pointing fully left) to PI/2 radians (finger pointing fully right).
float AMotionEvent_getHistoricalPressure | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical pressure of this event for the given pointer index that occurred between this event and the previous motion event. The pressure generally ranges from 0 (no pressure at all) to 1 (normal pressure), although values higher than 1 may be generated depending on the calibration of the input device.
float AMotionEvent_getHistoricalRawX | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical raw X coordinate of this event for the given pointer index that occurred between this event and the previous motion event. For touch events on the screen, this is the original location of the event on the screen, before it had been adjusted for the containing window and views. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
float AMotionEvent_getHistoricalRawY | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical raw Y coordinate of this event for the given pointer index that occurred between this event and the previous motion event. For touch events on the screen, this is the original location of the event on the screen, before it had been adjusted for the containing window and views. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
float AMotionEvent_getHistoricalSize | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the current scaled value of the approximate size for the given pointer index that occurred between this event and the previous motion event. This represents some approximation of the area of the screen being pressed; the actual value in pixels corresponding to the touch is normalized with the device specific range of values and scaled to a value between 0 and 1. The value of size can be used to determine fat touch events.
float AMotionEvent_getHistoricalToolMajor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical length of the major axis of an ellipse that describes the size of the approaching tool for the given pointer index that occurred between this event and the previous motion event. The tool area represents the estimated size of the finger or pen that is touching the device independent of its actual touch area at the point of contact.
float AMotionEvent_getHistoricalToolMinor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical length of the minor axis of an ellipse that describes the size of the approaching tool for the given pointer index that occurred between this event and the previous motion event. The tool area represents the estimated size of the finger or pen that is touching the device independent of its actual touch area at the point of contact.
float AMotionEvent_getHistoricalTouchMajor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical length of the major axis of an ellipse that describes the touch area at the point of contact for the given pointer index that occurred between this event and the previous motion event.
float AMotionEvent_getHistoricalTouchMinor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical length of the minor axis of an ellipse that describes the touch area at the point of contact for the given pointer index that occurred between this event and the previous motion event.
float AMotionEvent_getHistoricalX | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical X coordinate of this event for the given pointer index that occurred between this event and the previous motion event. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
float AMotionEvent_getHistoricalY | ( | const AInputEvent * | motion_event, |
size_t | pointer_index, | ||
size_t | history_index | ||
) |
Get the historical Y coordinate of this event for the given pointer index that occurred between this event and the previous motion event. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
size_t AMotionEvent_getHistorySize | ( | const AInputEvent * | motion_event | ) |
Get the number of historical points in this event. These are movements that have occurred between this event and the previous event. This only applies to AMOTION_EVENT_ACTION_MOVE events – all other actions will have a size of 0. Historical samples are indexed from oldest to newest.
int32_t AMotionEvent_getMetaState | ( | const AInputEvent * | motion_event | ) |
Get the state of any meta / modifier keys that were in effect when the event was generated.
float AMotionEvent_getOrientation | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current orientation of the touch area and tool area in radians clockwise from vertical for the given pointer index. An angle of 0 degrees indicates that the major axis of contact is oriented upwards, is perfectly circular or is of unknown orientation. A positive angle indicates that the major axis of contact is oriented to the right. A negative angle indicates that the major axis of contact is oriented to the left. The full range is from -PI/2 radians (finger pointing fully left) to PI/2 radians (finger pointing fully right).
size_t AMotionEvent_getPointerCount | ( | const AInputEvent * | motion_event | ) |
Get the number of pointers of data contained in this event. Always >= 1.
int32_t AMotionEvent_getPointerId | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the pointer identifier associated with a particular pointer data index in this event. The identifier tells you the actual pointer number associated with the data, accounting for individual pointers going up and down since the start of the current gesture.
float AMotionEvent_getPressure | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current pressure of this event for the given pointer index. The pressure generally ranges from 0 (no pressure at all) to 1 (normal pressure), although values higher than 1 may be generated depending on the calibration of the input device.
float AMotionEvent_getRawX | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the original raw X coordinate of this event. For touch events on the screen, this is the original location of the event on the screen, before it had been adjusted for the containing window and views.
float AMotionEvent_getRawY | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the original raw X coordinate of this event. For touch events on the screen, this is the original location of the event on the screen, before it had been adjusted for the containing window and views.
float AMotionEvent_getSize | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current scaled value of the approximate size for the given pointer index. This represents some approximation of the area of the screen being pressed; the actual value in pixels corresponding to the touch is normalized with the device specific range of values and scaled to a value between 0 and 1. The value of size can be used to determine fat touch events.
float AMotionEvent_getToolMajor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current length of the major axis of an ellipse that describes the size of the approaching tool for the given pointer index. The tool area represents the estimated size of the finger or pen that is touching the device independent of its actual touch area at the point of contact.
float AMotionEvent_getToolMinor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current length of the minor axis of an ellipse that describes the size of the approaching tool for the given pointer index. The tool area represents the estimated size of the finger or pen that is touching the device independent of its actual touch area at the point of contact.
int32_t AMotionEvent_getToolType | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the tool type of a pointer for the given pointer index. The tool type indicates the type of tool used to make contact such as a finger or stylus, if known.
float AMotionEvent_getTouchMajor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current length of the major axis of an ellipse that describes the touch area at the point of contact for the given pointer index.
float AMotionEvent_getTouchMinor | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current length of the minor axis of an ellipse that describes the touch area at the point of contact for the given pointer index.
float AMotionEvent_getX | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current X coordinate of this event for the given pointer index. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
float AMotionEvent_getXOffset | ( | const AInputEvent * | motion_event | ) |
Get the X coordinate offset. For touch events on the screen, this is the delta that was added to the raw screen coordinates to adjust for the absolute position of the containing windows and views.
float AMotionEvent_getXPrecision | ( | const AInputEvent * | motion_event | ) |
Get the precision of the X coordinates being reported. You can multiply this number with an X coordinate sample to find the actual hardware value of the X coordinate.
float AMotionEvent_getY | ( | const AInputEvent * | motion_event, |
size_t | pointer_index | ||
) |
Get the current Y coordinate of this event for the given pointer index. Whole numbers are pixels; the value may have a fraction for input devices that are sub-pixel precise.
float AMotionEvent_getYOffset | ( | const AInputEvent * | motion_event | ) |
Get the Y coordinate offset. For touch events on the screen, this is the delta that was added to the raw screen coordinates to adjust for the absolute position of the containing windows and views.
float AMotionEvent_getYPrecision | ( | const AInputEvent * | motion_event | ) |
Get the precision of the Y coordinates being reported. You can multiply this number with a Y coordinate sample to find the actual hardware value of the Y coordinate.