x11: implement unminimization

This appears to work with IceWM.
This commit is contained in:
wm4 2019-11-29 14:27:27 +01:00
parent 2b4c867505
commit 3f7556baef
2 changed files with 6 additions and 2 deletions

View File

@ -2811,7 +2811,7 @@ Window
Whether the video window is minimized or not. Setting this will minimize,
or unminimze, the video window if the current VO supports it. Note that
some VOs may support minimization while not supporting unminimization
(eg: X11 and Wayland).
(eg: Wayland).
Whether this option and ``--window-maximized`` work on program start or
at runtime, and whether they're (at runtime) updated to reflect the actual

View File

@ -1836,8 +1836,12 @@ static void vo_x11_minimize(struct vo *vo)
{
struct vo_x11_state *x11 = vo->x11;
if (x11->opts->window_minimized)
if (x11->opts->window_minimized) {
XIconifyWindow(x11->display, x11->window, x11->screen);
} else {
long params[5] = {0};
x11_send_ewmh_msg(x11, "_NET_ACTIVE_WINDOW", params);
}
}
int vo_x11_control(struct vo *vo, int *events, int request, void *arg)