aboutsummaryrefslogtreecommitdiff
path: root/X11/Xlibint.h
diff options
context:
space:
mode:
Diffstat (limited to 'X11/Xlibint.h')
-rw-r--r--X11/Xlibint.h121
1 files changed, 95 insertions, 26 deletions
diff --git a/X11/Xlibint.h b/X11/Xlibint.h
index 8aab764aa..2acfc7690 100644
--- a/X11/Xlibint.h
+++ b/X11/Xlibint.h
@@ -108,7 +108,7 @@ struct _XDisplay
int nscreens; /* number of screens on this server*/
Screen *screens; /* pointer to list of screens */
unsigned long motion_buffer; /* size of motion buffer */
- unsigned long flags; /* internal connection flags */
+ volatile unsigned long flags; /* internal connection flags */
int min_keycode; /* minimum defined keycode */
int max_keycode; /* maximum defined keycode */
KeySym *keysyms; /* This server's keysyms */
@@ -121,7 +121,7 @@ struct _XDisplay
struct _XExten *ext_procs; /* extensions initialized on this display */
/*
* the following can be fixed size, as the protocol defines how
- * much address space is available.
+ * much address space is available.
* While this could be done using the extension vector, there
* may be MANY events processed, so a search through the extension
* list to find the right procedure for each event might be
@@ -185,6 +185,20 @@ struct _XDisplay
struct _XkbInfoRec *xkb_info; /* XKB info */
struct _XtransConnInfo *trans_conn; /* transport connection object */
struct _X11XCBPrivate *xcb; /* XCB glue private data */
+
+ /* Generic event cookie handling */
+ unsigned int next_cookie; /* next event cookie */
+ /* vector for wire to generic event, index is (extension - 128) */
+ Bool (*generic_event_vec[128])(
+ Display * /* dpy */,
+ XGenericEventCookie * /* Xlib event */,
+ xEvent * /* wire event */);
+ /* vector for event copy, index is (extension - 128) */
+ Bool (*generic_event_copy_vec[128])(
+ Display * /* dpy */,
+ XGenericEventCookie * /* in */,
+ XGenericEventCookie * /* out*/);
+ void *cookiejar; /* cookie events returned but not claimed */
};
#define XAllocIDs(dpy,ids,n) (*(dpy)->idlist_alloc)(dpy,ids,n)
@@ -417,7 +431,7 @@ extern LockInfoPtr _Xglobal_lock;
/*
* GetReq - Get the next available X request packet in the buffer and
- * return it.
+ * return it.
*
* "name" is the name of the request, e.g. CreatePixmap, OpenFont, etc.
* "req" is the name of the request pointer.
@@ -474,9 +488,9 @@ extern LockInfoPtr _Xglobal_lock;
/*
- * GetResReq is for those requests that have a resource ID
+ * GetResReq is for those requests that have a resource ID
* (Window, Pixmap, GContext, etc.) as their single argument.
- * "rid" is the name of the resource.
+ * "rid" is the name of the resource.
*/
#if !defined(UNIXCPP) || defined(ANSICPP)
@@ -505,7 +519,7 @@ extern LockInfoPtr _Xglobal_lock;
/*
* GetEmptyReq is for those requests that have no arguments
- * at all.
+ * at all.
*/
#if !defined(UNIXCPP) || defined(ANSICPP)
#define GetEmptyReq(name, req) \
@@ -611,7 +625,7 @@ extern void _XFlushGCCache(Display *dpy, GC gc);
* "ptr" is the pointer being assigned to.
* "n" is the number of bytes to allocate.
*
- * Example:
+ * Example:
* xTextElt *elt;
* BufAlloc (xTextElt *, elt, nbytes)
*/
@@ -661,7 +675,7 @@ extern void _XRead32(
(((cs)->rbearing|(cs)->lbearing| \
(cs)->ascent|(cs)->descent) == 0))
-/*
+/*
* CI_GET_CHAR_INFO_1D - return the charinfo struct for the indicated 8bit
* character. If the character is in the column and exists, then return the
* appropriate metrics (note that fonts with common per-character metrics will
@@ -687,7 +701,7 @@ extern void _XRead32(
/*
- * CI_GET_CHAR_INFO_2D - return the charinfo struct for the indicated row and
+ * CI_GET_CHAR_INFO_2D - return the charinfo struct for the indicated row and
* column. This is used for fonts that have more than row zero.
*/
#define CI_GET_CHAR_INFO_2D(fs,row,col,def,cs) \
@@ -959,9 +973,6 @@ extern void _XGetAsyncData(
int /* datalen */,
int /* discardtotal */
);
-extern void _XSetSeqSyncFunction(
- Display* /* dpy */
-);
extern void _XFlush(
Display* /* dpy */
);
@@ -1008,6 +1019,19 @@ extern Bool _XUnknownWireEvent(
XEvent* /* re */,
xEvent* /* event */
);
+
+extern Bool _XUnknownWireEventCookie(
+ Display* /* dpy */,
+ XGenericEventCookie* /* re */,
+ xEvent* /* event */
+);
+
+extern Bool _XUnknownCopyEventCookie(
+ Display* /* dpy */,
+ XGenericEventCookie* /* in */,
+ XGenericEventCookie* /* out */
+);
+
extern Status _XUnknownNativeEvent(
Display* /* dpy */,
XEvent* /* re */,
@@ -1045,7 +1069,7 @@ extern int (*XESetCopyGC(
Display* /* display */,
GC /* gc */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, GC, XExtCodes*
);
@@ -1057,7 +1081,7 @@ extern int (*XESetFlushGC(
Display* /* display */,
GC /* gc */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, GC, XExtCodes*
);
@@ -1069,7 +1093,7 @@ extern int (*XESetFreeGC(
Display* /* display */,
GC /* gc */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, GC, XExtCodes*
);
@@ -1081,7 +1105,7 @@ extern int (*XESetCreateFont(
Display* /* display */,
XFontStruct* /* fs */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, XFontStruct*, XExtCodes*
);
@@ -1093,10 +1117,10 @@ extern int (*XESetFreeFont(
Display* /* display */,
XFontStruct* /* fs */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, XFontStruct*, XExtCodes*
-);
+);
extern int (*XESetCloseDisplay(
Display* /* display */,
@@ -1104,7 +1128,7 @@ extern int (*XESetCloseDisplay(
int (*) (
Display* /* display */,
XExtCodes* /* codes */
- ) /* proc */
+ ) /* proc */
))(
Display*, XExtCodes*
);
@@ -1117,7 +1141,7 @@ extern int (*XESetError(
xError* /* err */,
XExtCodes* /* codes */,
int* /* ret_code */
- ) /* proc */
+ ) /* proc */
))(
Display*, xError*, XExtCodes*, int*
);
@@ -1131,7 +1155,7 @@ extern char* (*XESetErrorString(
XExtCodes* /* codes */,
char* /* buffer */,
int /* nbytes */
- ) /* proc */
+ ) /* proc */
))(
Display*, int, XExtCodes*, char*, int
);
@@ -1155,11 +1179,36 @@ extern Bool (*XESetWireToEvent(
Display* /* display */,
XEvent* /* re */,
xEvent* /* event */
- ) /* proc */
+ ) /* proc */
))(
Display*, XEvent*, xEvent*
);
+extern Bool (*XESetWireToEventCookie(
+ Display* /* display */,
+ int /* extension */,
+ Bool (*) (
+ Display* /* display */,
+ XGenericEventCookie* /* re */,
+ xEvent* /* event */
+ ) /* proc */
+))(
+ Display*, XGenericEventCookie*, xEvent*
+);
+
+extern Bool (*XESetCopyEventCookie(
+ Display* /* display */,
+ int /* extension */,
+ Bool (*) (
+ Display* /* display */,
+ XGenericEventCookie* /* in */,
+ XGenericEventCookie* /* out */
+ ) /* proc */
+))(
+ Display*, XGenericEventCookie*, XGenericEventCookie*
+);
+
+
extern Status (*XESetEventToWire(
Display* /* display */,
int /* event_number */,
@@ -1167,7 +1216,7 @@ extern Status (*XESetEventToWire(
Display* /* display */,
XEvent* /* re */,
xEvent* /* event */
- ) /* proc */
+ ) /* proc */
))(
Display*, XEvent*, xEvent*
);
@@ -1179,7 +1228,7 @@ extern Bool (*XESetWireToError(
Display* /* display */,
XErrorEvent* /* he */,
xError* /* we */
- ) /* proc */
+ ) /* proc */
))(
Display*, XErrorEvent*, xError*
);
@@ -1192,7 +1241,7 @@ extern void (*XESetBeforeFlush(
XExtCodes* /* codes */,
_Xconst char* /* data */,
long /* len */
- ) /* proc */
+ ) /* proc */
))(
Display*, XExtCodes*, _Xconst char*, long
);
@@ -1321,9 +1370,29 @@ Status _XGetWindowAttributes(
XWindowAttributes *attr);
int _XPutBackEvent (
- register Display *dpy,
+ register Display *dpy,
register XEvent *event);
+extern Bool _XIsEventCookie(
+ Display *dpy,
+ XEvent *ev);
+
+extern void _XFreeEventCookies(
+ Display *dpy);
+
+extern void _XStoreEventCookie(
+ Display *dpy,
+ XEvent *ev);
+
+extern Bool _XFetchEventCookie(
+ Display *dpy,
+ XGenericEventCookie *ev);
+
+extern Bool _XCopyEventCookie(
+ Display *dpy,
+ XGenericEventCookie *in,
+ XGenericEventCookie *out);
+
_XFUNCPROTOEND
#endif /* _XLIBINT_H_ */