summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--multitouch.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/multitouch.c b/multitouch.c
index 86ed48c..62aa348 100644
--- a/multitouch.c
+++ b/multitouch.c
@@ -57,6 +57,7 @@ static Window init_window(struct multitouch *mt)
win = XCreateSimpleWindow(mt->dpy, mt->root, 0, 0, 800, 600,
0, 0, WhitePixel(mt->dpy, mt->screen));
+ XSelectInput(mt->dpy, win, ExposureMask);
XMapWindow(mt->dpy, win);
XMaskEvent(mt->dpy, ExposureMask, &event);
@@ -71,7 +72,7 @@ static Window init_window(struct multitouch *mt)
XISelectEvents(mt->dpy, win, &evmask, 1);
- XFlush(mt->dpy);
+ XSync(mt->dpy, False);
return win;
}