[mutter] wayland/actor-surface: Don't listen to notify::position signal



commit e68bb27df2ca99fe20a975fe5fedd1b0a5cc7dbf
Author: Jonas Dreßler <verdre v0yd nl>
Date:   Mon Mar 9 12:30:20 2020 +0100

    wayland/actor-surface: Don't listen to notify::position signal
    
    We started listening to "notify::position" on surface actors with commit
    08e4cb54. This commit was done to fix a regression from commit cf1edff9,
    which forgot to handle some cases like the actual WindowActor and not
    the SurfaceActor (which is a child of the WindowActor) moving (that was
    fixed by listening to MetaWindows "position-changed" signal). Also that
    commit introduced meta_wayland_surface_update_outputs_recursively(),
    which updates the outputs of all (sub-)surfaces in case any position
    changed and made sure subsurfaces also get their outputs updated in case
    the parent actor moved.
    
    Connecting to the "notify::position" signal, which the above commit also
    did is now superflous though because position changes will queue a
    relayout and the actors allocation will change during the next
    allocation cycle, notifying the "allocation" property which we also
    listen to.
    
    So save some resources and stop listening to that signal.
    
    https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1235

 src/wayland/meta-wayland-actor-surface.c | 3 ---
 1 file changed, 3 deletions(-)
---
diff --git a/src/wayland/meta-wayland-actor-surface.c b/src/wayland/meta-wayland-actor-surface.c
index faf170067..b6c6918c3 100644
--- a/src/wayland/meta-wayland-actor-surface.c
+++ b/src/wayland/meta-wayland-actor-surface.c
@@ -414,9 +414,6 @@ meta_wayland_actor_surface_reset_actor (MetaWaylandActorSurface *actor_surface)
   g_signal_connect_swapped (priv->actor, "notify::allocation",
                             G_CALLBACK (meta_wayland_surface_notify_geometry_changed),
                             surface);
-  g_signal_connect_swapped (priv->actor, "notify::position",
-                            G_CALLBACK (meta_wayland_surface_notify_geometry_changed),
-                            surface);
   g_signal_connect_swapped (priv->actor, "notify::mapped",
                             G_CALLBACK (meta_wayland_surface_notify_geometry_changed),
                             surface);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]