|
|
776610 |
From 35b69c1af4af996fb4cdac329a941a155569d810 Mon Sep 17 00:00:00 2001
|
|
|
776610 |
From: Carlos Garnacho <carlosg@gnome.org>
|
|
|
776610 |
Date: Thu, 27 Sep 2018 21:05:30 +0200
|
|
|
776610 |
Subject: [PATCH] wayland: Relax requirements for evdev events to have a evcode
|
|
|
776610 |
|
|
|
776610 |
There may be emulated events that don't contain those, it's fine to
|
|
|
776610 |
go through the fallback paths for these.
|
|
|
776610 |
---
|
|
|
776610 |
src/wayland/meta-wayland-keyboard.c | 4 ++--
|
|
|
776610 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
776610 |
|
|
|
776610 |
diff --git a/src/wayland/meta-wayland-keyboard.c b/src/wayland/meta-wayland-keyboard.c
|
|
|
776610 |
index e3ba4f000..4ffe146d5 100644
|
|
|
776610 |
--- a/src/wayland/meta-wayland-keyboard.c
|
|
|
776610 |
+++ b/src/wayland/meta-wayland-keyboard.c
|
|
|
776610 |
@@ -633,7 +633,7 @@ default_grab_key (MetaWaylandKeyboardGrab *grab,
|
|
|
776610 |
{
|
|
|
776610 |
MetaWaylandKeyboard *keyboard = grab->keyboard;
|
|
|
776610 |
gboolean is_press = event->type == CLUTTER_KEY_PRESS;
|
|
|
776610 |
- guint32 code;
|
|
|
776610 |
+ guint32 code = 0;
|
|
|
776610 |
#ifdef HAVE_NATIVE_BACKEND
|
|
|
776610 |
MetaBackend *backend = meta_get_backend ();
|
|
|
776610 |
#endif
|
|
|
776610 |
@@ -647,7 +647,7 @@ default_grab_key (MetaWaylandKeyboardGrab *grab,
|
|
|
776610 |
#ifdef HAVE_NATIVE_BACKEND
|
|
|
776610 |
if (META_IS_BACKEND_NATIVE (backend))
|
|
|
776610 |
code = clutter_evdev_event_get_event_code (event);
|
|
|
776610 |
- else
|
|
|
776610 |
+ if (code == 0)
|
|
|
776610 |
#endif
|
|
|
776610 |
code = evdev_code (&event->key);
|
|
|
776610 |
|
|
|
776610 |
--
|
|
|
776610 |
2.20.1
|
|
|
776610 |
|