mirror of
https://github.com/mpv-player/mpv.git
synced 2026-10-28 23:13:18 +08:00
x11: fix screen-name option
9a7b2015e1 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.
This commit is contained in:
@@ -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
|
||||
|
||||
|
||||
Reference in New Issue
Block a user