summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2011-09-14 22:33:57 -0700
committerPeter Hutterer <peter.hutterer@who-t.net>2011-12-21 15:32:05 +1000
commite73e2fe95dab3e0048b24d16327adbe54326ff3f (patch)
tree8189d07cfc14fd6eabbfc343faa1157a665e9bad /include
parent7888d14a499062a1c3b333f31f1330cecf1e97c1 (diff)
Implement support for XI 2.2
Adds support for the new TouchClass for multitouch-capable servers/devices. New events: XITouchOwnershipEvent New event types handled: XITouchBegin, XITouchUpdate, XITouchEnd XIRawTouchBegin, XIRawTouchUpdate, XIRawTouchEnd New functions: XIGrabTouchBegin ... passive grabs on touches XIUngrabTouchBegin XIAllowTouchEvents ... Allow/reject touch event sequences New XIQueryDevice classes: XITouchClassInfo Requires libX11 1.5 for GetReqSized Co-authored by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'include')
-rw-r--r--include/X11/extensions/XInput2.h51
1 files changed, 51 insertions, 0 deletions
diff --git a/include/X11/extensions/XInput2.h b/include/X11/extensions/XInput2.h
index 910b25f..26de695 100644
--- a/include/X11/extensions/XInput2.h
+++ b/include/X11/extensions/XInput2.h
@@ -146,6 +146,14 @@ typedef struct
typedef struct
{
+ int type;
+ int sourceid;
+ int mode;
+ int num_touches;
+} XITouchClassInfo;
+
+typedef struct
+{
int deviceid;
char *name;
int use;
@@ -303,6 +311,23 @@ typedef struct {
int what;
} XIPropertyEvent;
+typedef struct {
+ int type; /* GenericEvent */
+ unsigned long serial; /* # of last request processed by server */
+ Bool send_event; /* true if this came from a SendEvent request */
+ Display *display; /* Display the event was read from */
+ int extension; /* XI extension offset */
+ int evtype;
+ Time time;
+ int deviceid;
+ int sourceid;
+ unsigned int touchid;
+ Window root;
+ Window event;
+ Window child;
+ int flags;
+} XITouchOwnershipEvent;
+
_XFUNCPROTOBEGIN
extern Bool XIQueryPointer(
@@ -426,6 +451,14 @@ extern Status XIAllowEvents(
Time time
);
+extern Status XIAllowTouchEvents(
+ Display* display,
+ int deviceid,
+ unsigned int touchid,
+ Window grab_window,
+ int event_mode
+);
+
extern int XIGrabButton(
Display* display,
int deviceid,
@@ -477,6 +510,17 @@ extern int XIGrabFocusIn(
int num_modifiers,
XIGrabModifiers *modifiers_inout
);
+
+extern int XIGrabTouchBegin(
+ Display* display,
+ int deviceid,
+ Window grab_window,
+ int owner_events,
+ XIEventMask *mask,
+ int num_modifiers,
+ XIGrabModifiers *modifiers_inout
+);
+
extern Status XIUngrabButton(
Display* display,
int deviceid,
@@ -511,6 +555,13 @@ extern Status XIUngrabFocusIn(
XIGrabModifiers *modifiers
);
+extern Status XIUngrabTouchBegin(
+ Display* display,
+ int deviceid,
+ Window grab_window,
+ int num_modifiers,
+ XIGrabModifiers *modifiers
+);
extern Atom *XIListProperties(
Display* display,