mirror of
https://github.com/FreeRDP/FreeRDP.git
synced 2025-06-03 00:00:20 +00:00
shadow: convert incoming key scancode to DWORD before |= KBDEXT
KBDEXT is 0x100, so if we |= it onto a UINT8 it actually does nothing, making us interpret all scancodes as if they're non-extended.
This commit is contained in:
parent
7f13ac17e2
commit
9591dd1f0d
@ -212,6 +212,7 @@ static BOOL x11_shadow_input_keyboard_event(rdpShadowSubsystem* subsystem, rdpSh
|
|||||||
x11ShadowSubsystem* x11 = (x11ShadowSubsystem*)subsystem;
|
x11ShadowSubsystem* x11 = (x11ShadowSubsystem*)subsystem;
|
||||||
DWORD vkcode;
|
DWORD vkcode;
|
||||||
DWORD keycode;
|
DWORD keycode;
|
||||||
|
DWORD scancode;
|
||||||
BOOL extended = FALSE;
|
BOOL extended = FALSE;
|
||||||
|
|
||||||
if (!client || !subsystem)
|
if (!client || !subsystem)
|
||||||
@ -220,10 +221,11 @@ static BOOL x11_shadow_input_keyboard_event(rdpShadowSubsystem* subsystem, rdpSh
|
|||||||
if (flags & KBD_FLAGS_EXTENDED)
|
if (flags & KBD_FLAGS_EXTENDED)
|
||||||
extended = TRUE;
|
extended = TRUE;
|
||||||
|
|
||||||
|
scancode = code;
|
||||||
if (extended)
|
if (extended)
|
||||||
code |= KBDEXT;
|
scancode |= KBDEXT;
|
||||||
|
|
||||||
vkcode = GetVirtualKeyCodeFromVirtualScanCode(code, 4);
|
vkcode = GetVirtualKeyCodeFromVirtualScanCode(scancode, 4);
|
||||||
|
|
||||||
if (extended)
|
if (extended)
|
||||||
vkcode |= KBDEXT;
|
vkcode |= KBDEXT;
|
||||||
|
Loading…
Reference in New Issue
Block a user