Keycode Keycode Enum

Definition

Enumerates values returned by several types and taken as a parameter of several types.

public enum Keycode
type Keycode = 
Inheritance
KeycodeKeycode

Fields

A A 29

Key code constant: 'A' key.

AltLeft AltLeft 57

Key code constant: Left Alt modifier key.

AltRight AltRight 58

Key code constant: Right Alt modifier key.

Apostrophe Apostrophe 75

Key code constant: ''' (apostrophe) key.

AppSwitch AppSwitch 187

Key code constant: App switch key. Should bring up the application switcher dialog.

Assist Assist 219

Key code constant: Assist key. Launches the global assist activity.

At At 77

Key code constant: '@' key.

AvrInput AvrInput 182

Key code constant: A/V Receiver input key. On TV remotes, switches the input mode on an external A/V Receiver.

AvrPower AvrPower 181

Key code constant: A/V Receiver power key. On TV remotes, toggles the power on an external A/V Receiver.

B B 30

Key code constant: 'B' key.

Back Back 4

Key code constant: Back key.

Backslash Backslash 73

Key code constant: '' key.

Bookmark Bookmark 174

Key code constant: Bookmark key. On some TV remotes, bookmarks content or web pages.

Break Break 121

Key code constant: Break / Pause key.

BrightnessDown BrightnessDown 220

Key code constant: Brightness Down key. Adjusts the screen brightness down.

BrightnessUp BrightnessUp 221

Key code constant: Brightness Up key. Adjusts the screen brightness up.

Button1 Button1 188

Key code constant: Generic Game Pad Button #1.

Button10 Button10 197

Key code constant: Generic Game Pad Button #10.

Button11 Button11 198

Key code constant: Generic Game Pad Button #11.

Button12 Button12 199

Key code constant: Generic Game Pad Button #12.

Button13 Button13 200

Key code constant: Generic Game Pad Button #13.

Button14 Button14 201

Key code constant: Generic Game Pad Button #14.

Button15 Button15 202

Key code constant: Generic Game Pad Button #15.

Button16 Button16 203

Key code constant: Generic Game Pad Button #16.

Button2 Button2 189

Key code constant: Generic Game Pad Button #2.

Button3 Button3 190

Key code constant: Generic Game Pad Button #3.

Button4 Button4 191

Key code constant: Generic Game Pad Button #4.

Button5 Button5 192

Key code constant: Generic Game Pad Button #5.

Button6 Button6 193

Key code constant: Generic Game Pad Button #6.

Button7 Button7 194

Key code constant: Generic Game Pad Button #7.

Button8 Button8 195

Key code constant: Generic Game Pad Button #8.

Button9 Button9 196

Key code constant: Generic Game Pad Button #9.

ButtonA ButtonA 96

Key code constant: 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.

ButtonB ButtonB 97

Key code constant: 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.

ButtonC ButtonC 98

Key code constant: 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.

ButtonL1 ButtonL1 102

Key code constant: 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.

ButtonL2 ButtonL2 104

Key code constant: L2 Button key. On a game controller, the L2 button should be either the button labeled L2 or the bottom left trigger button.

ButtonMode ButtonMode 110

Key code constant: Mode Button key. On a game controller, the button labeled Mode.

ButtonR1 ButtonR1 103

Key code constant: 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.

ButtonR2 ButtonR2 105

Key code constant: R2 Button key. On a game controller, the R2 button should be either the button labeled R2 or the bottom right trigger button.

ButtonSelect ButtonSelect 109

Key code constant: Select Button key. On a game controller, the button labeled Select.

ButtonStart ButtonStart 108

Key code constant: Start Button key. On a game controller, the button labeled Start.

ButtonThumbl ButtonThumbl 106

Key code constant: Left Thumb Button key. On a game controller, the left thumb button indicates that the left (or only) joystick is pressed.

ButtonThumbr ButtonThumbr 107

Key code constant: Right Thumb Button key. On a game controller, the right thumb button indicates that the right joystick is pressed.

ButtonX ButtonX 99

Key code constant: 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.

ButtonY ButtonY 100

Key code constant: 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.

ButtonZ ButtonZ 101

Key code constant: 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.

C C 31

Key code constant: 'C' key.

Calculator Calculator 210

Key code constant: Calculator special function key. Used to launch a calculator application.

Calendar Calendar 208

Key code constant: Calendar special function key. Used to launch a calendar application.

Call Call 5

Key code constant: Call key.

Camera Camera 27

Key code constant: Camera key. Used to launch a camera application or take pictures.

CapsLock CapsLock 115

Key code constant: Caps Lock key.

Captions Captions 175

Key code constant: Toggle captions key. Switches the mode for closed-captioning text, for example during television shows.

ChannelDown ChannelDown 167

Key code constant: Channel down key. On TV remotes, decrements the television channel.

ChannelUp ChannelUp 166

Key code constant: Channel up key. On TV remotes, increments the television channel.

Clear Clear 28

Key code constant: Clear key.

Comma Comma 55

Key code constant: ',' key.

Contacts Contacts 207

Key code constant: Contacts special function key. Used to launch an address book application.

Copy Copy 278
CtrlLeft CtrlLeft 113

Key code constant: Left Control modifier key.

CtrlRight CtrlRight 114

Key code constant: Right Control modifier key.

Cut Cut 277
D D 32

Key code constant: 'D' key.

Del Del 67

Key code constant: Backspace key. Deletes characters before the insertion point, unlike ForwardDel.

DpadCenter DpadCenter 23

Key code constant: Directional Pad Center key. May also be synthesized from trackball motions.

DpadDown DpadDown 20

Key code constant: Directional Pad Down key. May also be synthesized from trackball motions.

DpadDownLeft DpadDownLeft 269
DpadDownRight DpadDownRight 271
DpadLeft DpadLeft 21

Key code constant: Directional Pad Left key. May also be synthesized from trackball motions.

DpadRight DpadRight 22

Key code constant: Directional Pad Right key. May also be synthesized from trackball motions.

DpadUp DpadUp 19

Key code constant: Directional Pad Up key. May also be synthesized from trackball motions.

DpadUpLeft DpadUpLeft 268
DpadUpRight DpadUpRight 270
Dvr Dvr 173

Key code constant: DVR key. On some TV remotes, switches to a DVR mode for recorded shows.

E E 33

Key code constant: 'E' key.

Eisu Eisu 212

Key code constant: Japanese alphanumeric key.

Endcall Endcall 6

Key code constant: End Call key.

Enter Enter 66

Key code constant: Enter key.

Envelope Envelope 65

Key code constant: Envelope special function key. Used to launch a mail application.

Equals Equals 70

Key code constant: '=' key.

Escape Escape 111

Key code constant: Escape key.

Explorer Explorer 64

Key code constant: Explorer special function key. Used to launch a browser application.

F F 34

Key code constant: 'F' key.

F1 F1 131

Key code constant: F1 key.

F10 F10 140

Key code constant: F10 key.

F11 F11 141

Key code constant: F11 key.

F12 F12 142

Key code constant: F12 key.

F2 F2 132

Key code constant: F2 key.

F3 F3 133

Key code constant: F3 key.

F4 F4 134

Key code constant: F4 key.

F5 F5 135

Key code constant: F5 key.

F6 F6 136

Key code constant: F6 key.

F7 F7 137

Key code constant: F7 key.

F8 F8 138

Key code constant: F8 key.

F9 F9 139

Key code constant: F9 key.

Focus Focus 80

Key code constant: Camera Focus key. Used to focus the camera.

Forward Forward 125

Key code constant: Forward key. Navigates forward in the history stack.

ForwardDel ForwardDel 112

Key code constant: Forward Delete key. Deletes characters ahead of the insertion point, unlike Del.

Function Function 119

Key code constant: Function modifier key.

G G 35

Key code constant: 'G' key.

Grave Grave 68

Key code constant: '`' (backtick) key.

Guide Guide 172

Key code constant: Guide key. On TV remotes, shows a programming guide.

H H 36

Key code constant: 'H' key.

Headsethook Headsethook 79

Key code constant: Headset Hook key. Used to hang up calls and stop media.

Help Help 259
Henkan Henkan 214

Key code constant: Japanese conversion key.

Home Home 3

Key code constant: Home key. This key is handled by the framework and is never delivered to applications.

I I 37

Key code constant: 'I' key.

Info Info 165

Key code constant: Info key. Common on TV remotes to show additional information related to what is currently being viewed.

Insert Insert 124

Key code constant: Insert key. Toggles insert / overwrite edit mode.

J J 38

Key code constant: 'J' key.

K K 39

Key code constant: 'K' key.

K11 K11 227
K12 K12 228
Kana Kana 218

Key code constant: Japanese kana key.

KatakanaHiragana KatakanaHiragana 215

Key code constant: Japanese katakana / hiragana key.

L L 40

Key code constant: 'L' key.

LanguageSwitch LanguageSwitch 204

Key code constant: Language Switch key. Toggles the current input language such as switching between English and Japanese on a QWERTY keyboard.

LastChannel LastChannel 229
LeftBracket LeftBracket 71

Key code constant: '[' key.

M M 41

Key code constant: 'M' key.

MannerMode MannerMode 205

Key code constant: 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.

MediaAudioTrack MediaAudioTrack 222
MediaClose MediaClose 128

Key code constant: Close media key. May be used to close a CD tray, for example.

MediaEject MediaEject 129

Key code constant: Eject media key. May be used to eject a CD tray, for example.

MediaFastForward MediaFastForward 90

Key code constant: Fast Forward media key.

MediaNext MediaNext 87

Key code constant: Play Next media key.

MediaPause MediaPause 127

Key code constant: Pause media key.

MediaPlay MediaPlay 126

Key code constant: Play media key.

MediaPlayPause MediaPlayPause 85

Key code constant: Play/Pause media key.

MediaPrevious MediaPrevious 88

Key code constant: Play Previous media key.

MediaRecord MediaRecord 130

Key code constant: Record media key.

MediaRewind MediaRewind 89

Key code constant: Rewind media key.

MediaSkipBackward MediaSkipBackward 273
MediaSkipForward MediaSkipForward 272
MediaStepBackward MediaStepBackward 275
MediaStepForward MediaStepForward 274
MediaStop MediaStop 86

Key code constant: Stop media key.

MediaTopMenu MediaTopMenu 226
Menu Menu 82

Key code constant: Menu key.

MetaLeft MetaLeft 117

Key code constant: Left Meta modifier key.

MetaRight MetaRight 118

Key code constant: Right Meta modifier key.

Minus Minus 69

Key code constant: '-'.

MoveEnd MoveEnd 123

Key code constant: End Movement key. Used for scrolling or moving the cursor around to the end of a line or to the bottom of a list.

MoveHome MoveHome 122

Key code constant: Home Movement key. Used for scrolling or moving the cursor around to the start of a line or to the top of a list.

Muhenkan Muhenkan 213

Key code constant: Japanese non-conversion key.

Music Music 209

Key code constant: Music special function key. Used to launch a music player application.

Mute Mute 91

Key code constant: Mute key. Mutes the microphone, unlike VolumeMute.

N N 42

Key code constant: 'N' key.

NavigateIn NavigateIn 262
NavigateNext NavigateNext 261
NavigateOut NavigateOut 263
NavigatePrevious NavigatePrevious 260
Notification Notification 83

Key code constant: Notification key.

Num Num 78
Num0 Num0 7

Key code constant: '0' key.

Num1 Num1 8

Key code constant: '1' key.

Num2 Num2 9

Key code constant: '2' key.

Num3 Num3 10

Key code constant: '3' key.

Num4 Num4 11

Key code constant: '4' key.

Num5 Num5 12

Key code constant: '5' key.

Num6 Num6 13

Key code constant: '6' key.

Num7 Num7 14

Key code constant: '7' key.

Num8 Num8 15

Key code constant: '8' key.

Num9 Num9 16

Key code constant: '9' key.

NumLock NumLock 143

Key code constant: Num Lock key. This is the Num Lock key; it is different from Num. This key alters the behavior of other keys on the numeric keypad.

Numpad0 Numpad0 144

Key code constant: Numeric keypad '0' key.

Numpad1 Numpad1 145

Key code constant: Numeric keypad '1' key.

Numpad2 Numpad2 146

Key code constant: Numeric keypad '2' key.

Numpad3 Numpad3 147

Key code constant: Numeric keypad '3' key.

Numpad4 Numpad4 148

Key code constant: Numeric keypad '4' key.

Numpad5 Numpad5 149

Key code constant: Numeric keypad '5' key.

Numpad6 Numpad6 150

Key code constant: Numeric keypad '6' key.

Numpad7 Numpad7 151

Key code constant: Numeric keypad '7' key.

Numpad8 Numpad8 152

Key code constant: Numeric keypad '8' key.

Numpad9 Numpad9 153

Key code constant: Numeric keypad '9' key.

NumpadAdd NumpadAdd 157

Key code constant: Numeric keypad '+' key (for addition).

NumpadComma NumpadComma 159

Key code constant: Numeric keypad ',' key (for decimals or digit grouping).

NumpadDivide NumpadDivide 154

Key code constant: Numeric keypad '/' key (for division).

NumpadDot NumpadDot 158

Key code constant: Numeric keypad '.' key (for decimals or digit grouping).

NumpadEnter NumpadEnter 160

Key code constant: Numeric keypad Enter key.

NumpadEquals NumpadEquals 161

Key code constant: Numeric keypad '=' key.

NumpadLeftParen NumpadLeftParen 162

Key code constant: Numeric keypad '(' key.

NumpadMultiply NumpadMultiply 155

Key code constant: Numeric keypad '*' key (for multiplication).

NumpadRightParen NumpadRightParen 163

Key code constant: Numeric keypad ')' key.

NumpadSubtract NumpadSubtract 156

Key code constant: Numeric keypad '-' key (for subtraction).

O O 43

Key code constant: 'O' key.

P P 44

Key code constant: 'P' key.

PageDown PageDown 93

Key code constant: Page Down key.

PageUp PageUp 92

Key code constant: Page Up key.

Pairing Pairing 225
Paste Paste 279
Period Period 56

Key code constant: '.' key.

Pictsymbols Pictsymbols 94

Key code constant: Picture Symbols modifier key. Used to switch symbol sets (Emoji, Kao-moji).

Plus Plus 81

Key code constant: '+' key.

Pound Pound 18

Key code constant: '#' key.

Power Power 26

Key code constant: Power key.

ProgBlue ProgBlue 186

Key code constant: Blue "programmable" key. On TV remotes, acts as a contextual/programmable key.

ProgGreen ProgGreen 184

Key code constant: Green "programmable" key. On TV remotes, actsas a contextual/programmable key.

ProgRed ProgRed 183

Key code constant: Red "programmable" key. On TV remotes, acts as a contextual/programmable key.

ProgYellow ProgYellow 185

Key code constant: Yellow "programmable" key. On TV remotes, acts as a contextual/programmable key.

Q Q 45

Key code constant: 'Q' key.

R R 46

Key code constant: 'R' key.

RightBracket RightBracket 72

Key code constant: ']' key.

Ro Ro 217

Key code constant: Japanese Ro key.

S S 47

Key code constant: 'S' key.

ScrollLock ScrollLock 116

Key code constant: Scroll Lock key.

84

Key code constant: Search key.

Semicolon Semicolon 74

Key code constant: ';' key.

Settings Settings 176

Key code constant: Settings key. Starts the system settings activity.

ShiftLeft ShiftLeft 59

Key code constant: Left Shift modifier key.

ShiftRight ShiftRight 60

Key code constant: Right Shift modifier key.

Slash Slash 76

Key code constant: '/' key.

Sleep Sleep 223
SoftLeft SoftLeft 1
SoftRight SoftRight 2
SoftSleep SoftSleep 276
Space Space 62

Key code constant: Space key.

Star Star 17

Key code constant: '*' key.

StbInput StbInput 180

Key code constant: Set-top-box input key. On TV remotes, switches the input mode on an external Set-top-box.

StbPower StbPower 179

Key code constant: Set-top-box power key. On TV remotes, toggles the power on an external Set-top-box.

Stem1 Stem1 265
Stem2 Stem2 266
Stem3 Stem3 267
StemPrimary StemPrimary 264
SwitchCharset SwitchCharset 95

Key code constant: Switch Charset modifier key. Used to switch character sets (Kanji, Katakana).

Sym Sym 63

Key code constant: Symbol modifier key. Used to enter alternate symbols.

Sysrq Sysrq 120

Key code constant: System Request / Print Screen key.

SystemNavigationDown SystemNavigationDown 281
SystemNavigationLeft SystemNavigationLeft 282
SystemNavigationRight SystemNavigationRight 283
SystemNavigationUp SystemNavigationUp 280
T T 48

Key code constant: 'T' key.

Tab Tab 61

Key code constant: Tab key.

ThreeDMode ThreeDMode 206

Key code constant: 3D Mode key. Toggles the display between 2D and 3D mode.

Tv Tv 170

Key code constant: TV key. On TV remotes, switches to viewing live TV.

TvAntennaCable TvAntennaCable 242
TvAudioDescription TvAudioDescription 252
TvAudioDescriptionMixDown TvAudioDescriptionMixDown 254
TvAudioDescriptionMixUp TvAudioDescriptionMixUp 253
TvContentsMenu TvContentsMenu 256
TvDataService TvDataService 230
TvInput TvInput 178

Key code constant: TV input key. On TV remotes, switches the input on a television screen.

TvInputComponent1 TvInputComponent1 249
TvInputComponent2 TvInputComponent2 250
TvInputComposite1 TvInputComposite1 247
TvInputComposite2 TvInputComposite2 248
TvInputHdmi1 TvInputHdmi1 243
TvInputHdmi2 TvInputHdmi2 244
TvInputHdmi3 TvInputHdmi3 245
TvInputHdmi4 TvInputHdmi4 246
TvInputVga1 TvInputVga1 251
TvMediaContextMenu TvMediaContextMenu 257
TvNetwork TvNetwork 241
TvNumberEntry TvNumberEntry 234
TvPower TvPower 177

Key code constant: TV power key. On TV remotes, toggles the power on a television screen.

TvRadioService TvRadioService 232
TvSatellite TvSatellite 237
TvSatelliteBs TvSatelliteBs 238
TvSatelliteCs TvSatelliteCs 239
TvSatelliteService TvSatelliteService 240
TvTeletext TvTeletext 233
TvTerrestrialAnalog TvTerrestrialAnalog 235
TvTerrestrialDigital TvTerrestrialDigital 236
TvTimerProgramming TvTimerProgramming 258
TvZoomMode TvZoomMode 255
U U 49

Key code constant: 'U' key.

Unknown Unknown 0

Key code constant: Unknown key code.

V V 50

Key code constant: 'V' key.

VoiceAssist VoiceAssist 231
VolumeDown VolumeDown 25

Key code constant: Volume Down key. Adjusts the speaker volume down.

VolumeMute VolumeMute 164
VolumeUp VolumeUp 24

Key code constant: Volume Up key. Adjusts the speaker volume up.

W W 51

Key code constant: 'W' key.

Wakeup Wakeup 224
Window Window 171

Key code constant: Window key. On TV remotes, toggles picture-in-picture mode or other windowing functions.

X X 52

Key code constant: 'X' key.

Y Y 53

Key code constant: 'Y' key.

Yen Yen 216

Key code constant: Japanese Yen key.

Z Z 54

Key code constant: 'Z' key.

ZenkakuHankaku ZenkakuHankaku 211

Key code constant: Japanese full-width / half-width key.

ZoomIn ZoomIn 168

Key code constant: Zoom in key.

ZoomOut ZoomOut 169

Key code constant: Zoom out key.

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to