moonlight-stream / moonlight-qt

GameStream client for PCs (Windows, Mac, Linux, and Steam Link)
GNU General Public License v3.0
10.38k stars 608 forks source link

Sleep timer and shutdown on Steam Link #860

Open CrendKing opened 2 years ago

CrendKing commented 2 years ago

Is your feature request related to a problem? Please describe. In Steam Link, there is a timer that allows the device to sleep if there is no active streaming and no user input for period of time. However, if Moonlight is active, Steam Link will no longer sleep, regardless of the system state.

Describe the solution you'd like Add a timer (configurable, or fixed as long as it's reasonable like 2 minutes) to automatically shutdown Moonlight on Steam Link if there is no streaming and no user input for the period of time.

Describe alternatives you've considered I could write a script that executes on streaming end, which connects to Steam Link via SSH and run shutdown to force it to sleep/shutdown.

cgutman commented 2 years ago

Moonlight doesn't suppress the screen saver or display blanking when it's running at the UI (only while streaming), so I think this is a Steam Link-specific thing that it won't sleep when a third-party app is running.

Does it sleep with any other third-party native app running?

CrendKing commented 2 years ago

I tested Kodi on Steam Link and it exhibits the same behavior, so I'm sure Steam Link's OS just disables it's internal sleep timer when there is a foreground app running. So technically I should instead ask Valve to implement option to change that behavior.

However, Kodi itself also has its own sleep timer (e.g. "Quit" after "5" minutes of idle), which is exactly what I'm asking here. I do understand Kodi has a much bigger role and coverage, so it's unsurprising they have such feature while Moonlight doesn't.

Anyways, it's up to you guys to decide if this is a won't fix. I'm OK either way.