[PATCH xinput] Only try to print XIPointerEmulated flag if it is defined.
Peter Hutterer
peter.hutterer at who-t.net
Tue Aug 23 14:51:44 PDT 2011
This flag is part of the future (currently unreleased) XI 2.1 protocol.
Introduced in 2c5187d0099e6c7588828ba9931d27f5c64bbaec
Reported-by: Chris Ball <cjb at laptop.org>
Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
src/test_xi2.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/test_xi2.c b/src/test_xi2.c
index 92c88da..a2cd5d6 100644
--- a/src/test_xi2.c
+++ b/src/test_xi2.c
@@ -53,11 +53,13 @@ static void print_deviceevent(XIDeviceEvent* event)
case XI_KeyRelease:
printf(" flags: %s\n", (event->flags & XIKeyRepeat) ? "repeat" : "");
break;
+#ifdef XIPointerEmulated
case XI_ButtonPress:
case XI_ButtonRelease:
case XI_Motion:
printf(" flags: %s\n", (event->flags & XIPointerEmulated) ? "emulated" : "");
break;
+#endif
}
printf(" root: %.2f/%.2f\n", event->root_x, event->root_y);
--
1.7.6
More information about the xorg-devel
mailing list