update sleep prevention

This commit is contained in:
Luke Pulverenti
2016-04-23 14:38:36 -04:00
parent 85a9363c78
commit 9807448fce
8 changed files with 67 additions and 33 deletions

View File

@@ -5,6 +5,7 @@ using MediaBrowser.ServerApplication.Networking;
using System.Collections.Generic;
using System.IO;
using System.Reflection;
using System.Windows.Forms;
using CommonIO;
using MediaBrowser.Controller.Power;
using MediaBrowser.Server.Startup.Common.FFMpeg;
@@ -134,7 +135,12 @@ namespace MediaBrowser.ServerApplication.Native
public void PreventSystemStandby()
{
Standby.PreventSystemStandby();
MainStartup.Invoke(Standby.PreventSleep);
}
public void AllowSystemStandby()
{
MainStartup.Invoke(Standby.AllowSleep);
}
public IPowerManagement GetPowerManagement()