From 06449648b3e519a1e63db716e8a37b16ced592f1 Mon Sep 17 00:00:00 2001 From: Robert Jordan Date: Wed, 20 May 2015 11:58:43 -0400 Subject: [PATCH] Possibly fixed issue #1056 Only resizes GUI and windows if not minimized. --- src/platform/shared.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/platform/shared.c b/src/platform/shared.c index 29eeeee2bc..0ed2fccaa3 100644 --- a/src/platform/shared.c +++ b/src/platform/shared.c @@ -245,14 +245,17 @@ static void platform_resize(int width, int height) RCT2_GLOBAL(RCT2_ADDRESS_DIRTY_BLOCK_COLUMNS, sint32) = (width >> 6) + 1; RCT2_GLOBAL(RCT2_ADDRESS_DIRTY_BLOCK_ROWS, sint32) = (height >> 3) + 1; - window_resize_gui(width, height); - window_relocate_windows(width, height); + flags = SDL_GetWindowFlags(gWindow); + + if ((flags & SDL_WINDOW_MINIMIZED) == 0) { + window_resize_gui(width, height); + window_relocate_windows(width, height); + } gfx_invalidate_screen(); // Check if the window has been resized in windowed mode and update the config file accordingly // This is called in rct2_update_2 and is only called after resizing a window has finished - flags = SDL_GetWindowFlags(gWindow); if ((flags & (SDL_WINDOW_MAXIMIZED | SDL_WINDOW_MINIMIZED | SDL_WINDOW_FULLSCREEN | SDL_WINDOW_FULLSCREEN_DESKTOP)) == 0) { if (width != gConfigGeneral.window_width || height != gConfigGeneral.window_height) {