aboutsummaryrefslogtreecommitdiffstats
path: root/event.c
diff options
context:
space:
mode:
authorarg@mmvi <unknown>2006-09-25 21:28:00 +0200
committerarg@mmvi <unknown>2006-09-25 21:28:00 +0200
commit67bc08d1b938842d27d976da9bbbc210b1f860b7 (patch)
tree52ee81bad219aa1dc7fa159cec83200bd4043d17 /event.c
parentbcb07de75000e75a450e4dddf851e9ce69966f59 (diff)
downloaddwm-67bc08d1b938842d27d976da9bbbc210b1f860b7.tar.gz
slight change of event handling order
Diffstat (limited to 'event.c')
-rw-r--r--event.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/event.c b/event.c
index fe25dee..cf89428 100644
--- a/event.c
+++ b/event.c
@@ -37,6 +37,9 @@ movemouse(Client *c) {
for(;;) {
XMaskEvent(dpy, MOUSEMASK | ExposureMask, &ev);
switch (ev.type) {
+ case ButtonRelease:
+ XUngrabPointer(dpy, CurrentTime);
+ return;
case Expose:
handler[Expose](&ev);
break;
@@ -46,9 +49,6 @@ movemouse(Client *c) {
c->y = ocy + (ev.xmotion.y - y1);
resize(c, False, TopLeft);
break;
- case ButtonRelease:
- XUngrabPointer(dpy, CurrentTime);
- return;
}
}
}
@@ -70,6 +70,9 @@ resizemouse(Client *c) {
for(;;) {
XMaskEvent(dpy, MOUSEMASK | ExposureMask, &ev);
switch(ev.type) {
+ case ButtonRelease:
+ XUngrabPointer(dpy, CurrentTime);
+ return;
case Expose:
handler[Expose](&ev);
break;
@@ -87,9 +90,6 @@ resizemouse(Client *c) {
sticky = (ocy <= ev.xmotion.y) ? TopRight : BotRight;
resize(c, True, sticky);
break;
- case ButtonRelease:
- XUngrabPointer(dpy, CurrentTime);
- return;
}
}
}