Added some #ifdefs HAVE_X11_XLIB_H where appropriate.

This commit is contained in:
Alexandre Julliard 2002-05-10 01:08:56 +00:00
parent 8877c6695b
commit ea69f8eeb4
8 changed files with 23 additions and 24 deletions

View File

@ -12,6 +12,7 @@
# error You must include config.h to use this header # error You must include config.h to use this header
#endif #endif
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
@ -147,7 +148,7 @@ extern int TSXUnmapWindow(Display*, Window);
extern int TSXWarpPointer(Display*, Window, Window, int, int, unsigned int, unsigned int, int, int); extern int TSXWarpPointer(Display*, Window, Window, int, int, unsigned int, unsigned int, int, int);
extern XIM TSXOpenIM(Display*, struct _XrmHashBucketRec*, char*, char*); extern XIM TSXOpenIM(Display*, struct _XrmHashBucketRec*, char*, char*);
extern int (*TSXSynchronize(Display *, Bool))(Display *); extern int (*TSXSynchronize(Display *, Bool))(Display *);
extern void TS_XInitImageFuncPtrs(XImage *);
#endif /* defined(HAVE_X11_XLIB_H) */
#endif /* __WINE_TS_XLIB_H */ #endif /* __WINE_TS_XLIB_H */

View File

@ -12,6 +12,7 @@
# error You must include config.h to use this header # error You must include config.h to use this header
#endif #endif
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
#include <X11/Xresource.h> #include <X11/Xresource.h>
@ -26,5 +27,6 @@ extern XrmDatabase TSXrmGetStringDatabase(const char*);
extern void TSXrmMergeDatabases(XrmDatabase, XrmDatabase*); extern void TSXrmMergeDatabases(XrmDatabase, XrmDatabase*);
extern void TSXrmParseCommand(XrmDatabase*, XrmOptionDescList, int, const char*, int*, char**); extern void TSXrmParseCommand(XrmDatabase*, XrmOptionDescList, int, const char*, int*, char**);
#endif /* defined(HAVE_X11_XLIB_H) */
#endif /* __WINE_TS_XRESOURCE_H */ #endif /* __WINE_TS_XRESOURCE_H */

View File

@ -12,6 +12,7 @@
# error You must include config.h to use this header # error You must include config.h to use this header
#endif #endif
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
#include <X11/Xresource.h> #include <X11/Xresource.h>
@ -56,5 +57,6 @@ extern int TSXAddPixel(struct _XImage *, long);
extern XContext TSXUniqueContext(void); extern XContext TSXUniqueContext(void);
extern int TSXDeleteContext(Display*,XID,XContext); extern int TSXDeleteContext(Display*,XID,XContext);
#endif /* defined(HAVE_X11_XLIB_H) */
#endif /* __WINE_TS_XUTIL_H */ #endif /* __WINE_TS_XUTIL_H */

View File

@ -57,8 +57,8 @@ foreach $name (@dolist) {
$x11_incl = ""; $x11_incl = "";
$extensions_dir = ""; $extensions_dir = "";
$pre_file = ""; $pre_file = "#ifdef HAVE_X11_XLIB_H\n";
$post_file = ""; $post_file = "#endif /* defined(HAVE_X11_XLIB_H) */\n";
$inc_name = $name; $inc_name = $name;
if($name eq "Xutil" || $name eq "Xresource" || $name eq "XShm") { if($name eq "Xutil" || $name eq "Xresource" || $name eq "XShm") {
$x11_incl = "#include <X11/Xlib.h>\n"; $x11_incl = "#include <X11/Xlib.h>\n";
@ -388,8 +388,6 @@ output_fn_short("XvImage *", "XvShmCreateImage", "Display*", "XvPortID", "int",
"int (*TSXSynchronize(Display *, Bool))(Display *)", "int (*TSXSynchronize(Display *, Bool))(Display *)",
"int (*TSXSynchronize(Display *a0, Bool a1))(Display *)", "int (*TSXSynchronize(Display *a0, Bool a1))(Display *)",
"a0, a1"); "a0, a1");
print OUTC "\nextern void _XInitImageFuncPtrs(XImage *);\n";
output_fn("_XInitImageFuncPtrs", "void", "XImage *", "XImage *a0", "a0");
} elsif($name eq "Xutil") { } elsif($name eq "Xutil") {
output_fn("XDestroyImage", "int", output_fn("XDestroyImage", "int",
"struct _XImage *", "struct _XImage *a0", "a0"); "struct _XImage *", "struct _XImage *a0", "a0");

View File

@ -185,7 +185,6 @@ XrmInitialize
XrmMergeDatabases XrmMergeDatabases
XrmParseCommand XrmParseCommand
XrmUniqueQuark XrmUniqueQuark
_XInitImageFuncPtrs
XF86DGAQueryExtension XF86DGAQueryExtension
XF86DGASetViewPort XF86DGASetViewPort
XF86DGAInstallColormap XF86DGAInstallColormap

View File

@ -6,6 +6,7 @@
#include "config.h" #include "config.h"
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
@ -1171,13 +1172,5 @@ int (*TSXSynchronize(Display *a0, Bool a1))(Display *)
return r; return r;
} }
extern void _XInitImageFuncPtrs(XImage *); #endif /* defined(HAVE_X11_XLIB_H) */
void TS_XInitImageFuncPtrs(XImage *a0)
{
wine_tsx11_lock();
_XInitImageFuncPtrs(a0);
wine_tsx11_unlock();
}

View File

@ -6,6 +6,7 @@
#include "config.h" #include "config.h"
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
#include <X11/Xresource.h> #include <X11/Xresource.h>
@ -63,4 +64,5 @@ void TSXrmParseCommand(XrmDatabase* a0, XrmOptionDescList a1, int a2, const ch
wine_tsx11_unlock(); wine_tsx11_unlock();
} }
#endif /* defined(HAVE_X11_XLIB_H) */

View File

@ -6,6 +6,7 @@
#include "config.h" #include "config.h"
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h> #include <X11/Xlib.h>
#include <X11/Xresource.h> #include <X11/Xresource.h>
@ -59,15 +60,6 @@ Region TSXCreateRegion(void)
return r; return r;
} }
int TSXDeleteContext(Display* a0, XID a1, XContext a2)
{
int r;
wine_tsx11_lock();
r = XDeleteContext(a0, a1, a2);
wine_tsx11_unlock();
return r;
}
int TSXDestroyRegion(Region a0) int TSXDestroyRegion(Region a0)
{ {
int r; int r;
@ -325,4 +317,14 @@ XContext TSXUniqueContext(void)
return r; return r;
} }
int TSXDeleteContext(Display*a0,XID a1,XContext a2)
{
int r;
wine_tsx11_lock();
r = XDeleteContext(a0,a1,a2);
wine_tsx11_unlock();
return r;
}
#endif /* defined(HAVE_X11_XLIB_H) */