Switch to XWindowEvent() pulling out events that match the mask *and*

window.
This commit is contained in:
okan 2016-09-30 15:05:02 +00:00
parent 24d6348e52
commit f63b2e2341

View File

@ -76,7 +76,7 @@ mousefunc_client_resize(struct client_ctx *cc, union arg *arg)
xu_ptr_setpos(cc->win, cc->geom.w, cc->geom.h);
for (;;) {
XMaskEvent(X_Dpy, MOUSEMASK, &ev);
XWindowEvent(X_Dpy, cc->win, MOUSEMASK, &ev);
switch (ev.type) {
case MotionNotify:
@ -129,7 +129,7 @@ mousefunc_client_move(struct client_ctx *cc, union arg *arg)
xu_ptr_getpos(cc->win, &px, &py);
for (;;) {
XMaskEvent(X_Dpy, MOUSEMASK, &ev);
XWindowEvent(X_Dpy, cc->win, MOUSEMASK, &ev);
switch (ev.type) {
case MotionNotify: