now tiled windows can be resized/moved, their floating state will be toggled implicitely

This commit is contained in:
Anselm R. Garbe 2007-09-16 13:27:33 +02:00
parent 9449ea3e00
commit d1ce3eac33
2 changed files with 12 additions and 8 deletions

16
dwm.c
View file

@ -335,16 +335,20 @@ buttonpress(XEvent *e) {
focus(c);
if(CLEANMASK(ev->state) != MODKEY)
return;
if(ev->button == Button1 && (isarrange(floating) || c->isfloating)) {
restack();
if(ev->button == Button1) {
if(!isarrange(floating) && !c->isfloating)
togglefloating(NULL);
else
restack();
movemouse(c);
}
else if(ev->button == Button2)
zoom(NULL);
else if(ev->button == Button3
&& (isarrange(floating) || c->isfloating) && !c->isfixed)
{
restack();
else if(ev->button == Button3 && !c->isfixed) {
if(!isarrange(floating) && !c->isfloating)
togglefloating(NULL);
else
restack();
resizemouse(c);
}
}