From 3b6bc1a7dc5871aef2c47426f87bb409a622de29 Mon Sep 17 00:00:00 2001 From: Henrik Rydberg Date: Fri, 6 Aug 2010 14:32:50 +0200 Subject: Remove thread code The primary usecase of grail involves using it together with the xserver, which is not threaded. Revert the touch-dev code back to the state prior to adding the threaded processing. Deferred event handling can be implemented by other means when needed. Signed-off-by: Henrik Rydberg --- test/grail-gesture.c | 4 +--- test/grail-touch.c | 6 ++---- 2 files changed, 3 insertions(+), 7 deletions(-) (limited to 'test') diff --git a/test/grail-gesture.c b/test/grail-gesture.c index 18c50c3..16b33ac 100644 --- a/test/grail-gesture.c +++ b/test/grail-gesture.c @@ -64,10 +64,8 @@ static void tp_gesture(struct grail *ge, const struct grail_event *ev) static void loop_device(struct grail *ge, int fd) { - while (!grail_idle(ge, fd, 5000)) { + while (!grail_idle(ge, fd, 5000)) grail_pull(ge, fd); - fprintf(stderr, "\r"); - } } int main(int argc, char *argv[]) diff --git a/test/grail-touch.c b/test/grail-touch.c index 8893c0d..bed31c3 100644 --- a/test/grail-touch.c +++ b/test/grail-touch.c @@ -54,10 +54,8 @@ static void loop_device(struct touch_dev *dev, int fd) struct touch_engine engine; touch_engine_init(&engine, tp_event, tp_sync, 0); touch_engine_attach(&engine, dev); - while (!touch_dev_idle(dev, fd, 5000)) { - touch_dev_fetch(dev, fd); - touch_dev_process(dev); - } + while (!touch_dev_idle(dev, fd, 5000)) + touch_dev_pull(dev, fd); touch_engine_detach(&engine, dev); } -- cgit v1.2.3