docs.unity3d.com
    Show / Hide Table of Contents

    Enum AndroidKeyCode

    Enum used to identity the key in the Android key event. See buttons. See https://developer.android.com/reference/android/view/KeyEvent#constants_1 for more details.

    Namespace: UnityEngine.InputSystem.Android.LowLevel
    Syntax
    public enum AndroidKeyCode

    Fields

    Name Description Value
    A

    'A' key.

    Alpha0

    '0' key.

    Alpha1

    '1' key.

    Alpha2

    '2' key.

    Alpha3

    '3' key.

    Alpha4

    '4' key.

    Alpha5

    '5' key.

    Alpha6

    '6' key.

    Alpha7

    '7' key.

    Alpha8

    '8' key.

    Alpha9

    '9' key.

    AltLeft

    Left Alt modifier key.

    AltRight

    Right Alt modifier key.

    Apostrophe

    ''' (apostrophe) key.

    AppSwitch

    App switch key. Should bring up the application switcher dialog.

    Assist

    Assist key. Launches the global assist activity. Not delivered to applications.

    At

    '@' key.

    AvrInput

    A/V Receiver input key. On TV remotes, switches the input mode on an external A/V Receive

    AvrPower

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

    B

    'B' key.

    Back

    Back key.

    Backslash

    '' key.

    Bookmark

    Bookmark key. On some TV remotes, bookmarks content or web pages.

    Break

    Break / Pause key.

    Button1

    Generic Game Pad Button #1.

    Button10

    Generic Game Pad Button #10.

    Button11

    Generic Game Pad Button #11.

    Button12

    Generic Game Pad Button #12.

    Button13

    Generic Game Pad Button #13.

    Button14

    Generic Game Pad Button #14.

    Button15

    Generic Game Pad Button #15.

    Button16

    Generic Game Pad Button #16.

    Button2

    Generic Game Pad Button #2.

    Button3

    Generic Game Pad Button #3.

    Button4

    Generic Game Pad Button #4.

    Button5

    Generic Game Pad Button #5.

    Button6

    Generic Game Pad Button #6.

    Button7

    Generic Game Pad Button #7.

    Button8

    Generic Game Pad Button #8.

    Button9

    Generic Game Pad Button #9.

    ButtonA

    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

    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

    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

    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

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

    ButtonMode

    Mode Button key. On a game controller, the button labeled Mode.

    ButtonR1

    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

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

    ButtonSelect

    Select Button key. On a game controller, the button labeled Select.

    ButtonStart

    Start Button key. On a game controller, the button labeled Start.

    ButtonThumbl

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

    ButtonThumbr

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

    ButtonX

    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

    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

    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' key.

    Calculator

    Calculator special function key. Used to launch a calculator application.

    Calendar

    Calendar special function key. Used to launch a calendar application.

    Call

    Call key.

    Camera

    Camera key. Used to launch a camera application or take pictures.

    CapsLock

    Caps Lock key.

    Captions

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

    ChannelDown

    Channel down key. On TV remotes, increments the television channel.

    ChannelUp

    Channel up key. On TV remotes, increments the television channel.

    Clear

    Clear key.

    Comma

    ',' key.

    Contacts

    Contacts special function key. Used to launch an address book application.

    CtrlLeft

    Left Control modifier key.

    CtrlRight

    Right Control modifier key.

    D

    'D' key.

    Del

    Backspace key. Deletes characters before the insertion point, unlike ForwardDel.

    DpadCenter

    Directional Pad Center key. May also be synthesized from trackball motions.

    DpadDown

    Directional Pad Down key. May also be synthesized from trackball motions.

    DpadLeft

    Directional Pad Left key. May also be synthesized from trackball motions.

    DpadRight

    Directional Pad Right key. May also be synthesized from trackball motions.

    DpadUp

    Directional Pad Up key. May also be synthesized from trackball motions.

    Dvr

    DVR key. On some TV remotes, switches to a DVR mode for recorded shows.

    E

    'E' key.

    Eisu

    Japanese alphanumeric key.

    Endcall

    End Call key.

    Enter

    Enter key.

    Envelope

    Envelope special function key. Used to launch a mail application.

    Equals

    '=' key.

    Escape

    Escape key.

    Explorer

    Explorer special function key. Used to launch a browser application.

    F

    'F' key.

    F1

    F1 key.

    F10

    F10 key.

    F11

    F11 key.

    F12

    F12 key.

    F2

    F2 key.

    F3

    F3 key.

    F4

    F4 key.

    F5

    F5 key.

    F6

    F6 key.

    F7

    F7 key.

    F8

    F8 key.

    F9

    F9 key.

    Focus

    Camera Focus key. Used to focus the camera.

    Forward

    Forward key. Navigates forward in the history stack. Complement of Back.

    ForwardDel

    Forward Delete key. Deletes characters ahead of the insertion point, unlike Del.

    Function

    Function modifier key.

    G

    'G' key.

    Grave

    '`' (backtick) key.

    Guide

    Guide key. On TV remotes, shows a programming guide.

    H

    'H' key.

    Headsethook

    Headset Hook key. Used to hang up calls and stop media.

    Henkan

    Japanese conversion key.

    Home

    Home key. This key is handled by the framework and is never delivered to applications.

    I

    'I' key.

    Info

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

    Insert

    Insert key. Toggles insert / overwrite edit mode.

    J

    'J' key.

    K

    'K' key.

    Kana

    Japanese kana key.

    KatakanaHiragana

    Japanese katakana / hiragana key.

    L

    'L' key.

    LanguageSwitch

    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.

    LeftBracket

    '[' key.

    M

    'M' key.

    MannerMode

    '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.

    MediaClose

    Close media key. May be used to close a CD tray, for example.

    MediaEject

    Eject media key. May be used to eject a CD tray, for example.

    MediaFastForward

    Fast Forward media key.

    MediaNext

    Play Next media key.

    MediaPause

    Play/Pause media key.

    MediaPlay

    Play media key.

    MediaPlayPause

    Play/Pause media key.

    MediaPrevious

    Play Previous media key.

    MediaRecord

    Record media key.

    MediaRewind

    Rewind media key.

    MediaStop

    Stop media key.

    Menu

    Menu key.

    MetaLeft

    Left Meta modifier key.

    MetaRight

    Right Meta modifier key.

    Minus

    '-' key.

    Mode3D

    3D Mode key. Toggles the display between 2D and 3D mode.

    MoveEnd

    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

    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

    Japanese non-conversion key.

    Music

    Music special function key. Used to launch a music player application.

    Mute

    Mute key. Mutes the microphone, unlike VolumeMute.

    N

    'N' key.

    Notification

    Notification key.

    Num

    Number modifier key. Used to enter numeric symbols. This key is not Num Lock; it is more like AltLeft.

    NumLock

    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

    Numeric keypad '0' key.

    Numpad1

    Numeric keypad '1' key.

    Numpad2

    Numeric keypad '2' key.

    Numpad3

    Numeric keypad '3' key.

    Numpad4

    Numeric keypad '4' key.

    Numpad5

    Numeric keypad '5' key.

    Numpad6

    'Numeric keypad '6' key.

    Numpad7

    'Numeric keypad '7' key.

    Numpad8

    Numeric keypad '8' key.

    Numpad9

    Numeric keypad '9' key.

    NumpadAdd

    Numeric keypad '+' key (for addition).

    NumpadComma

    Numeric keypad ',' key (for decimals or digit grouping).

    NumpadDivide

    Numeric keypad '/' key (for division).

    NumpadDot

    Numeric keypad '.' key (for decimals or digit grouping).

    NumpadEnter

    Numeric keypad Enter key.

    NumpadEquals

    Numeric keypad '=' key.

    NumpadLeftParen

    Numeric keypad '(' key.

    NumpadMultiply

    Numeric keypad '*' key (for multiplication).

    NumpadRightParen

    Numeric keypad ')' key.

    NumpadSubtract

    Numeric keypad '-' key (for subtraction).

    O

    'O' key.

    P

    'P' key.

    PageDown

    Page Down key.

    PageUp

    Page Up key.

    Period

    '.' key.

    Pictsymbols

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

    Plus

    '+' key.

    Pound

    '#' key.

    Power

    Power key.

    ProgBlue

    Blue "programmable" key. On TV remotes, actsas a contextual/programmable key.

    ProgGreen

    Green "programmable" key. On TV remotes, actsas a contextual/programmable key.

    ProgRed

    Red "programmable" key. On TV remotes, acts as a contextual/programmable key.

    ProgYellow

    Yellow "programmable" key. On TV remotes, actsas a contextual/programmable key.

    Q

    'Q' key.

    R

    'R' key.

    RightBracket

    ']' key.

    Ro

    Japanese Ro key.

    S

    'S' key.

    ScrollLock

    Scroll Lock key.

    Search

    Search key.

    Semicolon

    ';' key.

    Settings

    Settings key. Starts the system settings activity.

    ShiftLeft

    Left Shift modifier key.

    ShiftRight

    Right Shift modifier key.

    Slash

    '/' key.

    SoftLeft

    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.

    SoftRight

    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.

    Space

    Space key.

    Star

    '*' key.

    StbInput

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

    StbPower

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

    SwitchCharset

    Switch Charset modifier key. Used to switch character sets (Kanji, Katakana).

    Sym

    Symbol modifier key. Used to enter alternate symbols.

    Sysrq

    System Request / Print Screen key.

    T

    'T' key.

    Tab

    Tab key.

    Tv

    TV key. On TV remotes, switches to viewing live TV.

    TvInput

    TV input key. On TV remotes, switches the input on a television screen.

    TvPower

    TV power key. On HDMI TV panel devices and Android TV devices that don't support HDMI, toggles the power state of the device. On HDMI source devices, toggles the power state of the HDMI-connected TV via HDMI-CEC and makes the source device follow this power state.

    U

    'U' key.

    Unknown

    Unknown key code.

    V

    'V' key.

    VolumeDown

    Volume Down key. Adjusts the speaker volume down.

    VolumeMute

    Volume Mute key. Mutes the speaker, unlike 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 volum

    VolumeUp

    Volume Up key. Adjusts the speaker volume up.

    W

    'W' key.

    Window

    Window key. On TV remotes, toggles picture-in-picture mode or other windowing functions. On Android Wear devices, triggers a display offset.

    X

    'X' key.

    Y

    'Y' key.

    Yen

    Japanese Yen key.

    Z

    'Z' key.

    ZenkakuHankaku

    Japanese full-width / half-width key.

    ZoomIn

    Zoom in key.

    ZoomOut

    Zoom out key.

    In This Article
    • Fields
    Back to top
    Terms of use
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023