ts_xutil.c 9.62 KB
Newer Older
Alexandre Julliard's avatar
Alexandre Julliard committed
1 2 3
/*
 * Thread safe wrappers around Xutil calls.
 * This file was generated automatically by tools/make_X11wrappers
Alexandre Julliard's avatar
Alexandre Julliard committed
4
 * DO NOT EDIT!
Alexandre Julliard's avatar
Alexandre Julliard committed
5 6
 */

7 8 9 10 11
#include "config.h"

#ifndef X_DISPLAY_MISSING


Alexandre Julliard's avatar
Alexandre Julliard committed
12 13 14
#include <X11/Xlib.h>
#include <X11/Xresource.h>
#include <X11/Xutil.h>
15

16
#include "debugtools.h"
17
#include "ts_xutil.h"
18
#include "x11drv.h"
Alexandre Julliard's avatar
Alexandre Julliard committed
19

20 21
DEFAULT_DEBUG_CHANNEL(x11)

Alexandre Julliard's avatar
Alexandre Julliard committed
22 23 24
XClassHint * TSXAllocClassHint(void)
{
  XClassHint * r;
25
  TRACE("Call XAllocClassHint\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
26
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
27
  r = XAllocClassHint();
Alexandre Julliard's avatar
Alexandre Julliard committed
28
  LeaveCriticalSection( &X11DRV_CritSection );
29
  TRACE("Ret XAllocClassHint\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
30 31 32 33 34 35
  return r;
}

XSizeHints * TSXAllocSizeHints(void)
{
  XSizeHints * r;
36
  TRACE("Call XAllocSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
37
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
38
  r = XAllocSizeHints();
Alexandre Julliard's avatar
Alexandre Julliard committed
39
  LeaveCriticalSection( &X11DRV_CritSection );
40
  TRACE("Ret XAllocSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
41 42 43 44 45 46
  return r;
}

XWMHints * TSXAllocWMHints(void)
{
  XWMHints * r;
47
  TRACE("Call XAllocWMHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
48
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
49
  r = XAllocWMHints();
Alexandre Julliard's avatar
Alexandre Julliard committed
50
  LeaveCriticalSection( &X11DRV_CritSection );
51
  TRACE("Ret XAllocWMHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
52 53 54 55 56 57
  return r;
}

int  TSXClipBox(Region a0, XRectangle* a1)
{
  int  r;
58
  TRACE("Call XClipBox\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
59
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
60
  r = XClipBox(a0, a1);
Alexandre Julliard's avatar
Alexandre Julliard committed
61
  LeaveCriticalSection( &X11DRV_CritSection );
62
  TRACE("Ret XClipBox\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
63 64 65 66 67 68
  return r;
}

Region  TSXCreateRegion(void)
{
  Region  r;
69
  TRACE("Call XCreateRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
70
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
71
  r = XCreateRegion();
Alexandre Julliard's avatar
Alexandre Julliard committed
72
  LeaveCriticalSection( &X11DRV_CritSection );
73
  TRACE("Ret XCreateRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
74 75 76 77 78 79
  return r;
}

int  TSXDeleteContext(Display* a0, XID a1, XContext a2)
{
  int  r;
80
  TRACE("Call XDeleteContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
81
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
82
  r = XDeleteContext(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
83
  LeaveCriticalSection( &X11DRV_CritSection );
84
  TRACE("Ret XDeleteContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
85 86 87 88 89 90
  return r;
}

int  TSXDestroyRegion(Region a0)
{
  int  r;
91
  TRACE("Call XDestroyRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
92
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
93
  r = XDestroyRegion(a0);
Alexandre Julliard's avatar
Alexandre Julliard committed
94
  LeaveCriticalSection( &X11DRV_CritSection );
95
  TRACE("Ret XDestroyRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
96 97 98 99 100 101
  return r;
}

int  TSXEmptyRegion(Region a0)
{
  int  r;
102
  TRACE("Call XEmptyRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
103
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
104
  r = XEmptyRegion(a0);
Alexandre Julliard's avatar
Alexandre Julliard committed
105
  LeaveCriticalSection( &X11DRV_CritSection );
106
  TRACE("Ret XEmptyRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
107 108 109 110 111 112
  return r;
}

int  TSXEqualRegion(Region a0, Region a1)
{
  int  r;
113
  TRACE("Call XEqualRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
114
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
115
  r = XEqualRegion(a0, a1);
Alexandre Julliard's avatar
Alexandre Julliard committed
116
  LeaveCriticalSection( &X11DRV_CritSection );
117
  TRACE("Ret XEqualRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
118 119 120 121 122 123
  return r;
}

int  TSXFindContext(Display* a0, XID a1, XContext a2, XPointer* a3)
{
  int  r;
124
  TRACE("Call XFindContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
125
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
126
  r = XFindContext(a0, a1, a2, a3);
Alexandre Julliard's avatar
Alexandre Julliard committed
127
  LeaveCriticalSection( &X11DRV_CritSection );
128
  TRACE("Ret XFindContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
129 130 131
  return r;
}

Alexandre Julliard's avatar
Alexandre Julliard committed
132 133 134
XVisualInfo * TSXGetVisualInfo(Display* a0, long a1, XVisualInfo* a2, int* a3)
{
  XVisualInfo * r;
135
  TRACE("Call XGetVisualInfo\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
136 137 138
  EnterCriticalSection( &X11DRV_CritSection );
  r = XGetVisualInfo(a0, a1, a2, a3);
  LeaveCriticalSection( &X11DRV_CritSection );
139
  TRACE("Ret XGetVisualInfo\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
140 141 142
  return r;
}

Alexandre Julliard's avatar
Alexandre Julliard committed
143 144 145
int   TSXGetWMSizeHints(Display* a0, Window a1, XSizeHints* a2, long* a3, Atom a4)
{
  int   r;
146
  TRACE("Call XGetWMSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
147
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
148
  r = XGetWMSizeHints(a0, a1, a2, a3, a4);
Alexandre Julliard's avatar
Alexandre Julliard committed
149
  LeaveCriticalSection( &X11DRV_CritSection );
150
  TRACE("Ret XGetWMSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
151 152 153 154 155 156
  return r;
}

int  TSXIntersectRegion(Region a0, Region a1, Region a2)
{
  int  r;
157
  TRACE("Call XIntersectRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
158
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
159
  r = XIntersectRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
160
  LeaveCriticalSection( &X11DRV_CritSection );
161
  TRACE("Ret XIntersectRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
162 163 164 165 166 167
  return r;
}

int  TSXLookupString(XKeyEvent* a0, char* a1, int a2, KeySym* a3, XComposeStatus* a4)
{
  int  r;
168
  TRACE("Call XLookupString\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
169
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
170
  r = XLookupString(a0, a1, a2, a3, a4);
Alexandre Julliard's avatar
Alexandre Julliard committed
171
  LeaveCriticalSection( &X11DRV_CritSection );
172
  TRACE("Ret XLookupString\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
173 174 175 176 177 178
  return r;
}

int  TSXOffsetRegion(Region a0, int a1, int a2)
{
  int  r;
179
  TRACE("Call XOffsetRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
180
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
181
  r = XOffsetRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
182
  LeaveCriticalSection( &X11DRV_CritSection );
183
  TRACE("Ret XOffsetRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
184 185 186 187 188 189
  return r;
}

int   TSXPointInRegion(Region a0, int a1, int a2)
{
  int   r;
190
  TRACE("Call XPointInRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
191
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
192
  r = XPointInRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
193
  LeaveCriticalSection( &X11DRV_CritSection );
194
  TRACE("Ret XPointInRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
195 196 197 198 199 200
  return r;
}

Region  TSXPolygonRegion(XPoint* a0, int a1, int a2)
{
  Region  r;
201
  TRACE("Call XPolygonRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
202
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
203
  r = XPolygonRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
204
  LeaveCriticalSection( &X11DRV_CritSection );
205
  TRACE("Ret XPolygonRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
206 207 208 209 210 211
  return r;
}

int  TSXRectInRegion(Region a0, int a1, int a2, unsigned int a3, unsigned int a4)
{
  int  r;
212
  TRACE("Call XRectInRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
213
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
214
  r = XRectInRegion(a0, a1, a2, a3, a4);
Alexandre Julliard's avatar
Alexandre Julliard committed
215
  LeaveCriticalSection( &X11DRV_CritSection );
216
  TRACE("Ret XRectInRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
217 218 219 220 221 222
  return r;
}

int  TSXSaveContext(Display* a0, XID a1, XContext a2, const  char* a3)
{
  int  r;
223
  TRACE("Call XSaveContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
224
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
225
  r = XSaveContext(a0, a1, a2, a3);
Alexandre Julliard's avatar
Alexandre Julliard committed
226
  LeaveCriticalSection( &X11DRV_CritSection );
227
  TRACE("Ret XSaveContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
228 229 230
  return r;
}

231 232 233
int  TSXSetClassHint(Display* a0, Window a1, XClassHint* a2)
{
  int  r;
234
  TRACE("Call XSetClassHint\n");
235 236 237
  EnterCriticalSection( &X11DRV_CritSection );
  r = XSetClassHint(a0, a1, a2);
  LeaveCriticalSection( &X11DRV_CritSection );
238
  TRACE("Ret XSetClassHint\n");
239 240 241
  return r;
}

242 243 244
int  TSXSetWMHints(Display* a0, Window a1, XWMHints* a2)
{
  int  r;
245
  TRACE("Call XSetWMHints\n");
246 247 248
  EnterCriticalSection( &X11DRV_CritSection );
  r = XSetWMHints(a0, a1, a2);
  LeaveCriticalSection( &X11DRV_CritSection );
249
  TRACE("Ret XSetWMHints\n");
250 251 252
  return r;
}

Alexandre Julliard's avatar
Alexandre Julliard committed
253 254
void  TSXSetWMProperties(Display* a0, Window a1, XTextProperty* a2, XTextProperty* a3, char** a4, int a5, XSizeHints* a6, XWMHints* a7, XClassHint* a8)
{
255
  TRACE("Call XSetWMProperties\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
256
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
257
  XSetWMProperties(a0, a1, a2, a3, a4, a5, a6, a7, a8);
Alexandre Julliard's avatar
Alexandre Julliard committed
258
  LeaveCriticalSection( &X11DRV_CritSection );
259
  TRACE("Ret XSetWMProperties\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
260 261 262 263
}

void  TSXSetWMSizeHints(Display* a0, Window a1, XSizeHints* a2, Atom a3)
{
264
  TRACE("Call XSetWMSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
265
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
266
  XSetWMSizeHints(a0, a1, a2, a3);
Alexandre Julliard's avatar
Alexandre Julliard committed
267
  LeaveCriticalSection( &X11DRV_CritSection );
268
  TRACE("Ret XSetWMSizeHints\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
269 270 271 272 273
}

int  TSXSetRegion(Display* a0, GC a1, Region a2)
{
  int  r;
274
  TRACE("Call XSetRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
275
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
276
  r = XSetRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
277
  LeaveCriticalSection( &X11DRV_CritSection );
278
  TRACE("Ret XSetRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
279 280 281 282 283 284
  return r;
}

int  TSXShrinkRegion(Region a0, int a1, int a2)
{
  int  r;
285
  TRACE("Call XShrinkRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
286
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
287
  r = XShrinkRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
288
  LeaveCriticalSection( &X11DRV_CritSection );
289
  TRACE("Ret XShrinkRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
290 291 292 293 294 295
  return r;
}

int   TSXStringListToTextProperty(char** a0, int a1, XTextProperty* a2)
{
  int   r;
296
  TRACE("Call XStringListToTextProperty\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
297
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
298
  r = XStringListToTextProperty(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
299
  LeaveCriticalSection( &X11DRV_CritSection );
300
  TRACE("Ret XStringListToTextProperty\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
301 302 303 304 305 306
  return r;
}

int  TSXSubtractRegion(Region a0, Region a1, Region a2)
{
  int  r;
307
  TRACE("Call XSubtractRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
308
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
309
  r = XSubtractRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
310
  LeaveCriticalSection( &X11DRV_CritSection );
311
  TRACE("Ret XSubtractRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
312 313 314 315 316 317
  return r;
}

int  TSXUnionRectWithRegion(XRectangle* a0, Region a1, Region a2)
{
  int  r;
318
  TRACE("Call XUnionRectWithRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
319
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
320
  r = XUnionRectWithRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
321
  LeaveCriticalSection( &X11DRV_CritSection );
322
  TRACE("Ret XUnionRectWithRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
323 324 325 326 327 328
  return r;
}

int  TSXUnionRegion(Region a0, Region a1, Region a2)
{
  int  r;
329
  TRACE("Call XUnionRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
330
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
331
  r = XUnionRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
332
  LeaveCriticalSection( &X11DRV_CritSection );
333
  TRACE("Ret XUnionRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
334 335 336 337 338 339
  return r;
}

int  TSXXorRegion(Region a0, Region a1, Region a2)
{
  int  r;
340
  TRACE("Call XXorRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
341
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
342
  r = XXorRegion(a0, a1, a2);
Alexandre Julliard's avatar
Alexandre Julliard committed
343
  LeaveCriticalSection( &X11DRV_CritSection );
344
  TRACE("Ret XXorRegion\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
345 346 347 348 349 350
  return r;
}

int TSXDestroyImage(struct _XImage *a0)
{
  int r;
351
  TRACE("Call XDestroyImage\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
352
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
353
  r = XDestroyImage(a0);
Alexandre Julliard's avatar
Alexandre Julliard committed
354
  LeaveCriticalSection( &X11DRV_CritSection );
355
  TRACE("Ret XDestroyImage\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
356 357 358 359 360 361
  return r;
}

struct _XImage * TSXSubImage(struct _XImage *a0, int a1, int a2, unsigned int a3, unsigned int a4)
{
  struct _XImage * r;
362
  TRACE("Call XSubImage\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
363
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
364
  r = XSubImage(a0, a1, a2, a3, a4);
Alexandre Julliard's avatar
Alexandre Julliard committed
365
  LeaveCriticalSection( &X11DRV_CritSection );
366
  TRACE("Ret XSubImage\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
367 368 369 370 371 372
  return r;
}

int TSXAddPixel(struct _XImage *a0, long a1)
{
  int r;
373
  TRACE("Call XAddPixel\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
374
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
375
  r = XAddPixel(a0, a1);
Alexandre Julliard's avatar
Alexandre Julliard committed
376
  LeaveCriticalSection( &X11DRV_CritSection );
377
  TRACE("Ret XAddPixel\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
378 379 380 381 382 383
  return r;
}

XContext TSXUniqueContext(void)
{
  XContext r;
384
  TRACE("Call XUniqueContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
385
  EnterCriticalSection( &X11DRV_CritSection );
Alexandre Julliard's avatar
Alexandre Julliard committed
386
  r = XUniqueContext();
Alexandre Julliard's avatar
Alexandre Julliard committed
387
  LeaveCriticalSection( &X11DRV_CritSection );
388
  TRACE("Ret XUniqueContext\n");
Alexandre Julliard's avatar
Alexandre Julliard committed
389 390
  return r;
}
Alexandre Julliard's avatar
Alexandre Julliard committed
391

392 393

#endif /* !defined(X_DISPLAY_MISSING) */