Save scancode inside GdkEventPrivate
Windows save in hardware_keycode an information which is not so low level and some application require the hardware scancode. As Windows provides this information save it in GdkEventPrivate and provide a function to get this information. For no Windows system the function return the hardware_keycode instead. Signed-off-by: Frediano Ziglio <fziglio@redhat.com> https://bugzilla.gnome.org/show_bug.cgi?id=765259
This commit is contained in:
committed by
Matthias Clasen
parent
c081ca2d4c
commit
cf14fea5a8
@ -1134,6 +1134,7 @@ fill_key_event (GdkWindow *window,
|
||||
event->key.time = get_time_from_ns_event (nsevent);
|
||||
event->key.state = get_keyboard_modifiers_from_ns_event (nsevent);
|
||||
event->key.hardware_keycode = [nsevent keyCode];
|
||||
_gdk_event_set_scancode (event, [nsevent keyCode]);
|
||||
event->key.group = ([nsevent modifierFlags] & NSAlternateKeyMask) ? 1 : 0;
|
||||
event->key.keyval = GDK_KEY_VoidSymbol;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user