summaryrefslogtreecommitdiff
path: root/XI2proto.h
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-04-10 17:31:05 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-04-19 22:28:57 +1000
commit8914a9a2a99e334f66d6040d05b3d5f5b603780f (patch)
tree485fbded8fe50df1822e41f0745c3fd9d38387cc /XI2proto.h
parent1956df7e45a49464dee2d7beff36f38ea00e9cb8 (diff)
Add GrabDevice and UngrabDevice XI2 requests.
Diffstat (limited to 'XI2proto.h')
-rw-r--r--XI2proto.h57
1 files changed, 56 insertions, 1 deletions
diff --git a/XI2proto.h b/XI2proto.h
index 0a2c2a3..58873bb 100644
--- a/XI2proto.h
+++ b/XI2proto.h
@@ -55,8 +55,10 @@
#define X_XIQueryDevice 48
#define X_XISetDeviceFocus 49
#define X_XIGetDeviceFocus 50
+#define X_XIGrabDevice 51
+#define X_XIUngrabDevice 52
-#define XI2REQUESTS (X_XIGetDeviceFocus - X_XIQueryDevicePointer + 1)
+#define XI2REQUESTS (X_XIUngrabDevice - X_XIQueryDevicePointer + 1)
#define XI2EVENTS (XI_LASTEVENT + 1)
/*************************************************************************************
@@ -488,6 +490,59 @@ typedef struct {
} xXIGetDeviceFocusReply;
#define sz_xXIGetDeviceFocusReply 32
+
+/**********************************************************
+ *
+ * GrabDevice
+ *
+ */
+typedef struct {
+ uint8_t reqType;
+ uint8_t ReqType; /* Always X_XIGrabDevice */
+ uint16_t length;
+ Window grab_window;
+ Time time;
+ Cursor cursor;
+ uint16_t deviceid;
+ uint8_t grab_mode;
+ uint8_t paired_device_mode;
+ uint8_t owner_events;
+ uint8_t pad;
+ uint16_t mask_len;
+} xXIGrabDeviceReq;
+#define sz_xXIGrabDeviceReq 24
+
+typedef struct {
+ uint8_t repType; /* input extension major opcode */
+ uint8_t RepType; /* Always X_XIGrabDevice */
+ uint16_t sequenceNumber;
+ uint32_t length;
+ uint8_t status;
+ uint8_t pad0;
+ uint16_t pad1;
+ uint32_t pad2;
+ uint32_t pad3;
+ uint32_t pad4;
+ uint32_t pad5;
+ uint32_t pad6;
+} xXIGrabDeviceReply;
+#define sz_xXIGrabDeviceReply 32
+
+/**********************************************************
+ *
+ * UngrabDevice
+ *
+ */
+typedef struct {
+ uint8_t reqType;
+ uint8_t ReqType; /* Always X_XIUngrabDevice */
+ uint16_t length;
+ Time time;
+ uint16_t deviceid;
+ uint16_t pad;
+} xXIUngrabDeviceReq;
+#define sz_xXIUngrabDeviceReq 12
+
/*************************************************************************************
* *
* EVENTS *