X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=view.c;h=f2e4040ddb3e37099cd3a25d4047a18a9c3406a1;hb=6c767072a3afab0ecebaa54b028c4dfea07ccccc;hp=503f1c2ba46377e2fad3b60d2332b0c5fc320ad4;hpb=e9cfae7aba1c8eafd827854705bf0d11d2de2dfb;p=dwm.git diff --git a/view.c b/view.c index 503f1c2..f2e4040 100644 --- a/view.c +++ b/view.c @@ -260,14 +260,14 @@ zoom(Arg *arg) { for(n = 0, c = nexttiled(clients); c; c = nexttiled(c->next)) n++; - c = sel; - if((arrange != dofloat) && c != nexttiled(clients)) { - detach(c); - if(clients) - clients->prev = c; - c->next = clients; - clients = c; - focus(c); - arrange(); - } + if((c = sel) == nexttiled(clients)) + if(!(c = nexttiled(c->next))) + return; + detach(c); + if(clients) + clients->prev = c; + c->next = clients; + clients = c; + focus(c); + arrange(); }