Accepting request 503268 from home:Zaitor
Doh, I had added yet a patch OBS-URL: https://build.opensuse.org/request/show/503268 OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/mutter?expand=0&rev=239
This commit is contained in:
parent
5555189460
commit
6668873f63
@ -399,3 +399,60 @@ index 9f55590..87bc8c7 100644
|
||||
--
|
||||
cgit v0.12
|
||||
|
||||
|
||||
From e22c75377b4bb0be0bc21ed7a1f2f017672edbfe Mon Sep 17 00:00:00 2001
|
||||
From: mitchmindtree <mitchell.nordine@gmail.com>
|
||||
Date: Fri, 2 Jun 2017 14:41:56 +1000
|
||||
Subject: wayland/pointer: Check for subsurfaces when grabbing
|
||||
|
||||
Previously, the function only returned `TRUE` if the given surface was
|
||||
equal to the given pointer's focused surface. This changes the behaviour
|
||||
to also return `TRUE` if any of the given surface's subsurfaces are
|
||||
equal to the pointer's focused surface.
|
||||
|
||||
https://bugzilla.gnome.org/show_bug.cgi?id=781811
|
||||
---
|
||||
src/wayland/meta-wayland-pointer.c | 22 +++++++++++++++++++++-
|
||||
1 file changed, 21 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/wayland/meta-wayland-pointer.c b/src/wayland/meta-wayland-pointer.c
|
||||
index 0cd2883..15e27cd 100644
|
||||
--- a/src/wayland/meta-wayland-pointer.c
|
||||
+++ b/src/wayland/meta-wayland-pointer.c
|
||||
@@ -1162,13 +1162,33 @@ meta_wayland_pointer_create_new_resource (MetaWaylandPointer *pointer,
|
||||
}
|
||||
}
|
||||
|
||||
+static gboolean
|
||||
+pointer_can_grab_surface (MetaWaylandPointer *pointer,
|
||||
+ MetaWaylandSurface *surface)
|
||||
+{
|
||||
+ GList *l;
|
||||
+
|
||||
+ if (pointer->focus_surface == surface)
|
||||
+ return TRUE;
|
||||
+
|
||||
+ for (l = surface->subsurfaces; l; l = l->next)
|
||||
+ {
|
||||
+ MetaWaylandSurface *subsurface = l->data;
|
||||
+
|
||||
+ if (pointer_can_grab_surface (pointer, subsurface))
|
||||
+ return TRUE;
|
||||
+ }
|
||||
+
|
||||
+ return FALSE;
|
||||
+}
|
||||
+
|
||||
gboolean
|
||||
meta_wayland_pointer_can_grab_surface (MetaWaylandPointer *pointer,
|
||||
MetaWaylandSurface *surface,
|
||||
uint32_t serial)
|
||||
{
|
||||
return (pointer->grab_serial == serial &&
|
||||
- pointer->focus_surface == surface);
|
||||
+ pointer_can_grab_surface (pointer, surface));
|
||||
}
|
||||
|
||||
gboolean
|
||||
--
|
||||
cgit v0.12
|
||||
|
Loading…
Reference in New Issue
Block a user