diff --git a/video/out/x11_common.c b/video/out/x11_common.c index 9f44af23cd..362fd05149 100644 --- a/video/out/x11_common.c +++ b/video/out/x11_common.c @@ -1825,24 +1825,23 @@ int vo_x11_control(struct vo *vo, int *events, int request, void *arg) while (m_config_cache_get_next_changed(x11->opts_cache, &opt)) { if (opt == &opts->fullscreen) vo_x11_fullscreen(vo); + if (opt == &opts->ontop) + vo_x11_setlayer(vo, opts->ontop); + if (opt == &opts->border) + vo_x11_decoration(vo, opts->border); + if (opt == &opts->all_workspaces) { + long params[5] = {0xFFFFFFFF, 1}; + if (!opts->all_workspaces) { + x11_get_property_copy(x11, x11->rootwin, + XA(x11, _NET_CURRENT_DESKTOP), + XA_CARDINAL, 32, ¶ms[0], + sizeof(params[0])); + } + x11_send_ewmh_msg(x11, "_NET_WM_DESKTOP", params); + } } return VO_TRUE; } - case VOCTRL_ONTOP: - vo_x11_setlayer(vo, opts->ontop); - return VO_TRUE; - case VOCTRL_BORDER: - vo_x11_decoration(vo, opts->border); - return VO_TRUE; - case VOCTRL_ALL_WORKSPACES: { - long params[5] = {0xFFFFFFFF, 1}; - if (!opts->all_workspaces) { - x11_get_property_copy(x11, x11->rootwin, XA(x11, _NET_CURRENT_DESKTOP), - XA_CARDINAL, 32, ¶ms[0], sizeof(params[0])); - } - x11_send_ewmh_msg(x11, "_NET_WM_DESKTOP", params); - return VO_TRUE; - } case VOCTRL_GET_UNFS_WINDOW_SIZE: { int *s = arg; if (!x11->window || x11->parent)