summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnselm R.Garbe <arg@10ksloc.org>2006-08-10 10:16:12 +0200
committerAnselm R.Garbe <arg@10ksloc.org>2006-08-10 10:16:12 +0200
commitb79b5facb104a653314577bb7f15824396b9e94b (patch)
treea145b85cb026c7965b27b3db9ae3bcf0fdaa63bb
parentc53f0fca912e05cddcfbf79d99678b16d183c67d (diff)
downloaddwm-b79b5facb104a653314577bb7f15824396b9e94b.tar.gz
disallow zoom on maximized clients
-rw-r--r--client.c7
-rw-r--r--dwm.14
-rw-r--r--dwm.h1
-rw-r--r--event.c17
4 files changed, 8 insertions, 21 deletions
diff --git a/client.c b/client.c
index f92df83..f268623 100644
--- a/client.c
+++ b/client.c
@@ -197,13 +197,6 @@ killclient(Arg *arg)
}
void
-lower(Client *c)
-{
- XLowerWindow(dpy, c->title);
- XLowerWindow(dpy, c->win);
-}
-
-void
manage(Window w, XWindowAttributes *wa)
{
Client *c;
diff --git a/dwm.1 b/dwm.1
index 5b0be22..a411978 100644
--- a/dwm.1
+++ b/dwm.1
@@ -96,10 +96,6 @@ Moves current
.B window
while dragging.
.TP
-.B Mod1-Button2
-Lowers current
-.B window.
-.TP
.B Mod1-Button3
Resizes current
.B window
diff --git a/dwm.h b/dwm.h
index 57d628a..88640b8 100644
--- a/dwm.h
+++ b/dwm.h
@@ -91,7 +91,6 @@ extern Client *getctitle(Window w);
extern void gravitate(Client *c, Bool invert);
extern void higher(Client *c);
extern void killclient(Arg *arg);
-extern void lower(Client *c);
extern void manage(Window w, XWindowAttributes *wa);
extern void resize(Client *c, Bool sizehints, Corner sticky);
extern void setsize(Client *c);
diff --git a/event.c b/event.c
index b6beed5..0f984f2 100644
--- a/event.c
+++ b/event.c
@@ -127,15 +127,14 @@ buttonpress(XEvent *e)
default:
break;
case Button1:
- if(!c->ismax && (arrange == dofloat || c->isfloat)) {
- higher(c);
- movemouse(c);
+ if(!c->ismax) {
+ if(arrange == dofloat || c->isfloat) {
+ higher(c);
+ movemouse(c);
+ }
+ else
+ zoom(NULL);
}
- else
- zoom(NULL);
- break;
- case Button2:
- lower(c);
break;
case Button3:
if(!c->ismax && (arrange == dofloat || c->isfloat)) {
@@ -225,7 +224,7 @@ enternotify(XEvent *e)
Client *c;
XCrossingEvent *ev = &e->xcrossing;
- if(ev->detail == NotifyInferior)
+ if(ev->mode != NotifyNormal || ev->detail == NotifyInferior)
return;
if((c = getclient(ev->window)) || (c = getctitle(ev->window)))