This commit is contained in:
Alex Anderson 2025-06-03 18:25:28 -07:00 committed by GitHub
commit 12a5773182
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1353,6 +1353,8 @@ int InitPlatform(void)
// additionally auto iconify restores the hardware resolution of the monitor if the window that loses focus is a fullscreen window
glfwWindowHint(GLFW_AUTO_ICONIFY, 0);
// Keep flags to restore after initialization (for flags not supported on initialization)
unsigned int originalCoreWindowFlags = CORE.Window.flags;
// Check window creation flags
if ((CORE.Window.flags & FLAG_FULLSCREEN_MODE) > 0) CORE.Window.fullscreen = true;
@ -1717,7 +1719,10 @@ int InitPlatform(void)
char *glfwPlatform = "";
switch (glfwGetPlatform())
{
case GLFW_PLATFORM_WIN32: glfwPlatform = "Win32"; break;
case GLFW_PLATFORM_WIN32:
glfwPlatform = "Win32";
SetWindowState(originalCoreWindowFlags);
break;
case GLFW_PLATFORM_COCOA: glfwPlatform = "Cocoa"; break;
case GLFW_PLATFORM_WAYLAND: glfwPlatform = "Wayland"; break;
case GLFW_PLATFORM_X11: glfwPlatform = "X11"; break;