dwm-meillo

diff event.c @ 238:969fb6be25e1

applied sander's patch
author Anselm R.Garbe <arg@10ksloc.org>
date Thu, 10 Aug 2006 11:19:25 +0200
parents 98e9901b1dbb
children e5390f8e06b9
line diff
     1.1 --- a/event.c	Thu Aug 10 11:12:15 2006 +0200
     1.2 +++ b/event.c	Thu Aug 10 11:19:25 2006 +0200
     1.3 @@ -122,25 +122,22 @@
     1.4  		}
     1.5  	}
     1.6  	else if((c = getclient(ev->window))) {
     1.7 +		higher(c);
     1.8  		focus(c);
     1.9  		switch(ev->button) {
    1.10  		default:
    1.11  			break;
    1.12  		case Button1:
    1.13 -			if(!c->ismax) {
    1.14 -				if(arrange == dofloat || c->isfloat) {
    1.15 -					higher(c);
    1.16 -					movemouse(c);
    1.17 -				}
    1.18 -				else
    1.19 -					zoom(NULL);
    1.20 -			}
    1.21 +			if(!c->ismax && (arrange == dofloat || c->isfloat))
    1.22 +				movemouse(c);
    1.23 +			break;
    1.24 +		case Button2:
    1.25 +			if(!c->ismax && arrange != dofloat && !c->isfloat)
    1.26 +				zoom(NULL);
    1.27  			break;
    1.28  		case Button3:
    1.29 -			if(!c->ismax && (arrange == dofloat || c->isfloat)) {
    1.30 -				higher(c);
    1.31 +			if(!c->ismax && (arrange == dofloat || c->isfloat))
    1.32  				resizemouse(c);
    1.33 -			}
    1.34  			break;
    1.35  		}
    1.36  	}