From b057af0a56cd7de01691581178aeade7e4b6c5e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Michaj=C5=82ow?= Date: Sun, 3 Nov 2024 01:49:59 +0100 Subject: [PATCH] w32_common: update window style after changing maximized state Maximized state is not allowed without WS_OVERLAPPEDWINDOW style and doesn't stick. Set the style after. Fixes: #15093 --- video/out/w32_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/video/out/w32_common.c b/video/out/w32_common.c index d5e3a0d485..77ed79c067 100644 --- a/video/out/w32_common.c +++ b/video/out/w32_common.c @@ -1111,8 +1111,6 @@ static void update_maximized_state(struct vo_w32_state *w32, bool leaving_fullsc if (w32->parent) return; - update_window_style(w32); - // Apply the maximized state on leaving fullscreen. if (w32->current_fs && !leaving_fullscreen) return; @@ -1142,6 +1140,8 @@ static void update_maximized_state(struct vo_w32_state *w32, bool leaving_fullsc } } + update_window_style(w32); + if (toggle && !w32->current_fs && !w32->opts->window_maximized) { w32->windowrc = w32->prev_windowrc; update_window_state(w32);