scratchpads: when the scratchpad patch is added, the tagmask is altered, so to get a window onto all tags you have to do ~SPTAGSMASK instead of ~0 as otherwise it will interfere with the scratchpads, ref. #53

This commit is contained in:
bakkeby
2020-09-28 17:48:49 +02:00
parent 8726ae0aa9
commit 795fcc3b51
4 changed files with 22 additions and 2 deletions

9
dwm.c
View File

@ -3746,14 +3746,19 @@ toggleview(const Arg *arg)
selmon->tagset[selmon->seltags] = newtagset;
#if PERTAG_PATCH
if (newtagset == ~0) {
#if SCRATCHPADS_PATCH
if (newtagset == ~SPTAGMASK)
#else
if (newtagset == ~0)
#endif // SCRATCHPADS_PATCH
{
selmon->pertag->prevtag = selmon->pertag->curtag;
selmon->pertag->curtag = 0;
}
/* test if the user did not select the same tag */
if (!(newtagset & 1 << (selmon->pertag->curtag - 1))) {
selmon->pertag->prevtag = selmon->pertag->curtag;
for (i=0; !(newtagset & 1 << i); i++) ;
for (i = 0; !(newtagset & 1 << i); i++) ;
selmon->pertag->curtag = i + 1;
}