From 2cafe5137f1544df130face8f748cc571ddf0445 Mon Sep 17 00:00:00 2001 From: Dudemanguy Date: Thu, 7 Apr 2022 21:23:19 -0500 Subject: x11: fix screen-name option 9a7b2015e1a711a57b6e660774c36956ac59a7f6 added the --screen-name option for x11, but it was unfortunately broken. The commit does correctly handle vo_x11_update_screeninfo and select the correct screen. However, vo_x11_sizehint was missed. Specifically, the force_pos bool was always false because it only took into account --screen being set and not --screen-name. To fix this, just add an extra condition to the force_pos bool so it becomes true if there's a string in --screen_name. Fixes issue #9877. --- video/out/x11_common.c | 1 + 1 file changed, 1 insertion(+) (limited to 'video/out') diff --git a/video/out/x11_common.c b/video/out/x11_common.c index c3fa16f2a9..d1fb3b6f0a 100644 --- a/video/out/x11_common.c +++ b/video/out/x11_common.c @@ -1278,6 +1278,7 @@ static void vo_x11_sizehint(struct vo *vo, struct mp_rect rc, bool override_pos) 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 + opts->screen_name || // also force onto screen area x11->parent || // force to fill parent override_pos; // for fullscreen and such -- cgit v1.2.3