mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-13 22:10:08 +00:00
Handle emulated keyboard input that arrives as VK_PACKET
Fixes bug #642772. Thanks to the anonymous bug reporter for providing a test program.
This commit is contained in:
parent
50233edbc9
commit
8e6932f46e
@ -1958,12 +1958,16 @@ gdk_event_translate (MSG *msg,
|
||||
|
||||
build_key_event_state (event, key_state);
|
||||
|
||||
gdk_keymap_translate_keyboard_state (_gdk_win32_display_get_keymap (_gdk_display),
|
||||
event->key.hardware_keycode,
|
||||
event->key.state,
|
||||
event->key.group,
|
||||
&event->key.keyval,
|
||||
NULL, NULL, NULL);
|
||||
if (msg->wParam == VK_PACKET &&
|
||||
ToUnicode (VK_PACKET, HIWORD (msg->lParam), key_state, wbuf, 1, 0) == 1)
|
||||
event->key.keyval = gdk_unicode_to_keyval (wbuf[0]);
|
||||
else
|
||||
gdk_keymap_translate_keyboard_state (_gdk_win32_display_get_keymap (_gdk_display),
|
||||
event->key.hardware_keycode,
|
||||
event->key.state,
|
||||
event->key.group,
|
||||
&event->key.keyval,
|
||||
NULL, NULL, NULL);
|
||||
|
||||
fill_key_event_string (event);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user