summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-06-24 11:18:10 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-07-12 16:33:48 +1000
commitba0407100fd1314feb8dc0eace4352d00709cab3 (patch)
tree7b03ade7f3aed01fce74df9876e9a5ca240aa456
parentd6439bc4c5c26577d0c839555a85bd1a9db784f3 (diff)
Add effective modifiers/group to events - require inputproto 1.9.99.13
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--configure.ac2
-rw-r--r--include/X11/extensions/XInput2.h1
-rw-r--r--src/XExtInt.c4
3 files changed, 6 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 064864f..3e6460f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -20,7 +20,7 @@ AC_PROG_SED
XORG_CWARNFLAGS
# Checks for pkg-config packages
-PKG_CHECK_MODULES(XI, [xproto >= 7.0.13] [x11 >= 1.2.99.1] [xextproto >= 7.0.3] [xext >= 1.0.99.1] [inputproto >= 1.9.99.12])
+PKG_CHECK_MODULES(XI, [xproto >= 7.0.13] [x11 >= 1.2.99.1] [xextproto >= 7.0.3] [xext >= 1.0.99.1] [inputproto >= 1.9.99.13])
XI_CFLAGS="$CWARNFLAGS $XI_CFLAGS"
AC_SUBST(XI_CFLAGS)
AC_SUBST(XI_LIBS)
diff --git a/include/X11/extensions/XInput2.h b/include/X11/extensions/XInput2.h
index 373274a..ddae30f 100644
--- a/include/X11/extensions/XInput2.h
+++ b/include/X11/extensions/XInput2.h
@@ -73,6 +73,7 @@ typedef struct
int base;
int latched;
int locked;
+ int effective;
} XIModifierState;
typedef XIModifierState XIGroupState;
diff --git a/src/XExtInt.c b/src/XExtInt.c
index 0724e4a..e1d7971 100644
--- a/src/XExtInt.c
+++ b/src/XExtInt.c
@@ -1316,9 +1316,11 @@ wireToDeviceEvent(xXIDeviceEvent *in, XGenericEventCookie* cookie)
out->mods->base = in->mods.base_mods;
out->mods->locked = in->mods.locked_mods;
out->mods->latched = in->mods.latched_mods;
+ out->mods->effective = in->mods.effective_mods;
out->group->base = in->group.base_group;
out->group->locked = in->group.locked_group;
out->group->latched = in->group.latched_group;
+ out->group->effective = in->group.effective_group;
return 1;
}
@@ -1604,9 +1606,11 @@ wireToEnterLeave(xXIEnterEvent *in, XGenericEventCookie *cookie)
out->mods->base = in->mods.base_mods;
out->mods->locked = in->mods.locked_mods;
out->mods->latched = in->mods.latched_mods;
+ out->mods->effective = in->mods.effective_mods;
out->group->base = in->group.base_group;
out->group->locked = in->group.locked_group;
out->group->latched = in->group.latched_group;
+ out->group->effective = in->group.effective_group;
out->buttons->mask_len = in->buttons_len * 4;
memcpy(out->buttons->mask, &in[1], out->buttons->mask_len);