dwm-meillo

diff view.c @ 532:651f2c868b31

code polishing, removed unnecessary newlines
author Anselm R. Garbe <arg@10kloc.org>
date Fri, 06 Oct 2006 11:50:15 +0200
parents 96563762b4ad
children a5567a0d3011
line diff
     1.1 --- a/view.c	Fri Oct 06 11:37:12 2006 +0200
     1.2 +++ b/view.c	Fri Oct 06 11:50:15 2006 +0200
     1.3 @@ -1,5 +1,4 @@
     1.4 -/*
     1.5 - * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
     1.6 +/* (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
     1.7   * See LICENSE file for license details.
     1.8   */
     1.9  #include "dwm.h"
    1.10 @@ -43,9 +42,9 @@
    1.11  }
    1.12  
    1.13  static void
    1.14 -togglemax(Client *c)
    1.15 -{
    1.16 +togglemax(Client *c) {
    1.17  	XEvent ev;
    1.18 +
    1.19  	if((c->ismax = !c->ismax)) {
    1.20  		c->rx = c->x; c->x = sx;
    1.21  		c->ry = c->y; c->y = bh;
    1.22 @@ -102,11 +101,9 @@
    1.23  
    1.24  	for(n = 0, c = nexttiled(clients); c; c = nexttiled(c->next))
    1.25  		n++;
    1.26 -
    1.27  	mpx = (sw * master) / 1000;
    1.28  	stackw = sw - mpx;
    1.29  	stackh = sh - bh;
    1.30 -
    1.31  	th = stackh;
    1.32  	if(n > 1)
    1.33  		th /= (n - 1);
    1.34 @@ -145,6 +142,7 @@
    1.35  		}
    1.36  		else
    1.37  			ban(c);
    1.38 +
    1.39  	if(!sel || !isvisible(sel)) {
    1.40  		for(c = stack; c && !isvisible(c); c = c->snext);
    1.41  		focus(c);
    1.42 @@ -158,7 +156,6 @@
    1.43     
    1.44  	if(!sel)
    1.45  		return;
    1.46 -
    1.47  	if(!(c = getnext(sel->next)))
    1.48  		c = getnext(clients);
    1.49  	if(c) {
    1.50 @@ -173,7 +170,6 @@
    1.51  
    1.52  	if(!sel)
    1.53  		return;
    1.54 -
    1.55  	if(!(c = getprev(sel->prev))) {
    1.56  		for(c = clients; c && c->next; c = c->next);
    1.57  		c = getprev(c);
    1.58 @@ -204,7 +200,6 @@
    1.59  			n++;
    1.60  	if(!sel || sel->isfloat || n < 2 || (arrange == dofloat))
    1.61  		return;
    1.62 -
    1.63  	if(sel == getnext(clients)) {
    1.64  		if(master + arg->i > 950 || master + arg->i < 50)
    1.65  			return;
    1.66 @@ -290,8 +285,6 @@
    1.67  	arrange(NULL);
    1.68  }
    1.69  
    1.70 -
    1.71 -
    1.72  void
    1.73  zoom(Arg *arg) {
    1.74  	unsigned int n;
    1.75 @@ -299,18 +292,15 @@
    1.76  
    1.77  	if(!sel)
    1.78  		return;
    1.79 -
    1.80  	if(sel->isfloat || (arrange == dofloat)) {
    1.81  		togglemax(sel);
    1.82  		return;
    1.83  	}
    1.84 -
    1.85  	for(n = 0, c = clients; c; c = c->next)
    1.86  		if(isvisible(c) && !c->isfloat)
    1.87  			n++;
    1.88  	if(n < 2 || (arrange == dofloat))
    1.89  		return;
    1.90 -
    1.91  	if((c = sel) == nexttiled(clients))
    1.92  		if(!(c = nexttiled(c->next)))
    1.93  			return;