diff options
author | Kacper Michajłow <kasper93@gmail.com> | 2023-03-19 06:38:32 +0100 |
---|---|---|
committer | Dudemanguy <random342@airmail.cc> | 2023-09-21 23:13:19 +0000 |
commit | ee24dd04194aadfda882fd73553cba8d1e734567 (patch) | |
tree | 541a5a0b41ca3138317fc580addd7e9d513e7ba4 /video/out/w32_common.c | |
parent | 2c738ca54b16cdd1982473672bd39068fcf8d948 (diff) | |
download | mpv-ee24dd04194aadfda882fd73553cba8d1e734567.tar.bz2 mpv-ee24dd04194aadfda882fd73553cba8d1e734567.tar.xz |
win32: add an option to control window title bar state
Fixes: #11432
Diffstat (limited to 'video/out/w32_common.c')
-rw-r--r-- | video/out/w32_common.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/video/out/w32_common.c b/video/out/w32_common.c index 4861d97cc0..a8794b89c9 100644 --- a/video/out/w32_common.c +++ b/video/out/w32_common.c @@ -805,6 +805,8 @@ static DWORD update_style(struct vo_w32_state *w32, DWORD style) style |= FULLSCREEN; } else { style |= w32->opts->border ? FRAME : NO_FRAME; + if (!w32->opts->title_bar) + style &= ~WS_CAPTION; } return style; } @@ -1802,7 +1804,9 @@ static int gui_thread_control(struct vo_w32_state *w32, int request, void *arg) update_affinity(w32); } else if (changed_option == &vo_opts->ontop) { update_window_state(w32); - } else if (changed_option == &vo_opts->border) { + } else if (changed_option == &vo_opts->border || + changed_option == &vo_opts->title_bar) + { update_window_style(w32); update_window_state(w32); } else if (changed_option == &vo_opts->window_minimized) { |