The Free Software Media System - Server Backend & API
remove unused service properties
Luke Pulverentif7f41e4c739f
diff --git a/Emby.Server.Implementations/ApplicationHost.cs b/Emby.Server.Implementations/ApplicationHost.csindex 02308f79f5..2b0030152c 100644--- a/Emby.Server.Implementations/ApplicationHost.cs+++ b/Emby.Server.Implementations/ApplicationHost.cs@@ -439,14 +439,6 @@ namespace Emby.Server.Implementations}}- public virtual bool SupportsRunningAsService- {- get- {- return false;- }- }-private DeviceId _deviceId;public string SystemId{@@ -473,14 +465,6 @@ namespace Emby.Server.Implementations}}- public virtual bool IsRunningAsService- {- get- {- return false;- }- }-private Assembly GetAssembly(Type type){return type.GetTypeInfo().Assembly;@@ -1910,7 +1894,6 @@ namespace Emby.Server.ImplementationsHasUpdateAvailable = HasUpdateAvailable,SupportsAutoRunAtStartup = SupportsAutoRunAtStartup,TranscodingTempPath = ApplicationPaths.TranscodingTempPath,- SupportsRunningAsService = SupportsRunningAsService,ServerName = FriendlyName,LocalAddress = localAddress,SupportsLibraryMonitor = true,diff --git a/Emby.Server.Implementations/EntryPoints/SystemEvents.cs b/Emby.Server.Implementations/EntryPoints/SystemEvents.csindex aa63dae274..08f3edb3d5 100644--- a/Emby.Server.Implementations/EntryPoints/SystemEvents.cs+++ b/Emby.Server.Implementations/EntryPoints/SystemEvents.cs@@ -23,18 +23,9 @@ namespace Emby.Server.Implementations.EntryPointspublic void Run(){- _systemEvents.SessionLogoff += _systemEvents_SessionLogoff;_systemEvents.SystemShutdown += _systemEvents_SystemShutdown;}- private void _systemEvents_SessionLogoff(object sender, EventArgs e)- {- if (!_appHost.IsRunningAsService)- {- _appHost.Shutdown();- }- }-private void _systemEvents_SystemShutdown(object sender, EventArgs e){_appHost.Shutdown();diff --git a/MediaBrowser.Api/StartupWizardService.cs b/MediaBrowser.Api/StartupWizardService.csindex 7a75aeb4be..b15e06c9c0 100644--- a/MediaBrowser.Api/StartupWizardService.cs+++ b/MediaBrowser.Api/StartupWizardService.cs@@ -67,13 +67,10 @@ namespace MediaBrowser.Api_config.SaveConfiguration();}- public async Task<object> Get(GetStartupInfo request)+ public object Get(GetStartupInfo request){- var info = await _appHost.GetSystemInfo().ConfigureAwait(false);-return new StartupInfo{- SupportsRunningAsService = info.SupportsRunningAsService,HasMediaEncoder = !string.IsNullOrWhiteSpace(_mediaEncoder.EncoderPath)};}@@ -152,7 +149,6 @@ namespace MediaBrowser.Apipublic class StartupInfo{- public bool SupportsRunningAsService { get; set; }public bool HasMediaEncoder { get; set; }}diff --git a/MediaBrowser.Controller/IServerApplicationHost.cs b/MediaBrowser.Controller/IServerApplicationHost.csindex 86b52bd775..44c0031974 100644--- a/MediaBrowser.Controller/IServerApplicationHost.cs+++ b/MediaBrowser.Controller/IServerApplicationHost.cs@@ -21,12 +21,6 @@ namespace MediaBrowser.Controller/// <returns>SystemInfo.</returns>Task<SystemInfo> GetSystemInfo();- /// <summary>- /// Gets a value indicating whether this instance is running as service.- /// </summary>- /// <value><c>true</c> if this instance is running as service; otherwise, <c>false</c>.</value>- bool IsRunningAsService { get; }-/// <summary>/// Gets a value indicating whether [supports automatic run at startup]./// </summary>diff --git a/MediaBrowser.Model/System/SystemInfo.cs b/MediaBrowser.Model/System/SystemInfo.csindex f9f3bf52e5..b61d637293 100644--- a/MediaBrowser.Model/System/SystemInfo.cs+++ b/MediaBrowser.Model/System/SystemInfo.cs@@ -16,12 +16,6 @@ namespace MediaBrowser.Model.System/// <value>The display name of the operating system.</value>public string OperatingSystemDisplayName { get; set; }- /// <summary>- /// Gets or sets a value indicating whether [supports running as service].- /// </summary>- /// <value><c>true</c> if [supports running as service]; otherwise, <c>false</c>.</value>- public bool SupportsRunningAsService { get; set; }-/// <summary>/// Gets or sets the mac address./// </summary>diff --git a/MediaBrowser.ServerApplication/WindowsAppHost.cs b/MediaBrowser.ServerApplication/WindowsAppHost.csindex a6664c42f0..19079fbc92 100644--- a/MediaBrowser.ServerApplication/WindowsAppHost.cs+++ b/MediaBrowser.ServerApplication/WindowsAppHost.cs@@ -31,11 +31,6 @@ namespace MediaBrowser.ServerApplicationfileSystem.AddShortcutHandler(new LnkShortcutHandler());}- public override bool IsRunningAsService- {- get { return MainStartup.IsRunningAsService; }- }-protected override IConnectManager CreateConnectManager(){return new ConnectManager();@@ -111,14 +106,6 @@ namespace MediaBrowser.ServerApplication}}- public override bool SupportsRunningAsService- {- get- {- return true;- }- }-public override bool CanSelfRestart{get