[PATCH v2 2/2] Xi: swap touchid and grab_window in XIAllowEvents requests

Peter Hutterer peter.hutterer at who-t.net
Tue Feb 7 08:00:52 PST 2012


Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
 Xi/xiallowev.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/Xi/xiallowev.c b/Xi/xiallowev.c
index 8b88e67..3a2be42 100644
--- a/Xi/xiallowev.c
+++ b/Xi/xiallowev.c
@@ -48,12 +48,17 @@ int
 SProcXIAllowEvents(ClientPtr client)
 {
     REQUEST(xXIAllowEventsReq);
+    uint32_t *extra_data;
 
     swaps(&stuff->length);
     swaps(&stuff->deviceid);
     swapl(&stuff->time);
-    /* FIXME swap touchid */
-    /* FIXME swap window */
+    if (stuff->length > 3)
+    {
+        extra_data = (uint32_t*)&stuff[1];
+        swapl(&extra_data[0]); /* touchid */
+        swapl(&extra_data[1]); /* window */
+    }
 
     return ProcXIAllowEvents(client);
 }
-- 
1.7.7.5



More information about the xorg-devel mailing list