android.view
Class KeyEvent
java.lang.Object
android.view.InputEvent
android.view.KeyEvent
- All Implemented Interfaces:
- Parcelable
public class KeyEvent
- extends InputEvent
- implements Parcelable
Constructor Summary |
KeyEvent(int action,
int code)
|
KeyEvent(KeyEvent origEvent)
|
KeyEvent(KeyEvent origEvent,
long eventTime,
int newRepeat)
|
KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat)
|
KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState)
|
KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode)
|
KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode,
int flags)
|
KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode,
int flags,
int source)
|
KeyEvent(long time,
String characters,
int deviceId,
int flags)
|
Method Summary |
static KeyEvent |
changeAction(KeyEvent event,
int action)
|
static KeyEvent |
changeFlags(KeyEvent event,
int flags)
|
static KeyEvent |
changeTimeRepeat(KeyEvent event,
long eventTime,
int newRepeat)
|
static KeyEvent |
changeTimeRepeat(KeyEvent event,
long eventTime,
int newRepeat,
int newFlags)
|
boolean |
dispatch(KeyEvent.Callback receiver)
|
boolean |
dispatch(KeyEvent.Callback receiver,
KeyEvent.DispatcherState state,
Object target)
|
int |
getAction()
|
String |
getCharacters()
|
static int |
getDeadChar(int accent,
int c)
|
int |
getDeviceId()
|
char |
getDisplayLabel()
|
long |
getDownTime()
|
long |
getEventTime()
|
int |
getFlags()
|
KeyCharacterMap |
getKeyCharacterMap()
|
int |
getKeyCode()
|
boolean |
getKeyData(KeyCharacterMap.KeyData results)
|
char |
getMatch(char[] chars)
|
char |
getMatch(char[] chars,
int metaState)
|
static int |
getMaxKeyCode()
|
int |
getMetaState()
|
static int |
getModifierMetaStateMask()
|
int |
getModifiers()
|
char |
getNumber()
|
int |
getRepeatCount()
|
int |
getScanCode()
|
int |
getSource()
|
int |
getUnicodeChar()
|
int |
getUnicodeChar(int metaState)
|
boolean |
hasModifiers(int modifiers)
|
boolean |
hasNoModifiers()
|
boolean |
isAltPressed()
|
boolean |
isCanceled()
|
boolean |
isCapsLockOn()
|
boolean |
isCtrlPressed()
|
boolean |
isFunctionPressed()
|
static boolean |
isGamepadButton(int keyCode)
|
boolean |
isLongPress()
|
boolean |
isMetaPressed()
|
static boolean |
isModifierKey(int keyCode)
|
boolean |
isNumLockOn()
|
boolean |
isPrintingKey()
|
boolean |
isScrollLockOn()
|
boolean |
isShiftPressed()
|
boolean |
isSymPressed()
|
boolean |
isSystem()
|
boolean |
isTracking()
|
static int |
keyCodeFromString(String symbolicName)
|
static String |
keyCodeToString(int keyCode)
|
static boolean |
metaStateHasModifiers(int metaState,
int modifiers)
|
static boolean |
metaStateHasNoModifiers(int metaState)
|
static int |
normalizeMetaState(int metaState)
|
void |
setSource(int source)
|
void |
startTracking()
|
String |
toString()
|
void |
writeToParcel(Parcel out,
int flags)
|
KEYCODE_UNKNOWN
public static final int KEYCODE_UNKNOWN
- See Also:
- Constant Field Values
KEYCODE_SOFT_LEFT
public static final int KEYCODE_SOFT_LEFT
- See Also:
- Constant Field Values
KEYCODE_SOFT_RIGHT
public static final int KEYCODE_SOFT_RIGHT
- See Also:
- Constant Field Values
KEYCODE_HOME
public static final int KEYCODE_HOME
- See Also:
- Constant Field Values
KEYCODE_BACK
public static final int KEYCODE_BACK
- See Also:
- Constant Field Values
KEYCODE_CALL
public static final int KEYCODE_CALL
- See Also:
- Constant Field Values
KEYCODE_ENDCALL
public static final int KEYCODE_ENDCALL
- See Also:
- Constant Field Values
KEYCODE_0
public static final int KEYCODE_0
- See Also:
- Constant Field Values
KEYCODE_1
public static final int KEYCODE_1
- See Also:
- Constant Field Values
KEYCODE_2
public static final int KEYCODE_2
- See Also:
- Constant Field Values
KEYCODE_3
public static final int KEYCODE_3
- See Also:
- Constant Field Values
KEYCODE_4
public static final int KEYCODE_4
- See Also:
- Constant Field Values
KEYCODE_5
public static final int KEYCODE_5
- See Also:
- Constant Field Values
KEYCODE_6
public static final int KEYCODE_6
- See Also:
- Constant Field Values
KEYCODE_7
public static final int KEYCODE_7
- See Also:
- Constant Field Values
KEYCODE_8
public static final int KEYCODE_8
- See Also:
- Constant Field Values
KEYCODE_9
public static final int KEYCODE_9
- See Also:
- Constant Field Values
KEYCODE_STAR
public static final int KEYCODE_STAR
- See Also:
- Constant Field Values
KEYCODE_POUND
public static final int KEYCODE_POUND
- See Also:
- Constant Field Values
KEYCODE_DPAD_UP
public static final int KEYCODE_DPAD_UP
- See Also:
- Constant Field Values
KEYCODE_DPAD_DOWN
public static final int KEYCODE_DPAD_DOWN
- See Also:
- Constant Field Values
KEYCODE_DPAD_LEFT
public static final int KEYCODE_DPAD_LEFT
- See Also:
- Constant Field Values
KEYCODE_DPAD_RIGHT
public static final int KEYCODE_DPAD_RIGHT
- See Also:
- Constant Field Values
KEYCODE_DPAD_CENTER
public static final int KEYCODE_DPAD_CENTER
- See Also:
- Constant Field Values
KEYCODE_VOLUME_UP
public static final int KEYCODE_VOLUME_UP
- See Also:
- Constant Field Values
KEYCODE_VOLUME_DOWN
public static final int KEYCODE_VOLUME_DOWN
- See Also:
- Constant Field Values
KEYCODE_POWER
public static final int KEYCODE_POWER
- See Also:
- Constant Field Values
KEYCODE_CAMERA
public static final int KEYCODE_CAMERA
- See Also:
- Constant Field Values
KEYCODE_CLEAR
public static final int KEYCODE_CLEAR
- See Also:
- Constant Field Values
KEYCODE_A
public static final int KEYCODE_A
- See Also:
- Constant Field Values
KEYCODE_B
public static final int KEYCODE_B
- See Also:
- Constant Field Values
KEYCODE_C
public static final int KEYCODE_C
- See Also:
- Constant Field Values
KEYCODE_D
public static final int KEYCODE_D
- See Also:
- Constant Field Values
KEYCODE_E
public static final int KEYCODE_E
- See Also:
- Constant Field Values
KEYCODE_F
public static final int KEYCODE_F
- See Also:
- Constant Field Values
KEYCODE_G
public static final int KEYCODE_G
- See Also:
- Constant Field Values
KEYCODE_H
public static final int KEYCODE_H
- See Also:
- Constant Field Values
KEYCODE_I
public static final int KEYCODE_I
- See Also:
- Constant Field Values
KEYCODE_J
public static final int KEYCODE_J
- See Also:
- Constant Field Values
KEYCODE_K
public static final int KEYCODE_K
- See Also:
- Constant Field Values
KEYCODE_L
public static final int KEYCODE_L
- See Also:
- Constant Field Values
KEYCODE_M
public static final int KEYCODE_M
- See Also:
- Constant Field Values
KEYCODE_N
public static final int KEYCODE_N
- See Also:
- Constant Field Values
KEYCODE_O
public static final int KEYCODE_O
- See Also:
- Constant Field Values
KEYCODE_P
public static final int KEYCODE_P
- See Also:
- Constant Field Values
KEYCODE_Q
public static final int KEYCODE_Q
- See Also:
- Constant Field Values
KEYCODE_R
public static final int KEYCODE_R
- See Also:
- Constant Field Values
KEYCODE_S
public static final int KEYCODE_S
- See Also:
- Constant Field Values
KEYCODE_T
public static final int KEYCODE_T
- See Also:
- Constant Field Values
KEYCODE_U
public static final int KEYCODE_U
- See Also:
- Constant Field Values
KEYCODE_V
public static final int KEYCODE_V
- See Also:
- Constant Field Values
KEYCODE_W
public static final int KEYCODE_W
- See Also:
- Constant Field Values
KEYCODE_X
public static final int KEYCODE_X
- See Also:
- Constant Field Values
KEYCODE_Y
public static final int KEYCODE_Y
- See Also:
- Constant Field Values
KEYCODE_Z
public static final int KEYCODE_Z
- See Also:
- Constant Field Values
KEYCODE_COMMA
public static final int KEYCODE_COMMA
- See Also:
- Constant Field Values
KEYCODE_PERIOD
public static final int KEYCODE_PERIOD
- See Also:
- Constant Field Values
KEYCODE_ALT_LEFT
public static final int KEYCODE_ALT_LEFT
- See Also:
- Constant Field Values
KEYCODE_ALT_RIGHT
public static final int KEYCODE_ALT_RIGHT
- See Also:
- Constant Field Values
KEYCODE_SHIFT_LEFT
public static final int KEYCODE_SHIFT_LEFT
- See Also:
- Constant Field Values
KEYCODE_SHIFT_RIGHT
public static final int KEYCODE_SHIFT_RIGHT
- See Also:
- Constant Field Values
KEYCODE_TAB
public static final int KEYCODE_TAB
- See Also:
- Constant Field Values
KEYCODE_SPACE
public static final int KEYCODE_SPACE
- See Also:
- Constant Field Values
KEYCODE_SYM
public static final int KEYCODE_SYM
- See Also:
- Constant Field Values
KEYCODE_EXPLORER
public static final int KEYCODE_EXPLORER
- See Also:
- Constant Field Values
KEYCODE_ENVELOPE
public static final int KEYCODE_ENVELOPE
- See Also:
- Constant Field Values
KEYCODE_ENTER
public static final int KEYCODE_ENTER
- See Also:
- Constant Field Values
KEYCODE_DEL
public static final int KEYCODE_DEL
- See Also:
- Constant Field Values
KEYCODE_GRAVE
public static final int KEYCODE_GRAVE
- See Also:
- Constant Field Values
KEYCODE_MINUS
public static final int KEYCODE_MINUS
- See Also:
- Constant Field Values
KEYCODE_EQUALS
public static final int KEYCODE_EQUALS
- See Also:
- Constant Field Values
KEYCODE_LEFT_BRACKET
public static final int KEYCODE_LEFT_BRACKET
- See Also:
- Constant Field Values
KEYCODE_RIGHT_BRACKET
public static final int KEYCODE_RIGHT_BRACKET
- See Also:
- Constant Field Values
KEYCODE_BACKSLASH
public static final int KEYCODE_BACKSLASH
- See Also:
- Constant Field Values
KEYCODE_SEMICOLON
public static final int KEYCODE_SEMICOLON
- See Also:
- Constant Field Values
KEYCODE_APOSTROPHE
public static final int KEYCODE_APOSTROPHE
- See Also:
- Constant Field Values
KEYCODE_SLASH
public static final int KEYCODE_SLASH
- See Also:
- Constant Field Values
KEYCODE_AT
public static final int KEYCODE_AT
- See Also:
- Constant Field Values
KEYCODE_NUM
public static final int KEYCODE_NUM
- See Also:
- Constant Field Values
KEYCODE_HEADSETHOOK
public static final int KEYCODE_HEADSETHOOK
- See Also:
- Constant Field Values
KEYCODE_FOCUS
public static final int KEYCODE_FOCUS
- See Also:
- Constant Field Values
KEYCODE_PLUS
public static final int KEYCODE_PLUS
- See Also:
- Constant Field Values
KEYCODE_MENU
public static final int KEYCODE_MENU
- See Also:
- Constant Field Values
KEYCODE_NOTIFICATION
public static final int KEYCODE_NOTIFICATION
- See Also:
- Constant Field Values
KEYCODE_SEARCH
public static final int KEYCODE_SEARCH
- See Also:
- Constant Field Values
KEYCODE_MEDIA_PLAY_PAUSE
public static final int KEYCODE_MEDIA_PLAY_PAUSE
- See Also:
- Constant Field Values
KEYCODE_MEDIA_STOP
public static final int KEYCODE_MEDIA_STOP
- See Also:
- Constant Field Values
KEYCODE_MEDIA_NEXT
public static final int KEYCODE_MEDIA_NEXT
- See Also:
- Constant Field Values
KEYCODE_MEDIA_PREVIOUS
public static final int KEYCODE_MEDIA_PREVIOUS
- See Also:
- Constant Field Values
KEYCODE_MEDIA_REWIND
public static final int KEYCODE_MEDIA_REWIND
- See Also:
- Constant Field Values
KEYCODE_MEDIA_FAST_FORWARD
public static final int KEYCODE_MEDIA_FAST_FORWARD
- See Also:
- Constant Field Values
KEYCODE_MUTE
public static final int KEYCODE_MUTE
- See Also:
- Constant Field Values
KEYCODE_PAGE_UP
public static final int KEYCODE_PAGE_UP
- See Also:
- Constant Field Values
KEYCODE_PAGE_DOWN
public static final int KEYCODE_PAGE_DOWN
- See Also:
- Constant Field Values
KEYCODE_PICTSYMBOLS
public static final int KEYCODE_PICTSYMBOLS
- See Also:
- Constant Field Values
KEYCODE_SWITCH_CHARSET
public static final int KEYCODE_SWITCH_CHARSET
- See Also:
- Constant Field Values
KEYCODE_BUTTON_A
public static final int KEYCODE_BUTTON_A
- See Also:
- Constant Field Values
KEYCODE_BUTTON_B
public static final int KEYCODE_BUTTON_B
- See Also:
- Constant Field Values
KEYCODE_BUTTON_C
public static final int KEYCODE_BUTTON_C
- See Also:
- Constant Field Values
KEYCODE_BUTTON_X
public static final int KEYCODE_BUTTON_X
- See Also:
- Constant Field Values
KEYCODE_BUTTON_Y
public static final int KEYCODE_BUTTON_Y
- See Also:
- Constant Field Values
KEYCODE_BUTTON_Z
public static final int KEYCODE_BUTTON_Z
- See Also:
- Constant Field Values
KEYCODE_BUTTON_L1
public static final int KEYCODE_BUTTON_L1
- See Also:
- Constant Field Values
KEYCODE_BUTTON_R1
public static final int KEYCODE_BUTTON_R1
- See Also:
- Constant Field Values
KEYCODE_BUTTON_L2
public static final int KEYCODE_BUTTON_L2
- See Also:
- Constant Field Values
KEYCODE_BUTTON_R2
public static final int KEYCODE_BUTTON_R2
- See Also:
- Constant Field Values
KEYCODE_BUTTON_THUMBL
public static final int KEYCODE_BUTTON_THUMBL
- See Also:
- Constant Field Values
KEYCODE_BUTTON_THUMBR
public static final int KEYCODE_BUTTON_THUMBR
- See Also:
- Constant Field Values
KEYCODE_BUTTON_START
public static final int KEYCODE_BUTTON_START
- See Also:
- Constant Field Values
KEYCODE_BUTTON_SELECT
public static final int KEYCODE_BUTTON_SELECT
- See Also:
- Constant Field Values
KEYCODE_BUTTON_MODE
public static final int KEYCODE_BUTTON_MODE
- See Also:
- Constant Field Values
KEYCODE_ESCAPE
public static final int KEYCODE_ESCAPE
- See Also:
- Constant Field Values
KEYCODE_FORWARD_DEL
public static final int KEYCODE_FORWARD_DEL
- See Also:
- Constant Field Values
KEYCODE_CTRL_LEFT
public static final int KEYCODE_CTRL_LEFT
- See Also:
- Constant Field Values
KEYCODE_CTRL_RIGHT
public static final int KEYCODE_CTRL_RIGHT
- See Also:
- Constant Field Values
KEYCODE_CAPS_LOCK
public static final int KEYCODE_CAPS_LOCK
- See Also:
- Constant Field Values
KEYCODE_SCROLL_LOCK
public static final int KEYCODE_SCROLL_LOCK
- See Also:
- Constant Field Values
KEYCODE_META_LEFT
public static final int KEYCODE_META_LEFT
- See Also:
- Constant Field Values
KEYCODE_META_RIGHT
public static final int KEYCODE_META_RIGHT
- See Also:
- Constant Field Values
KEYCODE_FUNCTION
public static final int KEYCODE_FUNCTION
- See Also:
- Constant Field Values
KEYCODE_SYSRQ
public static final int KEYCODE_SYSRQ
- See Also:
- Constant Field Values
KEYCODE_BREAK
public static final int KEYCODE_BREAK
- See Also:
- Constant Field Values
KEYCODE_MOVE_HOME
public static final int KEYCODE_MOVE_HOME
- See Also:
- Constant Field Values
KEYCODE_MOVE_END
public static final int KEYCODE_MOVE_END
- See Also:
- Constant Field Values
KEYCODE_INSERT
public static final int KEYCODE_INSERT
- See Also:
- Constant Field Values
KEYCODE_FORWARD
public static final int KEYCODE_FORWARD
- See Also:
- Constant Field Values
KEYCODE_MEDIA_PLAY
public static final int KEYCODE_MEDIA_PLAY
- See Also:
- Constant Field Values
KEYCODE_MEDIA_PAUSE
public static final int KEYCODE_MEDIA_PAUSE
- See Also:
- Constant Field Values
KEYCODE_MEDIA_CLOSE
public static final int KEYCODE_MEDIA_CLOSE
- See Also:
- Constant Field Values
KEYCODE_MEDIA_EJECT
public static final int KEYCODE_MEDIA_EJECT
- See Also:
- Constant Field Values
KEYCODE_MEDIA_RECORD
public static final int KEYCODE_MEDIA_RECORD
- See Also:
- Constant Field Values
KEYCODE_F1
public static final int KEYCODE_F1
- See Also:
- Constant Field Values
KEYCODE_F2
public static final int KEYCODE_F2
- See Also:
- Constant Field Values
KEYCODE_F3
public static final int KEYCODE_F3
- See Also:
- Constant Field Values
KEYCODE_F4
public static final int KEYCODE_F4
- See Also:
- Constant Field Values
KEYCODE_F5
public static final int KEYCODE_F5
- See Also:
- Constant Field Values
KEYCODE_F6
public static final int KEYCODE_F6
- See Also:
- Constant Field Values
KEYCODE_F7
public static final int KEYCODE_F7
- See Also:
- Constant Field Values
KEYCODE_F8
public static final int KEYCODE_F8
- See Also:
- Constant Field Values
KEYCODE_F9
public static final int KEYCODE_F9
- See Also:
- Constant Field Values
KEYCODE_F10
public static final int KEYCODE_F10
- See Also:
- Constant Field Values
KEYCODE_F11
public static final int KEYCODE_F11
- See Also:
- Constant Field Values
KEYCODE_F12
public static final int KEYCODE_F12
- See Also:
- Constant Field Values
KEYCODE_NUM_LOCK
public static final int KEYCODE_NUM_LOCK
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_0
public static final int KEYCODE_NUMPAD_0
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_1
public static final int KEYCODE_NUMPAD_1
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_2
public static final int KEYCODE_NUMPAD_2
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_3
public static final int KEYCODE_NUMPAD_3
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_4
public static final int KEYCODE_NUMPAD_4
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_5
public static final int KEYCODE_NUMPAD_5
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_6
public static final int KEYCODE_NUMPAD_6
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_7
public static final int KEYCODE_NUMPAD_7
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_8
public static final int KEYCODE_NUMPAD_8
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_9
public static final int KEYCODE_NUMPAD_9
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_DIVIDE
public static final int KEYCODE_NUMPAD_DIVIDE
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_MULTIPLY
public static final int KEYCODE_NUMPAD_MULTIPLY
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_SUBTRACT
public static final int KEYCODE_NUMPAD_SUBTRACT
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_ADD
public static final int KEYCODE_NUMPAD_ADD
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_DOT
public static final int KEYCODE_NUMPAD_DOT
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_COMMA
public static final int KEYCODE_NUMPAD_COMMA
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_ENTER
public static final int KEYCODE_NUMPAD_ENTER
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_EQUALS
public static final int KEYCODE_NUMPAD_EQUALS
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_LEFT_PAREN
public static final int KEYCODE_NUMPAD_LEFT_PAREN
- See Also:
- Constant Field Values
KEYCODE_NUMPAD_RIGHT_PAREN
public static final int KEYCODE_NUMPAD_RIGHT_PAREN
- See Also:
- Constant Field Values
KEYCODE_VOLUME_MUTE
public static final int KEYCODE_VOLUME_MUTE
- See Also:
- Constant Field Values
KEYCODE_INFO
public static final int KEYCODE_INFO
- See Also:
- Constant Field Values
KEYCODE_CHANNEL_UP
public static final int KEYCODE_CHANNEL_UP
- See Also:
- Constant Field Values
KEYCODE_CHANNEL_DOWN
public static final int KEYCODE_CHANNEL_DOWN
- See Also:
- Constant Field Values
KEYCODE_ZOOM_IN
public static final int KEYCODE_ZOOM_IN
- See Also:
- Constant Field Values
KEYCODE_ZOOM_OUT
public static final int KEYCODE_ZOOM_OUT
- See Also:
- Constant Field Values
KEYCODE_TV
public static final int KEYCODE_TV
- See Also:
- Constant Field Values
KEYCODE_WINDOW
public static final int KEYCODE_WINDOW
- See Also:
- Constant Field Values
KEYCODE_GUIDE
public static final int KEYCODE_GUIDE
- See Also:
- Constant Field Values
KEYCODE_DVR
public static final int KEYCODE_DVR
- See Also:
- Constant Field Values
KEYCODE_BOOKMARK
public static final int KEYCODE_BOOKMARK
- See Also:
- Constant Field Values
KEYCODE_CAPTIONS
public static final int KEYCODE_CAPTIONS
- See Also:
- Constant Field Values
KEYCODE_SETTINGS
public static final int KEYCODE_SETTINGS
- See Also:
- Constant Field Values
KEYCODE_TV_POWER
public static final int KEYCODE_TV_POWER
- See Also:
- Constant Field Values
KEYCODE_TV_INPUT
public static final int KEYCODE_TV_INPUT
- See Also:
- Constant Field Values
KEYCODE_STB_POWER
public static final int KEYCODE_STB_POWER
- See Also:
- Constant Field Values
KEYCODE_STB_INPUT
public static final int KEYCODE_STB_INPUT
- See Also:
- Constant Field Values
KEYCODE_AVR_POWER
public static final int KEYCODE_AVR_POWER
- See Also:
- Constant Field Values
KEYCODE_AVR_INPUT
public static final int KEYCODE_AVR_INPUT
- See Also:
- Constant Field Values
KEYCODE_PROG_RED
public static final int KEYCODE_PROG_RED
- See Also:
- Constant Field Values
KEYCODE_PROG_GREEN
public static final int KEYCODE_PROG_GREEN
- See Also:
- Constant Field Values
KEYCODE_PROG_YELLOW
public static final int KEYCODE_PROG_YELLOW
- See Also:
- Constant Field Values
KEYCODE_PROG_BLUE
public static final int KEYCODE_PROG_BLUE
- See Also:
- Constant Field Values
KEYCODE_APP_SWITCH
public static final int KEYCODE_APP_SWITCH
- See Also:
- Constant Field Values
KEYCODE_BUTTON_1
public static final int KEYCODE_BUTTON_1
- See Also:
- Constant Field Values
KEYCODE_BUTTON_2
public static final int KEYCODE_BUTTON_2
- See Also:
- Constant Field Values
KEYCODE_BUTTON_3
public static final int KEYCODE_BUTTON_3
- See Also:
- Constant Field Values
KEYCODE_BUTTON_4
public static final int KEYCODE_BUTTON_4
- See Also:
- Constant Field Values
KEYCODE_BUTTON_5
public static final int KEYCODE_BUTTON_5
- See Also:
- Constant Field Values
KEYCODE_BUTTON_6
public static final int KEYCODE_BUTTON_6
- See Also:
- Constant Field Values
KEYCODE_BUTTON_7
public static final int KEYCODE_BUTTON_7
- See Also:
- Constant Field Values
KEYCODE_BUTTON_8
public static final int KEYCODE_BUTTON_8
- See Also:
- Constant Field Values
KEYCODE_BUTTON_9
public static final int KEYCODE_BUTTON_9
- See Also:
- Constant Field Values
KEYCODE_BUTTON_10
public static final int KEYCODE_BUTTON_10
- See Also:
- Constant Field Values
KEYCODE_BUTTON_11
public static final int KEYCODE_BUTTON_11
- See Also:
- Constant Field Values
KEYCODE_BUTTON_12
public static final int KEYCODE_BUTTON_12
- See Also:
- Constant Field Values
KEYCODE_BUTTON_13
public static final int KEYCODE_BUTTON_13
- See Also:
- Constant Field Values
KEYCODE_BUTTON_14
public static final int KEYCODE_BUTTON_14
- See Also:
- Constant Field Values
KEYCODE_BUTTON_15
public static final int KEYCODE_BUTTON_15
- See Also:
- Constant Field Values
KEYCODE_BUTTON_16
public static final int KEYCODE_BUTTON_16
- See Also:
- Constant Field Values
KEYCODE_LANGUAGE_SWITCH
public static final int KEYCODE_LANGUAGE_SWITCH
- See Also:
- Constant Field Values
KEYCODE_MANNER_MODE
public static final int KEYCODE_MANNER_MODE
- See Also:
- Constant Field Values
KEYCODE_3D_MODE
public static final int KEYCODE_3D_MODE
- See Also:
- Constant Field Values
MAX_KEYCODE
public static final int MAX_KEYCODE
- See Also:
- Constant Field Values
ACTION_DOWN
public static final int ACTION_DOWN
- See Also:
- Constant Field Values
ACTION_UP
public static final int ACTION_UP
- See Also:
- Constant Field Values
ACTION_MULTIPLE
public static final int ACTION_MULTIPLE
- See Also:
- Constant Field Values
META_ALT_ON
public static final int META_ALT_ON
- See Also:
- Constant Field Values
META_ALT_LEFT_ON
public static final int META_ALT_LEFT_ON
- See Also:
- Constant Field Values
META_ALT_RIGHT_ON
public static final int META_ALT_RIGHT_ON
- See Also:
- Constant Field Values
META_SHIFT_ON
public static final int META_SHIFT_ON
- See Also:
- Constant Field Values
META_SHIFT_LEFT_ON
public static final int META_SHIFT_LEFT_ON
- See Also:
- Constant Field Values
META_SHIFT_RIGHT_ON
public static final int META_SHIFT_RIGHT_ON
- See Also:
- Constant Field Values
META_SYM_ON
public static final int META_SYM_ON
- See Also:
- Constant Field Values
META_FUNCTION_ON
public static final int META_FUNCTION_ON
- See Also:
- Constant Field Values
META_CTRL_ON
public static final int META_CTRL_ON
- See Also:
- Constant Field Values
META_CTRL_LEFT_ON
public static final int META_CTRL_LEFT_ON
- See Also:
- Constant Field Values
META_CTRL_RIGHT_ON
public static final int META_CTRL_RIGHT_ON
- See Also:
- Constant Field Values
META_META_ON
public static final int META_META_ON
- See Also:
- Constant Field Values
META_META_LEFT_ON
public static final int META_META_LEFT_ON
- See Also:
- Constant Field Values
META_META_RIGHT_ON
public static final int META_META_RIGHT_ON
- See Also:
- Constant Field Values
META_CAPS_LOCK_ON
public static final int META_CAPS_LOCK_ON
- See Also:
- Constant Field Values
META_NUM_LOCK_ON
public static final int META_NUM_LOCK_ON
- See Also:
- Constant Field Values
META_SCROLL_LOCK_ON
public static final int META_SCROLL_LOCK_ON
- See Also:
- Constant Field Values
META_SHIFT_MASK
public static final int META_SHIFT_MASK
- See Also:
- Constant Field Values
META_ALT_MASK
public static final int META_ALT_MASK
- See Also:
- Constant Field Values
META_CTRL_MASK
public static final int META_CTRL_MASK
- See Also:
- Constant Field Values
META_META_MASK
public static final int META_META_MASK
- See Also:
- Constant Field Values
FLAG_WOKE_HERE
public static final int FLAG_WOKE_HERE
- See Also:
- Constant Field Values
FLAG_SOFT_KEYBOARD
public static final int FLAG_SOFT_KEYBOARD
- See Also:
- Constant Field Values
FLAG_KEEP_TOUCH_MODE
public static final int FLAG_KEEP_TOUCH_MODE
- See Also:
- Constant Field Values
FLAG_FROM_SYSTEM
public static final int FLAG_FROM_SYSTEM
- See Also:
- Constant Field Values
FLAG_EDITOR_ACTION
public static final int FLAG_EDITOR_ACTION
- See Also:
- Constant Field Values
FLAG_CANCELED
public static final int FLAG_CANCELED
- See Also:
- Constant Field Values
FLAG_VIRTUAL_HARD_KEY
public static final int FLAG_VIRTUAL_HARD_KEY
- See Also:
- Constant Field Values
FLAG_LONG_PRESS
public static final int FLAG_LONG_PRESS
- See Also:
- Constant Field Values
FLAG_CANCELED_LONG_PRESS
public static final int FLAG_CANCELED_LONG_PRESS
- See Also:
- Constant Field Values
FLAG_TRACKING
public static final int FLAG_TRACKING
- See Also:
- Constant Field Values
FLAG_FALLBACK
public static final int FLAG_FALLBACK
- See Also:
- Constant Field Values
CREATOR
public static final Parcelable.Creator<KeyEvent> CREATOR
KeyEvent
public KeyEvent(int action,
int code)
KeyEvent
public KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat)
KeyEvent
public KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState)
KeyEvent
public KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode)
KeyEvent
public KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode,
int flags)
KeyEvent
public KeyEvent(long downTime,
long eventTime,
int action,
int code,
int repeat,
int metaState,
int deviceId,
int scancode,
int flags,
int source)
KeyEvent
public KeyEvent(long time,
String characters,
int deviceId,
int flags)
KeyEvent
public KeyEvent(KeyEvent origEvent)
KeyEvent
public KeyEvent(KeyEvent origEvent,
long eventTime,
int newRepeat)
getMaxKeyCode
public static int getMaxKeyCode()
getDeadChar
public static int getDeadChar(int accent,
int c)
changeTimeRepeat
public static KeyEvent changeTimeRepeat(KeyEvent event,
long eventTime,
int newRepeat)
changeTimeRepeat
public static KeyEvent changeTimeRepeat(KeyEvent event,
long eventTime,
int newRepeat,
int newFlags)
changeAction
public static KeyEvent changeAction(KeyEvent event,
int action)
changeFlags
public static KeyEvent changeFlags(KeyEvent event,
int flags)
isSystem
public final boolean isSystem()
isGamepadButton
public static final boolean isGamepadButton(int keyCode)
getDeviceId
public final int getDeviceId()
- Specified by:
getDeviceId
in class InputEvent
getSource
public final int getSource()
- Specified by:
getSource
in class InputEvent
setSource
public final void setSource(int source)
getMetaState
public final int getMetaState()
getModifiers
public final int getModifiers()
getFlags
public final int getFlags()
getModifierMetaStateMask
public static int getModifierMetaStateMask()
isModifierKey
public static boolean isModifierKey(int keyCode)
normalizeMetaState
public static int normalizeMetaState(int metaState)
metaStateHasNoModifiers
public static boolean metaStateHasNoModifiers(int metaState)
metaStateHasModifiers
public static boolean metaStateHasModifiers(int metaState,
int modifiers)
hasNoModifiers
public final boolean hasNoModifiers()
hasModifiers
public final boolean hasModifiers(int modifiers)
isAltPressed
public final boolean isAltPressed()
isShiftPressed
public final boolean isShiftPressed()
isSymPressed
public final boolean isSymPressed()
isCtrlPressed
public final boolean isCtrlPressed()
isMetaPressed
public final boolean isMetaPressed()
isFunctionPressed
public final boolean isFunctionPressed()
isCapsLockOn
public final boolean isCapsLockOn()
isNumLockOn
public final boolean isNumLockOn()
isScrollLockOn
public final boolean isScrollLockOn()
getAction
public final int getAction()
isCanceled
public final boolean isCanceled()
startTracking
public final void startTracking()
isTracking
public final boolean isTracking()
isLongPress
public final boolean isLongPress()
getKeyCode
public final int getKeyCode()
getCharacters
public final String getCharacters()
getScanCode
public final int getScanCode()
getRepeatCount
public final int getRepeatCount()
getDownTime
public final long getDownTime()
getEventTime
public final long getEventTime()
getKeyCharacterMap
public final KeyCharacterMap getKeyCharacterMap()
getDisplayLabel
public char getDisplayLabel()
getUnicodeChar
public int getUnicodeChar()
getUnicodeChar
public int getUnicodeChar(int metaState)
getKeyData
public boolean getKeyData(KeyCharacterMap.KeyData results)
getMatch
public char getMatch(char[] chars)
getMatch
public char getMatch(char[] chars,
int metaState)
getNumber
public char getNumber()
isPrintingKey
public boolean isPrintingKey()
dispatch
public final boolean dispatch(KeyEvent.Callback receiver)
dispatch
public final boolean dispatch(KeyEvent.Callback receiver,
KeyEvent.DispatcherState state,
Object target)
toString
public String toString()
- Overrides:
toString
in class Object
keyCodeToString
public static String keyCodeToString(int keyCode)
keyCodeFromString
public static int keyCodeFromString(String symbolicName)
writeToParcel
public void writeToParcel(Parcel out,
int flags)
- Specified by:
writeToParcel
in interface Parcelable
Copyright © 2008-2012. All Rights Reserved.