Extended RETROK_ values with 18 new items, commonly found on
"multimedia" keyboards.
Mapping added for SDL, X11, Wayland, dinput, winraw keymaps.
Keyboard tester function of Remote Retropad extended to cover new keys.
One fix in Android mapping for #12986
Add keyboard overlay preset, keyboard submenu, and osk_toggle hotkey. Use overlay caching for osk_toggle.
For now, keyboard menu has only preset path, auto-scale toggle, and opacity.
Related fixes:
- input_keyboard_event: Don't check hotkey binds when device is RETRO_DEVICE_POINTER
- Add input_keymaps_translate_rk_to_ascii() for correct character input to input_keyboard_event
- input_overlay_poll: Delay clearing INPUT_OVERLAY_BLOCKED flag until there is no overlay input (Avoids stray input after osk_toggle)
- Send keyboard events for modifiers before other keys (for correct modifier+key input if hitboxes overlap)
From https://github.com/bramp/libcec-daemon, we have some keys that
aren’t recognized by RetroArch right now. So we can map them to actual
RETROK_ codes. They are:
- KEY_EXIT -> RETROK_CLEAR
- KEY_OK -> RETROK_RETURN
- KEY_SELECT -> RETROK_RETURN
See
fe9df5ddf7/src/main.cpp (L233-L312)
for a full list
* the remote control presents itself as ID_INPUT_KEY, not
ID_INPUT_KEYBOARD. However, ID_INPUT_KEYBOARD is a subset of
ID_INPUT_KEY.
* the remote control lacks the backspace and enter keys, which are hard
coded in RetroArch. It has "back" and "ok" instead, so map those to
RETROK_BACKSPACE and RETROK_ENTER as well.
Remote controls also have no ESC key, but that one is customizable
and I used the Power key of the remote (which already has a mapping
to RETROK_POWER).
The functionality provided is really the bare minimum, but it is enough
to teach a kid "press the power button here to watch TV"; compared to
pressing L1+R1+START+SELECT and navigating to the RetroArch's "quit"
menu item, that hopefully has more chances of success.