Add hint for blocking win key when using raw keyboard (#13066)

Co-authored-by: Susko3 <Susko3@protonmail.com>
This commit is contained in:
expikr
2025-10-27 00:27:33 +08:00
committed by GitHub
parent 0ea20a5f86
commit b4eaf9d96f
5 changed files with 73 additions and 1 deletions

View File

@@ -4384,6 +4384,28 @@ extern "C" {
*/
#define SDL_HINT_WINDOWS_RAW_KEYBOARD "SDL_WINDOWS_RAW_KEYBOARD"
/**
* A variable controlling whether or not the RIDEV_NOHOTKEYS flag is set when
* enabling Windows raw keyboard events.
*
* This blocks any hotkeys that have been registered by applications from
* having any effect beyond generating raw WM_INPUT events.
*
* This flag does not affect system-hotkeys like ALT-TAB or CTRL-ALT-DEL,
* but does affect the Windows Logo key since it is a userland hotkey registered
* by explorer.exe.
*
* The variable can be set to the following values:
*
* - "0": Hotkeys are not excluded. (default)
* - "1": Hotkeys are excluded.
*
* This hint can be set anytime.
*
* \since This hint is available since SDL 3.4.0.
*/
#define SDL_HINT_WINDOWS_RAW_KEYBOARD_EXCLUDE_HOTKEYS "SDL_WINDOWS_RAW_KEYBOARD_EXCLUDE_HOTKEYS"
/**
* A variable controlling whether SDL uses Kernel Semaphores on Windows.
*