aboutsummaryrefslogtreecommitdiff
path: root/dwl.c
diff options
context:
space:
mode:
authorLeonardo Hernández Hernández <leohdz172@protonmail.com>2022-09-05 22:48:16 -0500
committerLeonardo Hernández Hernández <leohdz172@protonmail.com>2022-09-06 13:23:19 -0500
commit1aacfada29657ec1104f856687400e65927e54b6 (patch)
treeb8b013c3fc53e33232d43805966ec3e1812b539e /dwl.c
parent14c010a0d69eb8a528d63a311a94134a52cab8bb (diff)
set `c->prev` in setmon() and not in mapnotify()
Diffstat (limited to 'dwl.c')
-rw-r--r--dwl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dwl.c b/dwl.c
index 5ed534e..41ce69f 100644
--- a/dwl.c
+++ b/dwl.c
@@ -1424,7 +1424,6 @@ mapnotify(struct wl_listener *listener, void *data)
client_get_geometry(c, &c->geom);
c->geom.width += 2 * c->bw;
c->geom.height += 2 * c->bw;
- c->prev = c->geom;
/* Insert this client into client lists. */
wl_list_insert(&clients, &c->link);
@@ -1960,6 +1959,7 @@ setmon(Client *c, Monitor *m, unsigned int newtags)
if (oldmon == m)
return;
c->mon = m;
+ c->prev = c->geom;
/* TODO leave/enter is not optimal but works */
if (oldmon) {