From ceb0602c16f007d1b24ac01fe681af51e85c02a5 Mon Sep 17 00:00:00 2001 From: jitspoe Date: Mon, 6 Nov 2023 02:36:12 -0500 Subject: [PATCH] Fix bug where maximized->fullscreen->windowed mode stays maximized. (cherry picked from commit 7918e2b6d9693b0a9c01c8de4debaa7d89fa72ed) --- platform/windows/display_server_windows.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/platform/windows/display_server_windows.cpp b/platform/windows/display_server_windows.cpp index bbaa8784fbf..2c7679b13ac 100644 --- a/platform/windows/display_server_windows.cpp +++ b/platform/windows/display_server_windows.cpp @@ -1401,7 +1401,9 @@ void DisplayServerWindows::window_set_mode(WindowMode p_mode, WindowID p_window) SystemParametersInfoA(SPI_SETMOUSETRAILS, restore_mouse_trails, 0, 0); restore_mouse_trails = 0; } - } else if (p_mode == WINDOW_MODE_WINDOWED) { + } + + if (p_mode == WINDOW_MODE_WINDOWED) { ShowWindow(wd.hWnd, SW_RESTORE); wd.maximized = false; wd.minimized = false;