From a595fc6d476c51efb9825deced802aa462260153 Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Fri, 25 Feb 2022 16:13:16 +0100 Subject: [PATCH] st: Move StWidget away from clutter_event_get_source() Ask the stage about the device actor instead for hover tracking. Part-of: --- src/st/st-widget.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/st/st-widget.c b/src/st/st-widget.c index e131a5108..f50be949a 100644 --- a/src/st/st-widget.c +++ b/src/st/st-widget.c @@ -692,7 +692,13 @@ st_widget_enter (ClutterActor *actor, if (priv->track_hover) { - if (clutter_actor_contains (actor, event->source)) + ClutterStage *stage; + ClutterActor *target; + + stage = clutter_event_get_stage ((ClutterEvent *) event); + target = clutter_stage_get_event_actor (stage, (ClutterEvent *) event); + + if (clutter_actor_contains (actor, target)) st_widget_set_hover (ST_WIDGET (actor), TRUE); else {