From 88d30586814f86297ce98edb5c45678fe58625f7 Mon Sep 17 00:00:00 2001 From: James Ross-Gowan Date: Mon, 20 Apr 2015 20:24:19 +1000 Subject: w32_common: prevent system sleep This prevents the machine from going to sleep while a video-only stream is playing. When audio is playing, the audio stack should make this request for us. --- video/out/w32_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/video/out/w32_common.c b/video/out/w32_common.c index e1ec3ad8e9..b208666e0c 100644 --- a/video/out/w32_common.c +++ b/video/out/w32_common.c @@ -1316,7 +1316,8 @@ static int gui_thread_control(struct vo_w32_state *w32, int request, void *arg) return VO_TRUE; case VOCTRL_KILL_SCREENSAVER: w32->disable_screensaver = true; - SetThreadExecutionState(ES_CONTINUOUS | ES_DISPLAY_REQUIRED); + SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED | + ES_DISPLAY_REQUIRED); return VO_TRUE; case VOCTRL_RESTORE_SCREENSAVER: w32->disable_screensaver = false; -- cgit v1.2.3