summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dwm.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/dwm.c b/dwm.c
index e135715..a13f07b 100644
--- a/dwm.c
+++ b/dwm.c
@@ -94,6 +94,8 @@ struct Client {
94 Client *next; 94 Client *next;
95 Client *snext; 95 Client *snext;
96 Window win; 96 Window win;
97 void *aux;
98 void (*freeaux)(void *);
97}; 99};
98 100
99typedef struct { 101typedef struct {
@@ -1519,6 +1521,8 @@ unmanage(Client *c) {
1519 detachstack(c); 1521 detachstack(c);
1520 if(sel == c) 1522 if(sel == c)
1521 focus(NULL); 1523 focus(NULL);
1524 if(c->aux && c->freeaux)
1525 c->freeaux(c->aux);
1522 XUngrabButton(dpy, AnyButton, AnyModifier, c->win); 1526 XUngrabButton(dpy, AnyButton, AnyModifier, c->win);
1523 setclientstate(c, WithdrawnState); 1527 setclientstate(c, WithdrawnState);
1524 free(c); 1528 free(c);
@@ -1642,6 +1646,8 @@ updatewmhints(Client *c) {
1642 1646
1643void 1647void
1644view(const Arg *arg) { 1648view(const Arg *arg) {
1649 if(arg && (arg->i & TAGMASK) == tagset[seltags])
1650 return;
1645 seltags ^= 1; /* toggle sel tagset */ 1651 seltags ^= 1; /* toggle sel tagset */
1646 if(arg && (arg->ui & TAGMASK)) 1652 if(arg && (arg->ui & TAGMASK))
1647 tagset[seltags] = arg->i & TAGMASK; 1653 tagset[seltags] = arg->i & TAGMASK;