summaryrefslogtreecommitdiff
blob: 7e641bf98413a470b274adb18964afdf0c31c623 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
From a1535e63935e6453301e54efbc4c13dc11995b40 Mon Sep 17 00:00:00 2001
From: Carlos Garnacho <carlosg@gnome.org>
Date: Mon, 5 Sep 2011 17:25:54 +0200
Subject: [PATCH 1/6] Xi: ensure replayed touch events have the right devices
 set

So update the event device/source to the TouchClientPtr ones
---
 Xi/exevents.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/Xi/exevents.c b/Xi/exevents.c
index 2f1a066..b8b9129 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -1625,12 +1625,16 @@ ProcessTouchOwnership(DeviceIntPtr dev, TouchPointInfoPtr ti, uint8_t reason,
                 Bool ret;
 
                 /* Deliver the saved touch begin event. */
+                ti->begin_event->device_event.deviceid = tc->device->id;
+                ti->begin_event->device_event.sourceid = tc->source->id;
                 ret = DeliverOneTouchEvent(tc, ti, ti->begin_event);
 
                 /* Deliver all the touch motion events in the ring buffer. */
                 ev = ti->first_history;
                 while (ret && ev != ti->next_history)
                 {
+                    ev->device_event.deviceid = tc->device->id;
+                    ev->device_event.sourceid = tc->source->id;
                     ret = DeliverOneTouchEvent(tc, ti, ev);
 
                     if (ev->any.type == ET_TouchEnd)
-- 
1.7.5.4