shell: Go straight to sleep if the sceensaver isn't configured

If the screensaver path is not set, nothing would set the compositor
state to sleeping. In that case, outpus DPMS state was never set to
off.
Ander Conselvan de Oliveira 12 years ago committed by Kristian Høgsberg
parent b17537e2c5
commit dda9d78ec9
  1. 4
      src/shell.c

@ -2167,8 +2167,10 @@ launch_screensaver(struct desktop_shell *shell)
if (shell->screensaver.binding) if (shell->screensaver.binding)
return; return;
if (!shell->screensaver.path) if (!shell->screensaver.path) {
weston_compositor_sleep(shell->compositor);
return; return;
}
if (shell->screensaver.process.pid != 0) { if (shell->screensaver.process.pid != 0) {
weston_log("old screensaver still running\n"); weston_log("old screensaver still running\n");

Loading…
Cancel
Save