[mutter/wip/carlosg/unthrottled-wayland: 19/22] clutter: Trigger immediate repick when pick actor is destroyed
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/carlosg/unthrottled-wayland: 19/22] clutter: Trigger immediate repick when pick actor is destroyed
- Date: Wed, 25 Aug 2021 20:08:26 +0000 (UTC)
commit a2acc3135284fe9b8f00b91e5154500e152b5199
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Aug 25 16:34:43 2021 +0200
clutter: Trigger immediate repick when pick actor is destroyed
Traditionally, the next repaint would also involve picking, which
would correct the actor under the pointer. This now does not happen
out of the box, so we really are waiting for the next pointer event
here.
To avoid the pointer/cursor to lag behind, trigger an immediate
repick here, that will look up the new actor under the pointer
coordinates.
clutter/clutter/clutter-stage.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
---
diff --git a/clutter/clutter/clutter-stage.c b/clutter/clutter/clutter-stage.c
index 72879f0161..c6047b9b0a 100644
--- a/clutter/clutter/clutter-stage.c
+++ b/clutter/clutter/clutter-stage.c
@@ -3483,12 +3483,10 @@ on_device_actor_destroyed (ClutterActor *actor,
/* Simply unset the current_actor pointer here, there's no need to
* unset has_pointer or to disconnect any signals because the actor
* is gone anyway.
- * Also, as soon as the next repaint happens, a repick should be triggered
- * and the PointerDeviceEntry will get updated again, so no need to
- * trigger a repick here.
*/
entry->current_actor = NULL;
g_clear_pointer (&entry->clear_area, cairo_region_destroy);
+ clutter_stage_repick_device (entry->stage, entry->device);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]