From 3497ed71c23a5147b0c8a0440f3e53cd37b48439 Mon Sep 17 00:00:00 2001 From: OBattler Date: Sat, 17 Apr 2021 22:43:31 +0200 Subject: [PATCH] Some fixes to the UI code. --- src/win/win.c | 5 ++++- src/win/win_ui.c | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/win/win.c b/src/win/win.c index f82bc7a3e..4b77561d8 100644 --- a/src/win/win.c +++ b/src/win/win.c @@ -499,7 +499,10 @@ main_thread(void *param) /* If needed, handle a screen resize. */ if (doresize && !video_fullscreen) { - plat_resize(scrnsz_x, scrnsz_y); + if (vid_resize & 2) + plat_resize(fixed_size_x, fixed_size_y); + else + plat_resize(scrnsz_x, scrnsz_y); doresize = 0; } } diff --git a/src/win/win_ui.c b/src/win/win_ui.c index de76d142b..fa3464bf6 100644 --- a/src/win/win_ui.c +++ b/src/win/win_ui.c @@ -1347,7 +1347,10 @@ ui_init(int nCmdShow) } /* Set up the current window size. */ - plat_resize(scrnsz_x, scrnsz_y); + if (vid_resize & 2) + plat_resize(fixed_size_x, fixed_size_y); + else + plat_resize(scrnsz_x, scrnsz_y); /* Fire up the machine. */ pc_reset_hard_init();