summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2011-10-26 16:09:13 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2011-10-26 16:09:13 +1000
commit45eb289f0990db43e8beb1a349c76898486061a6 (patch)
tree99adf4a518ad388c27c357e2ba2d0d1bf7ccb035
parentb79f36bc971f5f7ae85db99c32acc32af9fa8f00 (diff)
Ooops, select for ExposureMask before blocking on it
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-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;
}