1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2025-10-18 04:19:31 +00:00

Some fixes for msys2/mingw build

This commit is contained in:
fgenesis 2017-09-02 22:13:46 +02:00
commit 64406419c1
4 changed files with 14 additions and 9 deletions

View file

@ -61,18 +61,21 @@ void initIcon(void *screen)
HINSTANCE handle = ::GetModuleHandle(NULL);
if(!icon_windows)
icon_windows = ::LoadIcon(handle, "icon");
SDL_SysWMinfo wminfo;
SDL_VERSION(&wminfo.version)
if(icon_windows)
{
SDL_SysWMinfo wminfo;
SDL_VERSION(&wminfo.version)
#ifdef BBGE_BUILD_SDL2
SDL_GetWindowWMInfo((SDL_Window*)screen, &wminfo);
HWND hwnd = wminfo.info.win.window;
SDL_GetWindowWMInfo((SDL_Window*)screen, &wminfo);
HWND hwnd = wminfo.info.win.window;
#else
SDL_GetWMInfo(&wminfo);
HWND hwnd = wminfo.window;
SDL_GetWMInfo(&wminfo);
HWND hwnd = wminfo.window;
#endif
::SetClassLongPtr(hwnd, -14, (LONG) icon_windows); // -14 is GCL_HICON (32bit) or GCLP_HICON (64bit)
::SetClassLongPtr(hwnd, -14, (LONG)(uintptr_t)icon_windows); // -14 is GCL_HICON (32bit) or GCLP_HICON (64bit)
}
#endif
}

View file

@ -260,7 +260,7 @@ public:
bool cull;
float updateCull;
unsigned layer;
int layer;
InterpolatedVector *positionSnapTo;