From 4d87c041f6a232aa30528d70d4b9946d1824b4ed Mon Sep 17 00:00:00 2001 From: Daniel Landau Date: Sat, 12 Mar 2011 20:07:20 +0200 Subject: Four finger swipes in multitouch I think four finger swipes are useful, attached is a very simple patch enabling that. Signed-off-by: Daniel Landau Signed-off-by: Henrik Rydberg --- driver/multitouch.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'driver/multitouch.c') diff --git a/driver/multitouch.c b/driver/multitouch.c index 99f1484..a083adc 100644 --- a/driver/multitouch.c +++ b/driver/multitouch.c @@ -261,6 +261,14 @@ static void handle_gestures(LocalDevicePtr local, foreach_bit(i, gs->tapmask) tickle_button(local, i + 1); } + if (GETBIT(gs->type, GS_VSWIPE4)) { + int step = 1 + vswipe_fraction * get_cap_ysize(caps); + button_scroll(local, 16, 17, &vswipe, step, gs->dy); + } + if (GETBIT(gs->type, GS_HSWIPE4)) { + int step = 1 + hswipe_fraction * get_cap_xsize(caps); + button_scroll(local, 18, 19, &hswipe, step, gs->dx); + } } /* called for each full received packet from the touchpad */ -- cgit v1.2.3