mirror of
https://github.com/kanjitalk755/macemu.git
synced 2025-02-19 19:30:42 +00:00
Use GetMainWindowHandle() provided by main_windows.cpp
This commit is contained in:
parent
8d73299187
commit
dfbb829055
@ -93,16 +93,8 @@ struct ByteArray : public vector<uint8> {
|
|||||||
static void do_putscrap(uint32 type, void *scrap, int32 length);
|
static void do_putscrap(uint32 type, void *scrap, int32 length);
|
||||||
static void do_getscrap(void **handle, uint32 type, int32 offset);
|
static void do_getscrap(void **handle, uint32 type, int32 offset);
|
||||||
|
|
||||||
// The main window handle
|
// From main_windows.cpp
|
||||||
#ifdef USE_SDL_VIDEO
|
extern HWND GetMainWindowHandle(void);
|
||||||
#include <SDL_syswm.h>
|
|
||||||
static HWND GetMainWindowHandle(void)
|
|
||||||
{
|
|
||||||
SDL_SysWMinfo wmInfo;
|
|
||||||
SDL_VERSION(&wmInfo.version);
|
|
||||||
return SDL_GetWMInfo(&wmInfo) ? wmInfo.window : NULL;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -650,12 +650,10 @@ static int tick_func(void *arg)
|
|||||||
|
|
||||||
#ifdef USE_SDL_VIDEO
|
#ifdef USE_SDL_VIDEO
|
||||||
#include <SDL_syswm.h>
|
#include <SDL_syswm.h>
|
||||||
static HWND GetMainWindowHandle(void)
|
HWND GetMainWindowHandle(void)
|
||||||
{
|
{
|
||||||
SDL_SysWMinfo wmInfo;
|
SDL_SysWMinfo wmInfo;
|
||||||
wmInfo.version.major = SDL_MAJOR_VERSION;
|
SDL_VERSION(&wmInfo.version);
|
||||||
wmInfo.version.minor = SDL_MINOR_VERSION;
|
|
||||||
wmInfo.version.patch = SDL_PATCHLEVEL;
|
|
||||||
return SDL_GetWMInfo(&wmInfo) ? wmInfo.window : NULL;
|
return SDL_GetWMInfo(&wmInfo) ? wmInfo.window : NULL;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user