diff --git a/src/wayland/meta-wayland-actor-surface.c b/src/wayland/meta-wayland-actor-surface.c index 47b3c1c3e..5d4478253 100644 --- a/src/wayland/meta-wayland-actor-surface.c +++ b/src/wayland/meta-wayland-actor-surface.c @@ -76,6 +76,9 @@ clear_surface_actor (MetaWaylandActorSurface *actor_surface) g_signal_handlers_disconnect_by_func (priv->actor, meta_wayland_surface_update_outputs_recursively, surface); + g_signal_handlers_disconnect_by_func (priv->actor, + meta_wayland_surface_update_outputs, + surface); g_clear_object (&priv->actor); } @@ -445,4 +448,7 @@ meta_wayland_actor_surface_reset_actor (MetaWaylandActorSurface *actor_surface) g_signal_connect_swapped (priv->actor, "notify::mapped", G_CALLBACK (meta_wayland_surface_update_outputs_recursively), surface); + g_signal_connect_swapped (priv->actor, "stage-views-changed", + G_CALLBACK (meta_wayland_surface_update_outputs), + surface); } diff --git a/src/wayland/meta-wayland-shell-surface.c b/src/wayland/meta-wayland-shell-surface.c index 12d291043..7bad43f34 100644 --- a/src/wayland/meta-wayland-shell-surface.c +++ b/src/wayland/meta-wayland-shell-surface.c @@ -37,7 +37,6 @@ typedef struct _MetaWaylandShellSurfacePrivate MetaWindow *window; gulong unmanaging_handler_id; - gulong position_changed_handler_id; gulong effects_completed_handler_id; } MetaWaylandShellSurfacePrivate; @@ -107,8 +106,6 @@ clear_window (MetaWaylandShellSurface *shell_surface) g_clear_signal_handler (&priv->unmanaging_handler_id, priv->window); - g_clear_signal_handler (&priv->position_changed_handler_id, - priv->window); g_clear_signal_handler (&priv->effects_completed_handler_id, meta_window_actor_from_window (priv->window)); priv->window = NULL; @@ -127,18 +124,10 @@ window_unmanaging (MetaWindow *window, clear_window (shell_surface); } -static void -window_position_changed (MetaWindow *window, - MetaWaylandSurface *surface) -{ - meta_wayland_surface_update_outputs_recursively (surface); -} - static void window_actor_effects_completed (MetaWindowActor *window_actor, MetaWaylandSurface *surface) { - meta_wayland_surface_update_outputs_recursively (surface); meta_wayland_compositor_repick (surface->compositor); } @@ -167,11 +156,6 @@ meta_wayland_shell_surface_set_window (MetaWaylandShellSurface *shell_surface, "unmanaging", G_CALLBACK (window_unmanaging), shell_surface); - priv->position_changed_handler_id = - g_signal_connect (window, - "position-changed", - G_CALLBACK (window_position_changed), - surface); priv->effects_completed_handler_id = g_signal_connect (meta_window_actor_from_window (window), "effects-completed", diff --git a/src/wayland/meta-xwayland-surface.c b/src/wayland/meta-xwayland-surface.c index c8625f414..11f580127 100644 --- a/src/wayland/meta-xwayland-surface.c +++ b/src/wayland/meta-xwayland-surface.c @@ -44,7 +44,6 @@ struct _MetaXwaylandSurface MetaWindow *window; gulong unmanaging_handler_id; - gulong position_changed_handler_id; gulong effects_completed_handler_id; }; @@ -67,8 +66,6 @@ clear_window (MetaXwaylandSurface *xwayland_surface) g_clear_signal_handler (&xwayland_surface->unmanaging_handler_id, xwayland_surface->window); - g_clear_signal_handler (&xwayland_surface->position_changed_handler_id, - xwayland_surface->window); window_actor = meta_window_actor_from_window (xwayland_surface->window); g_clear_signal_handler (&xwayland_surface->effects_completed_handler_id, @@ -91,18 +88,10 @@ window_unmanaging (MetaWindow *window, clear_window (xwayland_surface); } -static void -window_position_changed (MetaWindow *window, - MetaWaylandSurface *surface) -{ - meta_wayland_surface_update_outputs_recursively (surface); -} - static void window_actor_effects_completed (MetaWindowActor *window_actor, MetaWaylandSurface *surface) { - meta_wayland_surface_update_outputs_recursively (surface); meta_wayland_compositor_repick (surface->compositor); } @@ -142,11 +131,6 @@ meta_xwayland_surface_associate_with_window (MetaXwaylandSurface *xwayland_surfa "unmanaging", G_CALLBACK (window_unmanaging), xwayland_surface); - xwayland_surface->position_changed_handler_id = - g_signal_connect (window, - "position-changed", - G_CALLBACK (window_position_changed), - surface); xwayland_surface->effects_completed_handler_id = g_signal_connect (meta_window_actor_from_window (window), "effects-completed",