From f7151932df4b239a8ee724117103cc15635987c5 Mon Sep 17 00:00:00 2001 From: Dudemanguy Date: Sun, 13 Aug 2023 15:31:51 -0500 Subject: x11: set sizehint for fs-screen and fs-screen-name Without doing this, --fs --fs-screen=1 wouldn't actually end up on the desired screen since the sizehint was never sent. Also check the screen-name variants for an empty string as well so the option can properly "undo" itself (not sure if this has any practical effect). --- video/out/x11_common.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'video') diff --git a/video/out/x11_common.c b/video/out/x11_common.c index c4ceb53a89..f63e1f02cd 100644 --- a/video/out/x11_common.c +++ b/video/out/x11_common.c @@ -1356,9 +1356,13 @@ static void vo_x11_sizehint(struct vo *vo, struct mp_rect rc, bool override_pos) if (!x11->window || x11->parent) return; + bool screen = opts->screen_id >= 0 || (opts->screen_name && + opts->screen_name[0]); + bool fsscreen = opts->fsscreen_id >= 0 || (opts->fsscreen_name && + opts->fsscreen_name[0]); bool force_pos = opts->geometry.xy_valid || // explicitly forced by user opts->force_window_position || // resize -> reset position - opts->screen_id >= 0 || // force onto screen area + screen || fsscreen || // force onto screen area opts->screen_name || // also force onto screen area x11->parent || // force to fill parent override_pos; // for fullscreen and such -- cgit v1.2.3