summaryrefslogtreecommitdiffstats
path: root/video/out/x11_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'video/out/x11_common.c')
-rw-r--r--video/out/x11_common.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/video/out/x11_common.c b/video/out/x11_common.c
index d1fb3b6f0a..d8cda687f8 100644
--- a/video/out/x11_common.c
+++ b/video/out/x11_common.c
@@ -1043,6 +1043,7 @@ static void vo_x11_check_net_wm_state_change(struct vo *vo)
}
opts->window_minimized = is_minimized;
+ x11->hidden = is_minimized;
m_config_cache_write_opt(x11->opts_cache, &opts->window_minimized);
opts->window_maximized = is_maximized;
m_config_cache_write_opt(x11->opts_cache, &opts->window_maximized);
@@ -1863,6 +1864,14 @@ static void vo_x11_set_geometry(struct vo *vo)
}
}
+bool vo_x11_check_visible(struct vo *vo) {
+ struct vo_x11_state *x11 = vo->x11;
+ struct mp_vo_opts *opts = x11->opts;
+
+ bool render = !x11->hidden || VS_IS_DISP(opts->video_sync);
+ return render;
+}
+
int vo_x11_control(struct vo *vo, int *events, int request, void *arg)
{
struct vo_x11_state *x11 = vo->x11;