You can't have an empty union in the structure...
This commit is contained in:
parent
9d25ba272a
commit
d257c63c2f
1 changed files with 14 additions and 16 deletions
|
@ -125,28 +125,27 @@ struct SDL_SysWMmsg
|
||||||
WPARAM wParam; /**< WORD message parameter */
|
WPARAM wParam; /**< WORD message parameter */
|
||||||
LPARAM lParam; /**< LONG message parameter */
|
LPARAM lParam; /**< LONG message parameter */
|
||||||
} win;
|
} win;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_X11)
|
||||||
#if defined(SDL_VIDEO_DRIVER_X11)
|
|
||||||
struct {
|
struct {
|
||||||
XEvent event;
|
XEvent event;
|
||||||
} x11;
|
} x11;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_DIRECTFB)
|
||||||
#if defined(SDL_VIDEO_DRIVER_DIRECTFB)
|
|
||||||
struct {
|
struct {
|
||||||
DFBEvent event;
|
DFBEvent event;
|
||||||
} dfb;
|
} dfb;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_COCOA)
|
||||||
#if defined(SDL_VIDEO_DRIVER_COCOA)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
/* No Cocoa window events yet */
|
/* No Cocoa window events yet */
|
||||||
} cocoa;
|
} cocoa;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_UIKIT)
|
||||||
#if defined(SDL_VIDEO_DRIVER_UIKIT)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
/* No UIKit window events yet */
|
/* No UIKit window events yet */
|
||||||
} uikit;
|
} uikit;
|
||||||
|
else
|
||||||
|
/* Can't have an empty union */
|
||||||
|
int dummy;
|
||||||
#endif
|
#endif
|
||||||
} msg;
|
} msg;
|
||||||
};
|
};
|
||||||
|
@ -168,33 +167,32 @@ struct SDL_SysWMinfo
|
||||||
{
|
{
|
||||||
HWND window; /**< The window handle */
|
HWND window; /**< The window handle */
|
||||||
} win;
|
} win;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_X11)
|
||||||
#if defined(SDL_VIDEO_DRIVER_X11)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
Display *display; /**< The X11 display */
|
Display *display; /**< The X11 display */
|
||||||
Window window; /**< The X11 window */
|
Window window; /**< The X11 window */
|
||||||
} x11;
|
} x11;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_DIRECTFB)
|
||||||
#if defined(SDL_VIDEO_DRIVER_DIRECTFB)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
IDirectFB *dfb; /**< The directfb main interface */
|
IDirectFB *dfb; /**< The directfb main interface */
|
||||||
IDirectFBWindow *window; /**< The directfb window handle */
|
IDirectFBWindow *window; /**< The directfb window handle */
|
||||||
IDirectFBSurface *surface; /**< The directfb client surface */
|
IDirectFBSurface *surface; /**< The directfb client surface */
|
||||||
} dfb;
|
} dfb;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_COCOA)
|
||||||
#if defined(SDL_VIDEO_DRIVER_COCOA)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
NSWindow *window; /* The Cocoa window */
|
NSWindow *window; /* The Cocoa window */
|
||||||
} cocoa;
|
} cocoa;
|
||||||
#endif
|
#elif defined(SDL_VIDEO_DRIVER_UIKIT)
|
||||||
#if defined(SDL_VIDEO_DRIVER_UIKIT)
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
UIWindow *window; /* The UIKit window */
|
UIWindow *window; /* The UIKit window */
|
||||||
} uikit;
|
} uikit;
|
||||||
|
#else
|
||||||
|
/* Can't have an empty union */
|
||||||
|
int dummy;
|
||||||
#endif
|
#endif
|
||||||
} info;
|
} info;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue