From e27ac6b09268beb448b5e9982f8f6472b4933687 Mon Sep 17 00:00:00 2001 From: Velaron Date: Sat, 20 May 2023 20:54:21 +0300 Subject: [PATCH] platform: win32: properly change icon --- engine/platform/sdl/vid_sdl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/engine/platform/sdl/vid_sdl.c b/engine/platform/sdl/vid_sdl.c index b791cc6c..e1f85386 100644 --- a/engine/platform/sdl/vid_sdl.c +++ b/engine/platform/sdl/vid_sdl.c @@ -619,7 +619,8 @@ static void WIN_SetWindowIcon( HICON ico ) if( SDL_GetWindowWMInfo( host.hWnd, &wminfo ) ) { - SetClassLongPtr( wminfo.info.win.window, GCLP_HICON, (LONG_PTR)ico ); + SendMessage( wminfo.info.win.window, WM_SETICON, ICON_SMALL, (LONG_PTR)ico ); + SendMessage( wminfo.info.win.window, WM_SETICON, ICON_BIG, (LONG_PTR)ico ); } } #endif