compositor: Trigger repick after window effects here
Just because of implementation details, this is only relevant to Wayland, and is done via ::effects-completed handlers there. Ideally, Clutter should notice by itself about effects starting, finishing, and affecting picking. Doing this in generic code seems slightly cleaner in the interim. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1654>
This commit is contained in:
@ -37,7 +37,6 @@ typedef struct _MetaWaylandShellSurfacePrivate
|
||||
MetaWindow *window;
|
||||
|
||||
gulong unmanaging_handler_id;
|
||||
gulong effects_completed_handler_id;
|
||||
} MetaWaylandShellSurfacePrivate;
|
||||
|
||||
G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (MetaWaylandShellSurface,
|
||||
@ -106,8 +105,6 @@ clear_window (MetaWaylandShellSurface *shell_surface)
|
||||
|
||||
g_clear_signal_handler (&priv->unmanaging_handler_id,
|
||||
priv->window);
|
||||
g_clear_signal_handler (&priv->effects_completed_handler_id,
|
||||
meta_window_actor_from_window (priv->window));
|
||||
priv->window = NULL;
|
||||
|
||||
surface_actor = meta_wayland_surface_get_actor (surface);
|
||||
@ -124,13 +121,6 @@ window_unmanaging (MetaWindow *window,
|
||||
clear_window (shell_surface);
|
||||
}
|
||||
|
||||
static void
|
||||
window_actor_effects_completed (MetaWindowActor *window_actor,
|
||||
MetaWaylandSurface *surface)
|
||||
{
|
||||
meta_wayland_compositor_repick (surface->compositor);
|
||||
}
|
||||
|
||||
void
|
||||
meta_wayland_shell_surface_set_window (MetaWaylandShellSurface *shell_surface,
|
||||
MetaWindow *window)
|
||||
@ -156,11 +146,6 @@ meta_wayland_shell_surface_set_window (MetaWaylandShellSurface *shell_surface,
|
||||
"unmanaging",
|
||||
G_CALLBACK (window_unmanaging),
|
||||
shell_surface);
|
||||
priv->effects_completed_handler_id =
|
||||
g_signal_connect (meta_window_actor_from_window (window),
|
||||
"effects-completed",
|
||||
G_CALLBACK (window_actor_effects_completed),
|
||||
surface);
|
||||
|
||||
meta_window_update_monitor (window, META_WINDOW_UPDATE_MONITOR_FLAGS_NONE);
|
||||
}
|
||||
|
Reference in New Issue
Block a user