Loading core/api/current.txt +21 −2 Original line number Diff line number Diff line Loading @@ -52003,6 +52003,7 @@ package android.view { field public static final int KEYCODE_CHANNEL_DOWN = 167; // 0xa7 field public static final int KEYCODE_CHANNEL_UP = 166; // 0xa6 field public static final int KEYCODE_CLEAR = 28; // 0x1c field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_CLOSE = 321; // 0x141 field public static final int KEYCODE_COMMA = 55; // 0x37 field public static final int KEYCODE_CONTACTS = 207; // 0xcf field public static final int KEYCODE_COPY = 278; // 0x116 Loading @@ -52015,6 +52016,8 @@ package android.view { field public static final int KEYCODE_DEMO_APP_2 = 302; // 0x12e field public static final int KEYCODE_DEMO_APP_3 = 303; // 0x12f field public static final int KEYCODE_DEMO_APP_4 = 304; // 0x130 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_DICTATE = 319; // 0x13f field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_DO_NOT_DISTURB = 322; // 0x142 field public static final int KEYCODE_DPAD_CENTER = 23; // 0x17 field public static final int KEYCODE_DPAD_DOWN = 20; // 0x14 field public static final int KEYCODE_DPAD_DOWN_LEFT = 269; // 0x10d Loading @@ -52027,7 +52030,7 @@ package android.view { field public static final int KEYCODE_DVR = 173; // 0xad field public static final int KEYCODE_E = 33; // 0x21 field public static final int KEYCODE_EISU = 212; // 0xd4 field @FlaggedApi("com.android.hardware.input.emoji_and_screenshot_keycodes_available") public static final int KEYCODE_EMOJI_PICKER = 317; // 0x13d field public static final int KEYCODE_EMOJI_PICKER = 317; // 0x13d field public static final int KEYCODE_ENDCALL = 6; // 0x6 field public static final int KEYCODE_ENTER = 66; // 0x42 field public static final int KEYCODE_ENVELOPE = 65; // 0x41 Loading @@ -52039,7 +52042,19 @@ package android.view { field public static final int KEYCODE_F10 = 140; // 0x8c field public static final int KEYCODE_F11 = 141; // 0x8d field public static final int KEYCODE_F12 = 142; // 0x8e field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F13 = 326; // 0x146 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F14 = 327; // 0x147 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F15 = 328; // 0x148 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F16 = 329; // 0x149 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F17 = 330; // 0x14a field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F18 = 331; // 0x14b field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F19 = 332; // 0x14c field public static final int KEYCODE_F2 = 132; // 0x84 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F20 = 333; // 0x14d field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F21 = 334; // 0x14e field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F22 = 335; // 0x14f field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F23 = 336; // 0x150 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F24 = 337; // 0x151 field public static final int KEYCODE_F3 = 133; // 0x85 field public static final int KEYCODE_F4 = 134; // 0x86 field public static final int KEYCODE_F5 = 135; // 0x87 Loading @@ -52054,6 +52069,7 @@ package android.view { field public static final int KEYCODE_FOCUS = 80; // 0x50 field public static final int KEYCODE_FORWARD = 125; // 0x7d field public static final int KEYCODE_FORWARD_DEL = 112; // 0x70 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_FULLSCREEN = 325; // 0x145 field public static final int KEYCODE_FUNCTION = 119; // 0x77 field public static final int KEYCODE_G = 35; // 0x23 field public static final int KEYCODE_GRAVE = 68; // 0x44 Loading @@ -52077,6 +52093,7 @@ package android.view { field public static final int KEYCODE_LANGUAGE_SWITCH = 204; // 0xcc field public static final int KEYCODE_LAST_CHANNEL = 229; // 0xe5 field public static final int KEYCODE_LEFT_BRACKET = 71; // 0x47 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_LOCK = 324; // 0x144 field public static final int KEYCODE_M = 41; // 0x29 field public static final int KEYCODE_MACRO_1 = 313; // 0x139 field public static final int KEYCODE_MACRO_2 = 314; // 0x13a Loading Loading @@ -52114,6 +52131,7 @@ package android.view { field public static final int KEYCODE_NAVIGATE_NEXT = 261; // 0x105 field public static final int KEYCODE_NAVIGATE_OUT = 263; // 0x107 field public static final int KEYCODE_NAVIGATE_PREVIOUS = 260; // 0x104 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_NEW = 320; // 0x140 field public static final int KEYCODE_NOTIFICATION = 83; // 0x53 field public static final int KEYCODE_NUM = 78; // 0x4e field public static final int KEYCODE_NUMPAD_0 = 144; // 0x90 Loading Loading @@ -52148,6 +52166,7 @@ package android.view { field public static final int KEYCODE_PLUS = 81; // 0x51 field public static final int KEYCODE_POUND = 18; // 0x12 field public static final int KEYCODE_POWER = 26; // 0x1a field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_PRINT = 323; // 0x143 field public static final int KEYCODE_PROFILE_SWITCH = 288; // 0x120 field public static final int KEYCODE_PROG_BLUE = 186; // 0xba field public static final int KEYCODE_PROG_GREEN = 184; // 0xb8 Loading @@ -52160,7 +52179,7 @@ package android.view { field public static final int KEYCODE_RIGHT_BRACKET = 72; // 0x48 field public static final int KEYCODE_RO = 217; // 0xd9 field public static final int KEYCODE_S = 47; // 0x2f field @FlaggedApi("com.android.hardware.input.emoji_and_screenshot_keycodes_available") public static final int KEYCODE_SCREENSHOT = 318; // 0x13e field public static final int KEYCODE_SCREENSHOT = 318; // 0x13e field public static final int KEYCODE_SCROLL_LOCK = 116; // 0x74 field public static final int KEYCODE_SEARCH = 84; // 0x54 field public static final int KEYCODE_SEMICOLON = 74; // 0x4a core/api/test-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -3729,7 +3729,7 @@ package android.view { method public final int getDisplayId(); method public final void setDisplayId(int); field public static final int FLAG_IS_ACCESSIBILITY_EVENT = 2048; // 0x800 field public static final int LAST_KEYCODE = 318; // 0x13e field public static final int LAST_KEYCODE = 337; // 0x151 } public final class KeyboardShortcutGroup implements android.os.Parcelable { Loading core/java/android/hardware/input/input_framework.aconfig +7 −8 Original line number Diff line number Diff line Loading @@ -28,14 +28,6 @@ flag { bug: "294546335" } flag { namespace: "input_native" name: "emoji_and_screenshot_keycodes_available" is_exported: true description: "Add new KeyEvent keycodes for opening Emoji Picker and Taking Screenshots" bug: "315307777" } flag { namespace: "input_native" name: "keyboard_a11y_slow_keys_flag" Loading Loading @@ -152,6 +144,13 @@ flag { bug: "365064144" } flag { name: "enable_new_25q2_keycodes" namespace: "input" description: "Enables new 25Q2 keycodes" bug: "365920375" } flag { name: "override_power_key_behavior_in_focused_window" namespace: "input_native" Loading core/java/android/view/KeyEvent.java +86 −3 Original line number Diff line number Diff line Loading @@ -935,7 +935,6 @@ public class KeyEvent extends InputEvent implements Parcelable { */ public static final int KEYCODE_MACRO_4 = 316; /** Key code constant: To open emoji picker */ @FlaggedApi(Flags.FLAG_EMOJI_AND_SCREENSHOT_KEYCODES_AVAILABLE) public static final int KEYCODE_EMOJI_PICKER = 317; /** * Key code constant: To take a screenshot Loading @@ -944,15 +943,80 @@ public class KeyEvent extends InputEvent implements Parcelable { * unlike {@code KEYCODE_SYSRQ} which is sent to the app first and only if the app * doesn't handle it, the framework handles it (to take a screenshot). */ @FlaggedApi(Flags.FLAG_EMOJI_AND_SCREENSHOT_KEYCODES_AVAILABLE) public static final int KEYCODE_SCREENSHOT = 318; /** Key code constant: To start dictate to an input field */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_DICTATE = 319; /** * Key code constant: AC New * * e.g. To create a new instance of a window, open a new tab, etc. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_NEW = 320; /** * Key code constant: AC Close * * e.g. To close current instance of the application window, close the current tab, etc. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_CLOSE = 321; /** Key code constant: To toggle 'Do Not Disturb' mode */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_DO_NOT_DISTURB = 322; /** Key code constant: To Print */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_PRINT = 323; /** Key code constant: To Lock the screen */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_LOCK = 324; /** Key code constant: To toggle fullscreen mode (on the current application) */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_FULLSCREEN = 325; /** Key code constant: F13 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F13 = 326; /** Key code constant: F14 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F14 = 327; /** Key code constant: F15 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F15 = 328; /** Key code constant: F16 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F16 = 329; /** Key code constant: F17 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F17 = 330; /** Key code constant: F18 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F18 = 331; /** Key code constant: F19 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F19 = 332; /** Key code constant: F20 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F20 = 333; /** Key code constant: F21 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F21 = 334; /** Key code constant: F22 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F22 = 335; /** Key code constant: F23 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F23 = 336; /** Key code constant: F24 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F24 = 337; /** * Integer value of the last KEYCODE. Increases as new keycodes are added to KeyEvent. * @hide */ @TestApi public static final int LAST_KEYCODE = KEYCODE_SCREENSHOT; @SuppressWarnings("FlaggedApi") public static final int LAST_KEYCODE = KEYCODE_F24; /** @hide */ @IntDef(prefix = {"KEYCODE_"}, value = { Loading Loading @@ -1275,6 +1339,25 @@ public class KeyEvent extends InputEvent implements Parcelable { KEYCODE_MACRO_4, KEYCODE_EMOJI_PICKER, KEYCODE_SCREENSHOT, KEYCODE_DICTATE, KEYCODE_NEW, KEYCODE_CLOSE, KEYCODE_DO_NOT_DISTURB, KEYCODE_PRINT, KEYCODE_LOCK, KEYCODE_FULLSCREEN, KEYCODE_F13, KEYCODE_F14, KEYCODE_F15, KEYCODE_F16, KEYCODE_F17, KEYCODE_F18, KEYCODE_F19, KEYCODE_F20, KEYCODE_F21, KEYCODE_F22, KEYCODE_F23, KEYCODE_F24, }) @Retention(RetentionPolicy.SOURCE) @interface KeyCode {} Loading data/keyboards/Generic.kl +25 −17 Original line number Diff line number Diff line Loading @@ -171,7 +171,7 @@ key 143 WAKEUP # key 149 "KEY_PROG2" key 150 EXPLORER # key 151 "KEY_MSDOS" key 152 POWER key 152 LOCK # key 153 "KEY_DIRECTION" # key 154 "KEY_CYCLEWINDOWS" key 155 ENVELOPE Loading Loading @@ -200,20 +200,20 @@ key 177 PAGE_UP key 178 PAGE_DOWN key 179 NUMPAD_LEFT_PAREN key 180 NUMPAD_RIGHT_PAREN # key 181 "KEY_NEW" key 181 NEW # key 182 "KEY_REDO" # key 183 F13 # key 184 F14 # key 185 F15 # key 186 F16 # key 187 F17 # key 188 F18 # key 189 F19 # key 190 F20 # key 191 F21 # key 192 F22 # key 193 F23 # key 194 F24 key 183 F13 key 184 F14 key 185 F15 key 186 F16 key 187 F17 key 188 F18 key 189 F19 key 190 F20 key 191 F21 key 192 F22 key 193 F23 key 194 F24 # key 195 (undefined) # key 196 (undefined) # key 197 (undefined) Loading @@ -225,11 +225,11 @@ key 201 MEDIA_PAUSE # key 203 "KEY_PROG4" key 204 NOTIFICATION # key 205 "KEY_SUSPEND" # key 206 "KEY_CLOSE" key 206 CLOSE key 207 MEDIA_PLAY key 208 MEDIA_FAST_FORWARD # key 209 "KEY_BASSBOOST" # key 210 "KEY_PRINT" key 210 PRINT # key 211 "KEY_HP" key 212 CAMERA key 213 MUSIC Loading Loading @@ -328,7 +328,7 @@ key 368 LANGUAGE_SWITCH # key 369 "KEY_TITLE" key 370 CAPTIONS # key 371 "KEY_ANGLE" # key 372 "KEY_ZOOM" key 372 FULLSCREEN # key 373 "KEY_MODE" # key 374 "KEY_KEYBOARD" # key 375 "KEY_SCREEN" Loading Loading @@ -425,12 +425,15 @@ key 582 VOICE_ASSIST # Linux KEY_ASSISTANT key 583 ASSIST key 585 EMOJI_PICKER key 586 DICTATE key 656 MACRO_1 key 657 MACRO_2 key 658 MACRO_3 key 659 MACRO_4 # Keys defined by HID usages key usage 0x010082 LOCK FALLBACK_USAGE_MAPPING key usage 0x01009B DO_NOT_DISTURB FALLBACK_USAGE_MAPPING key usage 0x0c0065 SCREENSHOT FALLBACK_USAGE_MAPPING key usage 0x0c0067 WINDOW FALLBACK_USAGE_MAPPING key usage 0x0c006F BRIGHTNESS_UP FALLBACK_USAGE_MAPPING Loading @@ -438,12 +441,17 @@ key usage 0x0c0070 BRIGHTNESS_DOWN FALLBACK_USAGE_MAPPING key usage 0x0c0079 KEYBOARD_BACKLIGHT_UP FALLBACK_USAGE_MAPPING key usage 0x0c007A KEYBOARD_BACKLIGHT_DOWN FALLBACK_USAGE_MAPPING key usage 0x0c007C KEYBOARD_BACKLIGHT_TOGGLE FALLBACK_USAGE_MAPPING key usage 0x0c00D8 DICTATE FALLBACK_USAGE_MAPPING key usage 0x0c00D9 EMOJI_PICKER FALLBACK_USAGE_MAPPING key usage 0x0c0173 MEDIA_AUDIO_TRACK FALLBACK_USAGE_MAPPING key usage 0x0c019C PROFILE_SWITCH FALLBACK_USAGE_MAPPING key usage 0x0c019F SETTINGS FALLBACK_USAGE_MAPPING key usage 0x0c01A2 ALL_APPS FALLBACK_USAGE_MAPPING key usage 0x0c0201 NEW FALLBACK_USAGE_MAPPING key usage 0x0c0203 CLOSE FALLBACK_USAGE_MAPPING key usage 0x0c0208 PRINT FALLBACK_USAGE_MAPPING key usage 0x0c0227 REFRESH FALLBACK_USAGE_MAPPING key usage 0x0c0232 FULLSCREEN FALLBACK_USAGE_MAPPING key usage 0x0c029D LANGUAGE_SWITCH FALLBACK_USAGE_MAPPING key usage 0x0c029F RECENT_APPS FALLBACK_USAGE_MAPPING key usage 0x0c02A2 ALL_APPS FALLBACK_USAGE_MAPPING Loading Loading
core/api/current.txt +21 −2 Original line number Diff line number Diff line Loading @@ -52003,6 +52003,7 @@ package android.view { field public static final int KEYCODE_CHANNEL_DOWN = 167; // 0xa7 field public static final int KEYCODE_CHANNEL_UP = 166; // 0xa6 field public static final int KEYCODE_CLEAR = 28; // 0x1c field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_CLOSE = 321; // 0x141 field public static final int KEYCODE_COMMA = 55; // 0x37 field public static final int KEYCODE_CONTACTS = 207; // 0xcf field public static final int KEYCODE_COPY = 278; // 0x116 Loading @@ -52015,6 +52016,8 @@ package android.view { field public static final int KEYCODE_DEMO_APP_2 = 302; // 0x12e field public static final int KEYCODE_DEMO_APP_3 = 303; // 0x12f field public static final int KEYCODE_DEMO_APP_4 = 304; // 0x130 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_DICTATE = 319; // 0x13f field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_DO_NOT_DISTURB = 322; // 0x142 field public static final int KEYCODE_DPAD_CENTER = 23; // 0x17 field public static final int KEYCODE_DPAD_DOWN = 20; // 0x14 field public static final int KEYCODE_DPAD_DOWN_LEFT = 269; // 0x10d Loading @@ -52027,7 +52030,7 @@ package android.view { field public static final int KEYCODE_DVR = 173; // 0xad field public static final int KEYCODE_E = 33; // 0x21 field public static final int KEYCODE_EISU = 212; // 0xd4 field @FlaggedApi("com.android.hardware.input.emoji_and_screenshot_keycodes_available") public static final int KEYCODE_EMOJI_PICKER = 317; // 0x13d field public static final int KEYCODE_EMOJI_PICKER = 317; // 0x13d field public static final int KEYCODE_ENDCALL = 6; // 0x6 field public static final int KEYCODE_ENTER = 66; // 0x42 field public static final int KEYCODE_ENVELOPE = 65; // 0x41 Loading @@ -52039,7 +52042,19 @@ package android.view { field public static final int KEYCODE_F10 = 140; // 0x8c field public static final int KEYCODE_F11 = 141; // 0x8d field public static final int KEYCODE_F12 = 142; // 0x8e field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F13 = 326; // 0x146 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F14 = 327; // 0x147 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F15 = 328; // 0x148 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F16 = 329; // 0x149 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F17 = 330; // 0x14a field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F18 = 331; // 0x14b field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F19 = 332; // 0x14c field public static final int KEYCODE_F2 = 132; // 0x84 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F20 = 333; // 0x14d field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F21 = 334; // 0x14e field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F22 = 335; // 0x14f field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F23 = 336; // 0x150 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_F24 = 337; // 0x151 field public static final int KEYCODE_F3 = 133; // 0x85 field public static final int KEYCODE_F4 = 134; // 0x86 field public static final int KEYCODE_F5 = 135; // 0x87 Loading @@ -52054,6 +52069,7 @@ package android.view { field public static final int KEYCODE_FOCUS = 80; // 0x50 field public static final int KEYCODE_FORWARD = 125; // 0x7d field public static final int KEYCODE_FORWARD_DEL = 112; // 0x70 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_FULLSCREEN = 325; // 0x145 field public static final int KEYCODE_FUNCTION = 119; // 0x77 field public static final int KEYCODE_G = 35; // 0x23 field public static final int KEYCODE_GRAVE = 68; // 0x44 Loading @@ -52077,6 +52093,7 @@ package android.view { field public static final int KEYCODE_LANGUAGE_SWITCH = 204; // 0xcc field public static final int KEYCODE_LAST_CHANNEL = 229; // 0xe5 field public static final int KEYCODE_LEFT_BRACKET = 71; // 0x47 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_LOCK = 324; // 0x144 field public static final int KEYCODE_M = 41; // 0x29 field public static final int KEYCODE_MACRO_1 = 313; // 0x139 field public static final int KEYCODE_MACRO_2 = 314; // 0x13a Loading Loading @@ -52114,6 +52131,7 @@ package android.view { field public static final int KEYCODE_NAVIGATE_NEXT = 261; // 0x105 field public static final int KEYCODE_NAVIGATE_OUT = 263; // 0x107 field public static final int KEYCODE_NAVIGATE_PREVIOUS = 260; // 0x104 field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_NEW = 320; // 0x140 field public static final int KEYCODE_NOTIFICATION = 83; // 0x53 field public static final int KEYCODE_NUM = 78; // 0x4e field public static final int KEYCODE_NUMPAD_0 = 144; // 0x90 Loading Loading @@ -52148,6 +52166,7 @@ package android.view { field public static final int KEYCODE_PLUS = 81; // 0x51 field public static final int KEYCODE_POUND = 18; // 0x12 field public static final int KEYCODE_POWER = 26; // 0x1a field @FlaggedApi("com.android.hardware.input.enable_new_25q2_keycodes") public static final int KEYCODE_PRINT = 323; // 0x143 field public static final int KEYCODE_PROFILE_SWITCH = 288; // 0x120 field public static final int KEYCODE_PROG_BLUE = 186; // 0xba field public static final int KEYCODE_PROG_GREEN = 184; // 0xb8 Loading @@ -52160,7 +52179,7 @@ package android.view { field public static final int KEYCODE_RIGHT_BRACKET = 72; // 0x48 field public static final int KEYCODE_RO = 217; // 0xd9 field public static final int KEYCODE_S = 47; // 0x2f field @FlaggedApi("com.android.hardware.input.emoji_and_screenshot_keycodes_available") public static final int KEYCODE_SCREENSHOT = 318; // 0x13e field public static final int KEYCODE_SCREENSHOT = 318; // 0x13e field public static final int KEYCODE_SCROLL_LOCK = 116; // 0x74 field public static final int KEYCODE_SEARCH = 84; // 0x54 field public static final int KEYCODE_SEMICOLON = 74; // 0x4a
core/api/test-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -3729,7 +3729,7 @@ package android.view { method public final int getDisplayId(); method public final void setDisplayId(int); field public static final int FLAG_IS_ACCESSIBILITY_EVENT = 2048; // 0x800 field public static final int LAST_KEYCODE = 318; // 0x13e field public static final int LAST_KEYCODE = 337; // 0x151 } public final class KeyboardShortcutGroup implements android.os.Parcelable { Loading
core/java/android/hardware/input/input_framework.aconfig +7 −8 Original line number Diff line number Diff line Loading @@ -28,14 +28,6 @@ flag { bug: "294546335" } flag { namespace: "input_native" name: "emoji_and_screenshot_keycodes_available" is_exported: true description: "Add new KeyEvent keycodes for opening Emoji Picker and Taking Screenshots" bug: "315307777" } flag { namespace: "input_native" name: "keyboard_a11y_slow_keys_flag" Loading Loading @@ -152,6 +144,13 @@ flag { bug: "365064144" } flag { name: "enable_new_25q2_keycodes" namespace: "input" description: "Enables new 25Q2 keycodes" bug: "365920375" } flag { name: "override_power_key_behavior_in_focused_window" namespace: "input_native" Loading
core/java/android/view/KeyEvent.java +86 −3 Original line number Diff line number Diff line Loading @@ -935,7 +935,6 @@ public class KeyEvent extends InputEvent implements Parcelable { */ public static final int KEYCODE_MACRO_4 = 316; /** Key code constant: To open emoji picker */ @FlaggedApi(Flags.FLAG_EMOJI_AND_SCREENSHOT_KEYCODES_AVAILABLE) public static final int KEYCODE_EMOJI_PICKER = 317; /** * Key code constant: To take a screenshot Loading @@ -944,15 +943,80 @@ public class KeyEvent extends InputEvent implements Parcelable { * unlike {@code KEYCODE_SYSRQ} which is sent to the app first and only if the app * doesn't handle it, the framework handles it (to take a screenshot). */ @FlaggedApi(Flags.FLAG_EMOJI_AND_SCREENSHOT_KEYCODES_AVAILABLE) public static final int KEYCODE_SCREENSHOT = 318; /** Key code constant: To start dictate to an input field */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_DICTATE = 319; /** * Key code constant: AC New * * e.g. To create a new instance of a window, open a new tab, etc. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_NEW = 320; /** * Key code constant: AC Close * * e.g. To close current instance of the application window, close the current tab, etc. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_CLOSE = 321; /** Key code constant: To toggle 'Do Not Disturb' mode */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_DO_NOT_DISTURB = 322; /** Key code constant: To Print */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_PRINT = 323; /** Key code constant: To Lock the screen */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_LOCK = 324; /** Key code constant: To toggle fullscreen mode (on the current application) */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_FULLSCREEN = 325; /** Key code constant: F13 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F13 = 326; /** Key code constant: F14 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F14 = 327; /** Key code constant: F15 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F15 = 328; /** Key code constant: F16 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F16 = 329; /** Key code constant: F17 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F17 = 330; /** Key code constant: F18 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F18 = 331; /** Key code constant: F19 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F19 = 332; /** Key code constant: F20 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F20 = 333; /** Key code constant: F21 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F21 = 334; /** Key code constant: F22 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F22 = 335; /** Key code constant: F23 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F23 = 336; /** Key code constant: F24 key. */ @FlaggedApi(Flags.FLAG_ENABLE_NEW_25Q2_KEYCODES) public static final int KEYCODE_F24 = 337; /** * Integer value of the last KEYCODE. Increases as new keycodes are added to KeyEvent. * @hide */ @TestApi public static final int LAST_KEYCODE = KEYCODE_SCREENSHOT; @SuppressWarnings("FlaggedApi") public static final int LAST_KEYCODE = KEYCODE_F24; /** @hide */ @IntDef(prefix = {"KEYCODE_"}, value = { Loading Loading @@ -1275,6 +1339,25 @@ public class KeyEvent extends InputEvent implements Parcelable { KEYCODE_MACRO_4, KEYCODE_EMOJI_PICKER, KEYCODE_SCREENSHOT, KEYCODE_DICTATE, KEYCODE_NEW, KEYCODE_CLOSE, KEYCODE_DO_NOT_DISTURB, KEYCODE_PRINT, KEYCODE_LOCK, KEYCODE_FULLSCREEN, KEYCODE_F13, KEYCODE_F14, KEYCODE_F15, KEYCODE_F16, KEYCODE_F17, KEYCODE_F18, KEYCODE_F19, KEYCODE_F20, KEYCODE_F21, KEYCODE_F22, KEYCODE_F23, KEYCODE_F24, }) @Retention(RetentionPolicy.SOURCE) @interface KeyCode {} Loading
data/keyboards/Generic.kl +25 −17 Original line number Diff line number Diff line Loading @@ -171,7 +171,7 @@ key 143 WAKEUP # key 149 "KEY_PROG2" key 150 EXPLORER # key 151 "KEY_MSDOS" key 152 POWER key 152 LOCK # key 153 "KEY_DIRECTION" # key 154 "KEY_CYCLEWINDOWS" key 155 ENVELOPE Loading Loading @@ -200,20 +200,20 @@ key 177 PAGE_UP key 178 PAGE_DOWN key 179 NUMPAD_LEFT_PAREN key 180 NUMPAD_RIGHT_PAREN # key 181 "KEY_NEW" key 181 NEW # key 182 "KEY_REDO" # key 183 F13 # key 184 F14 # key 185 F15 # key 186 F16 # key 187 F17 # key 188 F18 # key 189 F19 # key 190 F20 # key 191 F21 # key 192 F22 # key 193 F23 # key 194 F24 key 183 F13 key 184 F14 key 185 F15 key 186 F16 key 187 F17 key 188 F18 key 189 F19 key 190 F20 key 191 F21 key 192 F22 key 193 F23 key 194 F24 # key 195 (undefined) # key 196 (undefined) # key 197 (undefined) Loading @@ -225,11 +225,11 @@ key 201 MEDIA_PAUSE # key 203 "KEY_PROG4" key 204 NOTIFICATION # key 205 "KEY_SUSPEND" # key 206 "KEY_CLOSE" key 206 CLOSE key 207 MEDIA_PLAY key 208 MEDIA_FAST_FORWARD # key 209 "KEY_BASSBOOST" # key 210 "KEY_PRINT" key 210 PRINT # key 211 "KEY_HP" key 212 CAMERA key 213 MUSIC Loading Loading @@ -328,7 +328,7 @@ key 368 LANGUAGE_SWITCH # key 369 "KEY_TITLE" key 370 CAPTIONS # key 371 "KEY_ANGLE" # key 372 "KEY_ZOOM" key 372 FULLSCREEN # key 373 "KEY_MODE" # key 374 "KEY_KEYBOARD" # key 375 "KEY_SCREEN" Loading Loading @@ -425,12 +425,15 @@ key 582 VOICE_ASSIST # Linux KEY_ASSISTANT key 583 ASSIST key 585 EMOJI_PICKER key 586 DICTATE key 656 MACRO_1 key 657 MACRO_2 key 658 MACRO_3 key 659 MACRO_4 # Keys defined by HID usages key usage 0x010082 LOCK FALLBACK_USAGE_MAPPING key usage 0x01009B DO_NOT_DISTURB FALLBACK_USAGE_MAPPING key usage 0x0c0065 SCREENSHOT FALLBACK_USAGE_MAPPING key usage 0x0c0067 WINDOW FALLBACK_USAGE_MAPPING key usage 0x0c006F BRIGHTNESS_UP FALLBACK_USAGE_MAPPING Loading @@ -438,12 +441,17 @@ key usage 0x0c0070 BRIGHTNESS_DOWN FALLBACK_USAGE_MAPPING key usage 0x0c0079 KEYBOARD_BACKLIGHT_UP FALLBACK_USAGE_MAPPING key usage 0x0c007A KEYBOARD_BACKLIGHT_DOWN FALLBACK_USAGE_MAPPING key usage 0x0c007C KEYBOARD_BACKLIGHT_TOGGLE FALLBACK_USAGE_MAPPING key usage 0x0c00D8 DICTATE FALLBACK_USAGE_MAPPING key usage 0x0c00D9 EMOJI_PICKER FALLBACK_USAGE_MAPPING key usage 0x0c0173 MEDIA_AUDIO_TRACK FALLBACK_USAGE_MAPPING key usage 0x0c019C PROFILE_SWITCH FALLBACK_USAGE_MAPPING key usage 0x0c019F SETTINGS FALLBACK_USAGE_MAPPING key usage 0x0c01A2 ALL_APPS FALLBACK_USAGE_MAPPING key usage 0x0c0201 NEW FALLBACK_USAGE_MAPPING key usage 0x0c0203 CLOSE FALLBACK_USAGE_MAPPING key usage 0x0c0208 PRINT FALLBACK_USAGE_MAPPING key usage 0x0c0227 REFRESH FALLBACK_USAGE_MAPPING key usage 0x0c0232 FULLSCREEN FALLBACK_USAGE_MAPPING key usage 0x0c029D LANGUAGE_SWITCH FALLBACK_USAGE_MAPPING key usage 0x0c029F RECENT_APPS FALLBACK_USAGE_MAPPING key usage 0x0c02A2 ALL_APPS FALLBACK_USAGE_MAPPING Loading