From 27aa8173f30139512ebed06cd8fbeb314fc703d3 Mon Sep 17 00:00:00 2001 From: John Lindgren Date: Mon, 1 Dec 2025 13:58:18 -0500 Subject: [PATCH] view: move view_moved() out of view_impl_apply_geometry() --- src/view-impl-common.c | 5 ----- src/xdg.c | 1 + src/xwayland.c | 1 + 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/view-impl-common.c b/src/view-impl-common.c index 8f4e2795..e5e10878 100644 --- a/src/view-impl-common.c +++ b/src/view-impl-common.c @@ -65,7 +65,6 @@ view_impl_apply_geometry(struct view *view, int w, int h) { struct wlr_box *current = &view->current; struct wlr_box *pending = &view->pending; - struct wlr_box old = *current; /* * Anchor right edge if resizing via left edge. @@ -100,8 +99,4 @@ view_impl_apply_geometry(struct view *view, int w, int h) current->width = w; current->height = h; - - if (!wlr_box_equal(current, &old)) { - view_moved(view); - } } diff --git a/src/xdg.c b/src/xdg.c index 2bb6d660..5949638e 100644 --- a/src/xdg.c +++ b/src/xdg.c @@ -238,6 +238,7 @@ handle_commit(struct wl_listener *listener, void *data) if (update_required) { view_impl_apply_geometry(view, size.width, size.height); + view_moved(view); /* * Some views (e.g., terminals that scale as multiples of rows diff --git a/src/xwayland.c b/src/xwayland.c index 91e40897..9c58f574 100644 --- a/src/xwayland.c +++ b/src/xwayland.c @@ -274,6 +274,7 @@ handle_commit(struct wl_listener *listener, void *data) */ if (current->width != state->width || current->height != state->height) { view_impl_apply_geometry(view, state->width, state->height); + view_moved(view); } }