From 305c442acab6672bbf01fb7e8fb7a9806f99db3b Mon Sep 17 00:00:00 2001 From: Aajonus Online Date: Tue, 5 May 2020 19:31:53 +0300 Subject: [PATCH 1/2] swallow patch: unfullscreen client and reset focus --- dwm.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dwm.c b/dwm.c index a6968ff..8e004cb 100644 --- a/dwm.c +++ b/dwm.c @@ -513,12 +513,15 @@ unswallow(Client *c) free(c->swallowing); c->swallowing = NULL; + /* unfullscreen the client */ + setfullscreen(c, 0); updatetitle(c); arrange(c->mon); XMapWindow(dpy, c->win); XMoveResizeWindow(dpy, c->win, c->x, c->y, c->w, c->h); - configure(c); setclientstate(c, NormalState); + focus(NULL); + arrange(c->mon); } void From ff49b0353eeeea89a7eace6af4d0d0661857adad Mon Sep 17 00:00:00 2001 From: Aajonus Online Date: Tue, 5 May 2020 19:47:01 +0300 Subject: [PATCH 2/2] fixes previous patch --- dwm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dwm.c b/dwm.c index 8e004cb..9331025 100644 --- a/dwm.c +++ b/dwm.c @@ -499,8 +499,8 @@ swallow(Client *p, Client *c) p->win = c->win; c->win = w; updatetitle(p); - arrange(p->mon); XMoveResizeWindow(dpy, p->win, p->x, p->y, p->w, p->h); + arrange(p->mon); configure(p); updateclientlist(); }