Adding sendmon_keepfocus patch

This commit is contained in:
bakkeby
2020-06-24 17:12:54 +02:00
parent ce12e07163
commit 9574035849
3 changed files with 15 additions and 2 deletions

9
dwm.c
View File

@@ -2897,6 +2897,9 @@ sendmon(Client *c, Monitor *m)
unfocus(c, 1);
detach(c);
detachstack(c);
#if SENDMON_KEEPFOCUS_PATCH && !EXRESIZE_PATCH
arrange(c->mon);
#endif // SENDMON_KEEPFOCUS_PATCH
c->mon = m;
#if EMPTYVIEW_PATCH
c->tags = (m->tagset[m->seltags] ? m->tagset[m->seltags] : 1);
@@ -2915,10 +2918,14 @@ sendmon(Client *c, Monitor *m)
arrange(m);
focus(c);
restack(m);
#elif SENDMON_KEEPFOCUS_PATCH
arrange(m);
focus(c);
restack(m);
#else
focus(NULL);
arrange(NULL);
#endif // EXRESIZE_PATCH
#endif // EXRESIZE_PATCH / SENDMON_KEEPFOCUS_PATCH
#if SWITCHTAG_PATCH
if (c->switchtag)
c->switchtag = 0;