blob: a8c9a670b4a0668765f7108788201eddb338ccc7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
/* Copyright (C) 2003-2006 Jamey Sharp, Josh Triplett
* This file is licensed under the MIT license. See the file COPYING. */
#ifndef XXCBINT_H
#define XXCBINT_H
#include <assert.h>
#include <stdint.h>
#include <X11/Xlibint.h>
#ifdef WIN32
#include <X11/Xwindows.h>
#endif
#include <X11/Xlib-xcb.h>
#include "locking.h"
#define XLIB_SEQUENCE_COMPARE(a,op,b) (((long) (a) - (long) (b)) op 0)
typedef struct PendingRequest PendingRequest;
struct PendingRequest {
PendingRequest *next;
unsigned long sequence;
unsigned reply_waiter;
};
typedef struct _X11XCBPrivate {
xcb_connection_t *connection;
PendingRequest *pending_requests;
PendingRequest *pending_requests_tail;
xcb_generic_event_t *next_event;
char *real_bufmax;
char *reply_data;
int reply_length;
int reply_consumed;
uint64_t last_flushed;
enum XEventQueueOwner event_owner;
XID next_xid;
/* handle simultaneous threads waiting for responses */
xcondition_t event_notify;
int event_waiter;
xcondition_t reply_notify;
} _X11XCBPrivate;
/* xcb_disp.c */
int _XConnectXCB(Display *dpy, _Xconst char *display, int *screenp);
void _XFreeX11XCBStructure(Display *dpy);
#endif /* XXCBINT_H */
|