diff --git a/platform/windows/display_server_windows.cpp b/platform/windows/display_server_windows.cpp index 6d69e658be5..e1950c720f9 100644 --- a/platform/windows/display_server_windows.cpp +++ b/platform/windows/display_server_windows.cpp @@ -7153,6 +7153,11 @@ DisplayServerWindows::DisplayServerWindows(const String &p_rendering_driver, Win OleInitialize(nullptr); + HICON default_icon = LoadIconW(GetModuleHandle(nullptr), L"GODOT_ICON"); + if (default_icon == nullptr) { + default_icon = LoadIcon(nullptr, IDI_WINLOGO); + } + memset(&wc, 0, sizeof(WNDCLASSEXW)); wc.cbSize = sizeof(WNDCLASSEXW); wc.style = CS_OWNDC | CS_DBLCLKS; @@ -7160,7 +7165,7 @@ DisplayServerWindows::DisplayServerWindows(const String &p_rendering_driver, Win wc.cbClsExtra = 0; wc.cbWndExtra = 0; wc.hInstance = hInstance ? hInstance : GetModuleHandle(nullptr); - wc.hIcon = LoadIcon(nullptr, IDI_WINLOGO); + wc.hIcon = default_icon; wc.hCursor = nullptr; wc.hbrBackground = nullptr; wc.lpszMenuName = nullptr;