[gtk+] wayland: Update grab serial when ungrabbing keyboards
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] wayland: Update grab serial when ungrabbing keyboards
- Date: Wed, 24 Jun 2015 14:43:58 +0000 (UTC)
commit de260ae2ea8809b992b113d5f37b2dac38b2abcf
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Jun 24 15:41:23 2015 +0200
wayland: Update grab serial when ungrabbing keyboards
This was being done so only on pointers. Internally, a GdkDeviceGrabInfo
is kept for each of the master pointer/keyboard, failing to do this for
keyboards results in a stuck keyboard grab.
https://bugzilla.gnome.org/show_bug.cgi?id=748892
gdk/wayland/gdkdevice-wayland.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/gdk/wayland/gdkdevice-wayland.c b/gdk/wayland/gdkdevice-wayland.c
index 9ef8968..45ba21b 100644
--- a/gdk/wayland/gdkdevice-wayland.c
+++ b/gdk/wayland/gdkdevice-wayland.c
@@ -415,6 +415,11 @@ gdk_wayland_device_ungrab (GdkDevice *device,
display = gdk_device_get_display (device);
+ grab = _gdk_display_get_last_device_grab (display, device);
+
+ if (grab)
+ grab->serial_end = grab->serial_start;
+
if (gdk_device_get_source (device) == GDK_SOURCE_KEYBOARD)
{
/* Device is a keyboard */
@@ -422,11 +427,6 @@ gdk_wayland_device_ungrab (GdkDevice *device,
else
{
/* Device is a pointer */
- grab = _gdk_display_get_last_device_grab (display, device);
-
- if (grab)
- grab->serial_end = grab->serial_start;
-
g_clear_object (&wayland_device->grab_cursor);
gdk_wayland_device_update_window_cursor (wayland_device);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]