diff options
author | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2024-03-26 17:47:11 +0100 |
---|---|---|
committer | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2024-04-08 13:44:29 +0200 |
commit | 8aa84d089e4233e17a6263cb0cf629331e63d051 (patch) | |
tree | fa46597046c977f17fd8f0d5a68a26b0bf320e47 /src/client.cpp | |
parent | 59919635523d41f3a15120c83db4b7d080c155de (diff) | |
download | mana-8aa84d089e4233e17a6263cb0cf629331e63d051.tar.gz mana-8aa84d089e4233e17a6263cb0cf629331e63d051.tar.bz2 mana-8aa84d089e4233e17a6263cb0cf629331e63d051.tar.xz mana-8aa84d089e4233e17a6263cb0cf629331e63d051.zip |
Compile fixes for MSYS2 UCRT64
Also added instructions for installing the dependencies on MSYS2.
The selection of the default language is commented out for now. It will
be fixed in another change.
Diffstat (limited to 'src/client.cpp')
-rw-r--r-- | src/client.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/client.cpp b/src/client.cpp index 2a854bc0..63452112 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -80,8 +80,9 @@ #include <SDL_image.h> #ifdef _WIN32 -#include <SDL_syswm.h> #include "utils/specialfolder.h" +#include <SDL_syswm.h> +#include <winuser.h> #endif #include <sys/stat.h> @@ -332,7 +333,7 @@ Client::Client(const Options &options): logger->log("Loading icon from file: %s", iconFile.c_str()); #ifdef _WIN32 static SDL_SysWMinfo pInfo; - SDL_GetWMInfo(&pInfo); + SDL_GetWindowWMInfo(mVideo.window(), &pInfo); // Attempt to load icon from .ico file HICON icon = (HICON) LoadImage(NULL, iconFile.c_str(), @@ -342,7 +343,7 @@ Client::Client(const Options &options): icon = LoadIcon(GetModuleHandle(NULL), "A"); if (icon) - SetClassLong(pInfo.window, GCL_HICON, (LONG) icon); + SetClassLongPtr(pInfo.info.win.window, GCLP_HICON, (LONG_PTR) icon); #else mIcon = IMG_Load(iconFile.c_str()); if (mIcon) |