summaryrefslogtreecommitdiff
path: root/Xi
diff options
context:
space:
mode:
authorChase Douglas <chase.douglas@canonical.com>2012-04-10 17:12:41 -0700
committerPeter Hutterer <peter.hutterer@who-t.net>2012-04-16 11:30:02 +1000
commit163b0f375d73c05873fb341652de3ed347337828 (patch)
treed14a796305c120c42a9429cd722796ad614a93a6 /Xi
parent210cd12c47d063f97915ff23292b61d09abfd73a (diff)
Update event type when delivering end event to a pointer listener
Just like when we deliver to a touch listener, we must convert a touch end event to an update event for further clients. This also ensures that the touch record is not deleted at the end of ProcessTouchEvent(). Signed-off-by: Chase Douglas <chase.douglas@canonical.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'Xi')
-rw-r--r--Xi/exevents.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Xi/exevents.c b/Xi/exevents.c
index 31171239f..a843e0300 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -1757,6 +1757,13 @@ DeliverTouchEndEvent(DeviceIntPtr dev, TouchPointInfoPtr ti, InternalEvent *ev,
listener->type == LISTENER_POINTER_GRAB) {
rc = DeliverTouchEmulatedEvent(dev, ti, ev, listener, client, win,
grab, xi2mask);
+
+ if (ti->num_listeners > 1) {
+ ev->any.type = ET_TouchUpdate;
+ ev->device_event.flags |= TOUCH_PENDING_END;
+ ti->pending_finish = TRUE;
+ }
+
goto out;
}