From bf76cefe47749f784d4ee3b7b71c1c86460e236b Mon Sep 17 00:00:00 2001 From: Anselm R Garbe Date: Wed, 2 Jul 2008 11:06:46 +0100 Subject: minor fix to view() --- dwm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dwm.c b/dwm.c index e1357158..a13f07b5 100644 --- a/dwm.c +++ b/dwm.c @@ -94,6 +94,8 @@ struct Client { Client *next; Client *snext; Window win; + void *aux; + void (*freeaux)(void *); }; typedef struct { @@ -1519,6 +1521,8 @@ unmanage(Client *c) { detachstack(c); if(sel == c) focus(NULL); + if(c->aux && c->freeaux) + c->freeaux(c->aux); XUngrabButton(dpy, AnyButton, AnyModifier, c->win); setclientstate(c, WithdrawnState); free(c); @@ -1642,6 +1646,8 @@ updatewmhints(Client *c) { void view(const Arg *arg) { + if(arg && (arg->i & TAGMASK) == tagset[seltags]) + return; seltags ^= 1; /* toggle sel tagset */ if(arg && (arg->ui & TAGMASK)) tagset[seltags] = arg->i & TAGMASK; -- cgit v1.2.3