hw/xwin: Consistently use BOOL type from Xmd.h

This avoids including Xdefs.h, which means we avoid all the issues with
_XSERVER64 effecting how types are defined by that.
This commit is contained in:
Jon Turney 2018-07-02 17:25:53 +01:00
parent 4055fed1e7
commit f269e01e1a
7 changed files with 17 additions and 17 deletions

View File

@ -77,7 +77,7 @@ GenerateAuthorization(unsigned name_length,
* Generate authorization cookie for internal server clients * Generate authorization cookie for internal server clients
*/ */
Bool BOOL
winGenerateAuthorization(void) winGenerateAuthorization(void)
{ {
#ifdef XCSECURITY #ifdef XCSECURITY

View File

@ -20,7 +20,7 @@
*/ */
#include <xcb/xcb.h> #include <xcb/xcb.h>
#include <X11/Xdefs.h> // for Bool #include <X11/Xmd.h> // for BOOL
Bool winGenerateAuthorization(void); BOOL winGenerateAuthorization(void);
xcb_auth_info_t * winGetXcbAuthInfo(void); xcb_auth_info_t * winGetXcbAuthInfo(void);

View File

@ -33,7 +33,7 @@
#include <xcb/xproto.h> #include <xcb/xproto.h>
#include <X11/Xfuncproto.h> // for _X_ATTRIBUTE_PRINTF #include <X11/Xfuncproto.h> // for _X_ATTRIBUTE_PRINTF
#include <X11/Xdefs.h> // for Bool type #include <X11/Xmd.h> // for BOOL
/* Windows headers */ /* Windows headers */
#include <X11/Xwindows.h> #include <X11/Xwindows.h>
@ -82,7 +82,7 @@ typedef struct
* winclipboardwndproc.c * winclipboardwndproc.c
*/ */
Bool winClipboardFlushWindowsMessageQueue(HWND hwnd); BOOL winClipboardFlushWindowsMessageQueue(HWND hwnd);
LRESULT CALLBACK LRESULT CALLBACK
winClipboardWindowProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); winClipboardWindowProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam);

View File

@ -103,7 +103,7 @@ intern_atom(xcb_connection_t *conn, const char *atomName)
* returns TRUE if shutdown was signalled to loop, FALSE if some error occurred * returns TRUE if shutdown was signalled to loop, FALSE if some error occurred
*/ */
Bool BOOL
winClipboardProc(char *szDisplay, xcb_auth_info_t *auth_info) winClipboardProc(char *szDisplay, xcb_auth_info_t *auth_info)
{ {
ClipboardAtoms atoms; ClipboardAtoms atoms;
@ -120,7 +120,7 @@ winClipboardProc(char *szDisplay, xcb_auth_info_t *auth_info)
xcb_connection_t *conn; xcb_connection_t *conn;
xcb_window_t iWindow = XCB_NONE; xcb_window_t iWindow = XCB_NONE;
int iSelectError; int iSelectError;
Bool fShutdown = FALSE; BOOL fShutdown = FALSE;
ClipboardConversionData data; ClipboardConversionData data;
int screen; int screen;

View File

@ -27,15 +27,15 @@
#ifndef WINCLIPBOARD_H #ifndef WINCLIPBOARD_H
#define WINCLIPBOARD_H #define WINCLIPBOARD_H
#include <X11/Xdefs.h> // for Bool type
#include <xcb/xcb.h> #include <xcb/xcb.h>
#include <X11/Xmd.h> // for BOOL type
Bool winClipboardProc(char *szDisplay, xcb_auth_info_t *auth_info); BOOL winClipboardProc(char *szDisplay, xcb_auth_info_t *auth_info);
void winFixClipboardChain(void); void winFixClipboardChain(void);
void winClipboardWindowDestroy(void); void winClipboardWindowDestroy(void);
extern Bool fPrimarySelection; extern BOOL fPrimarySelection;
#endif #endif

View File

@ -131,7 +131,7 @@ winClipboardWindowProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
static xcb_connection_t *conn; static xcb_connection_t *conn;
static xcb_window_t iWindow; static xcb_window_t iWindow;
static ClipboardAtoms *atoms; static ClipboardAtoms *atoms;
static Bool fRunning; static BOOL fRunning;
/* Branch on message type */ /* Branch on message type */
switch (message) { switch (message) {
@ -310,7 +310,7 @@ winClipboardWindowProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
case WM_RENDERFORMAT: case WM_RENDERFORMAT:
{ {
int iReturn; int iReturn;
Bool pasted = FALSE; BOOL pasted = FALSE;
xcb_atom_t selection; xcb_atom_t selection;
ClipboardConversionData data; ClipboardConversionData data;
int best_target = 0; int best_target = 0;
@ -440,7 +440,7 @@ winClipboardWindowProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
* Process any pending Windows messages * Process any pending Windows messages
*/ */
Bool BOOL
winClipboardFlushWindowsMessageQueue(HWND hwnd) winClipboardFlushWindowsMessageQueue(HWND hwnd)
{ {
MSG msg; MSG msg;

View File

@ -59,7 +59,7 @@
*/ */
extern int xfixes_event_base; extern int xfixes_event_base;
Bool fPrimarySelection = TRUE; BOOL fPrimarySelection = TRUE;
/* /*
* Local variables * Local variables
@ -198,7 +198,7 @@ winClipboardSelectionNotifyData(HWND hwnd, xcb_window_t iWindow, xcb_connection_
xcb_atom_t xtpText_encoding; xcb_atom_t xtpText_encoding;
int xtpText_nitems; int xtpText_nitems;
Bool fSetClipboardData = TRUE; BOOL fSetClipboardData = TRUE;
char *pszReturnData = NULL; char *pszReturnData = NULL;
UINT codepage; UINT codepage;
wchar_t *pwszUnicodeStr = NULL; wchar_t *pwszUnicodeStr = NULL;
@ -403,8 +403,8 @@ winClipboardFlushXEvents(HWND hwnd,
const char *pszGlobalData = NULL; const char *pszGlobalData = NULL;
HGLOBAL hGlobal = NULL; HGLOBAL hGlobal = NULL;
char *pszConvertData = NULL; char *pszConvertData = NULL;
Bool fAbort = FALSE; BOOL fAbort = FALSE;
Bool fCloseClipboard = FALSE; BOOL fCloseClipboard = FALSE;
/* Branch on the event type */ /* Branch on the event type */
switch (event->response_type & ~0x80) { switch (event->response_type & ~0x80) {