From fa5526c842908e26709416476610995d07785821 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Thu, 17 Oct 2019 11:26:31 +0300 Subject: [PATCH] sowm: Don't force window location when the window wants to be put elsewhere. --- sowm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sowm.c b/sowm.c index 46e4532..fcd066c 100644 --- a/sowm.c +++ b/sowm.c @@ -497,8 +497,10 @@ void map_request(XEvent *e) { Window w = e->xmaprequest.window; XSelectInput(d, w, StructureNotifyMask|EnterWindowMask); + win_size(w, &wx, &wy, &ww, &wh); + + if (wx == 0 && wy == 0) win_center((Arg){.i = w}); - win_center((Arg){.i = w}); XMapWindow(d, w); win_focus(w); win_add(w);