draw window borders when redrawing a window

from aon@iki.fi
This commit is contained in:
jasper 2007-06-05 18:57:03 +00:00
parent 9b04f2582b
commit 15fdb76df9

10
grab.c
View File

@ -64,9 +64,12 @@ grab_sweep(struct client_ctx *cc)
for (;;) { for (;;) {
/* Look for changes in ptr position. */ /* Look for changes in ptr position. */
XMaskEvent(X_Dpy, MouseMask, &ev); XMaskEvent(X_Dpy, MouseMask|ExposureMask, &ev);
switch (ev.type) { switch (ev.type) {
case Expose:
client_draw_border(cc);
break;
case MotionNotify: case MotionNotify:
if (_sweepcalc(cc, x0, y0, ev.xmotion.x, ev.xmotion.y)) if (_sweepcalc(cc, x0, y0, ev.xmotion.x, ev.xmotion.y))
/* Recompute window output */ /* Recompute window output */
@ -108,9 +111,12 @@ grab_drag(struct client_ctx *cc)
xu_ptr_getpos(sc->rootwin, &xm, &ym); xu_ptr_getpos(sc->rootwin, &xm, &ym);
for (;;) { for (;;) {
XMaskEvent(X_Dpy, MouseMask, &ev); XMaskEvent(X_Dpy, MouseMask|ExposureMask, &ev);
switch (ev.type) { switch (ev.type) {
case Expose:
client_draw_border(cc);
break;
case MotionNotify: case MotionNotify:
cc->geom.x = x0 + (ev.xmotion.x - xm); cc->geom.x = x0 + (ev.xmotion.x - xm);
cc->geom.y = y0 + (ev.xmotion.y - ym); cc->geom.y = y0 + (ev.xmotion.y - ym);