[mutter/wip/carlosg/crossings: 1/9] wayland: Don't use CLUTTER_LEAVE source actor for repick
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/carlosg/crossings: 1/9] wayland: Don't use CLUTTER_LEAVE source actor for repick
- Date: Wed, 23 Dec 2020 11:37:53 +0000 (UTC)
commit c2518ab3936960ca667c96e19af0d90de9183af7
Author: Carlos Garnacho <carlosg gnome org>
Date: Tue Dec 22 17:24:31 2020 +0100
wayland: Don't use CLUTTER_LEAVE source actor for repick
This is the actor receiving the event, therefore precisely not the
actor the pointer is on. We should avoid this event's source here,
use the related actor (i.e. the one being entered) instead.
Fixes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1584
src/wayland/meta-wayland-pointer.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/wayland/meta-wayland-pointer.c b/src/wayland/meta-wayland-pointer.c
index 0b563efcce..ef0923577b 100644
--- a/src/wayland/meta-wayland-pointer.c
+++ b/src/wayland/meta-wayland-pointer.c
@@ -586,7 +586,9 @@ repick_for_event (MetaWaylandPointer *pointer,
ClutterActor *actor;
MetaWaylandSurface *surface;
- if (for_event)
+ if (for_event && clutter_event_type (for_event) == CLUTTER_LEAVE)
+ actor = clutter_event_get_related (for_event);
+ else if (for_event)
actor = clutter_event_get_source (for_event);
else
actor = clutter_stage_get_device_actor (stage, pointer->device, NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]