summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--config.mk4
-rw-r--r--dwm.c14
2 files changed, 7 insertions, 11 deletions
diff --git a/config.mk b/config.mk
index 40e74b0..957a92c 100644
--- a/config.mk
+++ b/config.mk
@@ -11,8 +11,8 @@ X11INC = /usr/X11R6/include
11X11LIB = /usr/X11R6/lib 11X11LIB = /usr/X11R6/lib
12 12
13# Xinerama, un-comment if you want it 13# Xinerama, un-comment if you want it
14#XINERAMALIBS = -L${X11LIB} -lXinerama 14XINERAMALIBS = -L${X11LIB} -lXinerama
15#XINERAMAFLAGS = -DXINERAMA 15XINERAMAFLAGS = -DXINERAMA
16 16
17# includes and libs 17# includes and libs
18INCS = -I. -I/usr/include -I${X11INC} 18INCS = -I. -I/usr/include -I${X11INC}
diff --git a/dwm.c b/dwm.c
index 43dcdc0..8620306 100644
--- a/dwm.c
+++ b/dwm.c
@@ -179,7 +179,7 @@ static void setclientstate(Client *c, long state);
179static void setlayout(const Arg *arg); 179static void setlayout(const Arg *arg);
180static void setmfact(const Arg *arg); 180static void setmfact(const Arg *arg);
181static void setup(void); 181static void setup(void);
182static void showhide(Client *c, unsigned int ntiled); 182static void showhide(Client *c);
183static void sigchld(int signal); 183static void sigchld(int signal);
184static void spawn(const Arg *arg); 184static void spawn(const Arg *arg);
185static void tag(const Arg *arg); 185static void tag(const Arg *arg);
@@ -338,11 +338,7 @@ applysizehints(Client *c, int *x, int *y, int *w, int *h) {
338 338
339void 339void
340arrange(void) { 340arrange(void) {
341 unsigned int nt; 341 showhide(stack);
342 Client *c;
343
344 for(nt = 0, c = nexttiled(clients); c; c = nexttiled(c->next), nt++);
345 showhide(stack, nt);
346 focus(NULL); 342 focus(NULL);
347 if(lt[sellt]->arrange) 343 if(lt[sellt]->arrange)
348 lt[sellt]->arrange(); 344 lt[sellt]->arrange();
@@ -1330,17 +1326,17 @@ setup(void) {
1330} 1326}
1331 1327
1332void 1328void
1333showhide(Client *c, unsigned int ntiled) { 1329showhide(Client *c) {
1334 if(!c) 1330 if(!c)
1335 return; 1331 return;
1336 if(ISVISIBLE(c)) { /* show clients top down */ 1332 if(ISVISIBLE(c)) { /* show clients top down */
1337 XMoveWindow(dpy, c->win, c->x, c->y); 1333 XMoveWindow(dpy, c->win, c->x, c->y);
1338 if(!lt[sellt]->arrange || c->isfloating) 1334 if(!lt[sellt]->arrange || c->isfloating)
1339 resize(c, c->x, c->y, c->w, c->h); 1335 resize(c, c->x, c->y, c->w, c->h);
1340 showhide(c->snext, ntiled); 1336 showhide(c->snext);
1341 } 1337 }
1342 else { /* hide clients bottom up */ 1338 else { /* hide clients bottom up */
1343 showhide(c->snext, ntiled); 1339 showhide(c->snext);
1344 XMoveWindow(dpy, c->win, c->x + 2 * sw, c->y); 1340 XMoveWindow(dpy, c->win, c->x + 2 * sw, c->y);
1345 } 1341 }
1346} 1342}