summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPeter Hutterer <peter@cs.unisa.edu.au>2007-07-06 15:43:08 +0930
committerPeter Hutterer <peter@cs.unisa.edu.au>2007-07-06 15:43:08 +0930
commit5ccc09b18244f91a06b3bea20b02a97280d1a229 (patch)
tree485d8f1818f2f42490c79ed252e38eec05c06f6a /include
parentc1a16bdcfe7aa907fe78f27dc606a8e5a2699952 (diff)
Use the same struct for generic event masks throughout the code.
Renaming those structs too. Previously grabs were using a different struct than windows, which was reasonably stupid.
Diffstat (limited to 'include')
-rw-r--r--include/dix.h1
-rw-r--r--include/inputstr.h9
-rw-r--r--include/misc.h1
-rw-r--r--include/windowstr.h22
4 files changed, 13 insertions, 20 deletions
diff --git a/include/dix.h b/include/dix.h
index be1cb95f2..2fc625438 100644
--- a/include/dix.h
+++ b/include/dix.h
@@ -52,6 +52,7 @@ SOFTWARE.
#include "window.h"
#include "input.h"
#include "cursor.h"
+#include "geext.h"
#include <X11/extensions/XI.h>
#define EARLIER -1
diff --git a/include/inputstr.h b/include/inputstr.h
index d9128cce8..6c65aa46d 100644
--- a/include/inputstr.h
+++ b/include/inputstr.h
@@ -53,6 +53,7 @@ SOFTWARE.
#include "window.h"
#include "dixstruct.h"
#include "cursorstr.h"
+#include "geext.h"
#define BitIsOn(ptr, bit) (((BYTE *) (ptr))[(bit)>>3] & (1 << ((bit) & 7)))
@@ -102,12 +103,6 @@ typedef struct _DetailRec { /* Grab details may be bit masks */
Mask *pMask;
} DetailRec;
-typedef struct _GenericMaskRec {
- int extension;
- Mask mask;
- struct _GenericMaskRec* next;
-} GenericMaskRec;
-
/**
* Central struct for device grabs.
* The same struct is used for both core grabs and device grabs, with
@@ -139,7 +134,7 @@ typedef struct _GrabRec {
CursorPtr cursor; /* always NULL for keyboards */
Mask eventMask;
Mask deviceMask;
- GenericMaskPtr genericMasks; /* null terminated list */
+ GenericMaskPtr genericMasks;
} GrabRec;
typedef struct _KeyClassRec {
diff --git a/include/misc.h b/include/misc.h
index 14c848d1c..e6a5e9eb2 100644
--- a/include/misc.h
+++ b/include/misc.h
@@ -243,7 +243,6 @@ typedef struct pixman_box16 *BoxPtr;
typedef struct _xEvent *xEventPtr;
typedef struct _xRectangle *xRectanglePtr;
typedef struct _GrabRec *GrabPtr;
-typedef struct _GenericMaskRec *GenericMaskPtr;
/* typedefs from other places - duplicated here to minimize the amount
* of unnecessary junk that one would normally have to include to get
diff --git a/include/windowstr.h b/include/windowstr.h
index a1d501d37..959ea0ec1 100644
--- a/include/windowstr.h
+++ b/include/windowstr.h
@@ -77,17 +77,15 @@ typedef struct _DevCursorNode {
struct _DevCursorNode* next;
} DevCursNodeRec, *DevCursNodePtr, *DevCursorList;
-typedef struct _GEClientRec {
- Mask eventMask[MAXEXTENSIONS];
- ClientPtr client;
- struct _GEClientRec* next;
-} GEClientRec, *GEClientPtr;
-
-/* Mask structure for GE extension. Allows one mask per extension. */
-typedef struct _GEEventMasks {
- Mask eventMasks[MAXEXTENSIONS];
- struct _GEClientRec* geClients;
-} GEEventMasksRec, *GEEventMasksPtr;
+/* Mask structure for GE extension as stored on the window.
+ * Allows one mask per extension.
+ * .eventMask - Summary mask for all clients, used for quick checking.
+ * .geClients - list of clients with their specific mask.
+ */
+typedef struct _GenericClientMasks {
+ Mask eventMasks[MAXEXTENSIONS];
+ GenericMaskPtr geClients;
+} GenericClientMasksRec, *GenericClientMasksPtr;
typedef struct _WindowAccessRec {
int defaultRule; /* WindowAccessDenyAll */
@@ -117,7 +115,7 @@ typedef struct _WindowOpt {
struct _OtherInputMasks *inputMasks; /* default: NULL */
#endif
DevCursorList deviceCursors; /* default: NULL */
- struct _GEEventMasks* geMasks; /* default: NULL */
+ struct _GenericClientMasks *geMasks;/* default: NULL */
WindowAccessRec access;
} WindowOptRec, *WindowOptPtr;