summaryrefslogtreecommitdiff
path: root/driver/xf86-input-keyboard/src/kbd.c
diff options
context:
space:
mode:
authorAlexandr Shadchin <shadchin@cvs.openbsd.org>2012-08-16 16:38:05 +0000
committerAlexandr Shadchin <shadchin@cvs.openbsd.org>2012-08-16 16:38:05 +0000
commitb6b7a17ad268ae42808934ae16cca477d5bdd3b6 (patch)
tree0e2f7f56e8b572df41d15903caac4c09517fac6d /driver/xf86-input-keyboard/src/kbd.c
parentc69adad12b7e8b838ac196edd22d50eae2c09767 (diff)
Update to 1.6.2.
ok matthieu@
Diffstat (limited to 'driver/xf86-input-keyboard/src/kbd.c')
-rw-r--r--driver/xf86-input-keyboard/src/kbd.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/driver/xf86-input-keyboard/src/kbd.c b/driver/xf86-input-keyboard/src/kbd.c
index ea5480b13..2c16c86e7 100644
--- a/driver/xf86-input-keyboard/src/kbd.c
+++ b/driver/xf86-input-keyboard/src/kbd.c
@@ -38,6 +38,10 @@
#include "xf86OSKbd.h"
#include "compiler.h"
+#include "exevents.h"
+#include <X11/Xatom.h>
+#include "xserver-properties.h"
+
#include "xkbstr.h"
#include "xkbsrv.h"
@@ -328,6 +332,21 @@ KbdProc(DeviceIntPtr device, int what)
return BadValue;
}
}
+# ifdef XI_PROP_DEVICE_NODE
+ {
+ const char *device_node =
+ xf86CheckStrOption(pInfo->options, "Device", NULL);
+
+ if (device_node)
+ {
+ Atom prop_device = MakeAtom(XI_PROP_DEVICE_NODE,
+ strlen(XI_PROP_DEVICE_NODE), TRUE);
+ XIChangeDeviceProperty(device, prop_device, XA_STRING, 8,
+ PropModeReplace, strlen(device_node),
+ device_node, FALSE);
+ }
+ }
+# endif /* XI_PROP_DEVICE_NODE */
#else
{
XkbComponentNamesRec xkbnames;