aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2015-06-14 13:55:42 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2015-06-14 13:55:42 -0400
commit4cf456925f489c435704950d619ac206443e8698 (patch)
treee0146adb1564bcd9c22ce993dc4cc50b0eea526a
parent3205913b2a8559a6a29a81d63dd144249db6e234 (diff)
adjust default setting for library monitor
-rw-r--r--MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj3
-rw-r--r--MediaBrowser.Model.net35/MediaBrowser.Model.net35.csproj3
-rw-r--r--MediaBrowser.Model/Configuration/AutoOnOff.cs10
-rw-r--r--MediaBrowser.Model/Configuration/ServerConfiguration.cs6
-rw-r--r--MediaBrowser.Model/MediaBrowser.Model.csproj1
-rw-r--r--MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs19
-rw-r--r--SharedVersion.cs2
7 files changed, 39 insertions, 5 deletions
diff --git a/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj b/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj
index a2fb145174..3238e79b71 100644
--- a/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj
+++ b/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj
@@ -182,6 +182,9 @@
<Compile Include="..\MediaBrowser.Model\Configuration\AccessSchedule.cs">
<Link>Configuration\AccessSchedule.cs</Link>
</Compile>
+ <Compile Include="..\MediaBrowser.Model\Configuration\AutoOnOff.cs">
+ <Link>Configuration\AutoOnOff.cs</Link>
+ </Compile>
<Compile Include="..\MediaBrowser.Model\Configuration\BaseApplicationConfiguration.cs">
<Link>Configuration\BaseApplicationConfiguration.cs</Link>
</Compile>
diff --git a/MediaBrowser.Model.net35/MediaBrowser.Model.net35.csproj b/MediaBrowser.Model.net35/MediaBrowser.Model.net35.csproj
index 0cb8e5ca22..be72776077 100644
--- a/MediaBrowser.Model.net35/MediaBrowser.Model.net35.csproj
+++ b/MediaBrowser.Model.net35/MediaBrowser.Model.net35.csproj
@@ -147,6 +147,9 @@
<Compile Include="..\MediaBrowser.Model\Configuration\AccessSchedule.cs">
<Link>Configuration\AccessSchedule.cs</Link>
</Compile>
+ <Compile Include="..\MediaBrowser.Model\Configuration\AutoOnOff.cs">
+ <Link>Configuration\AutoOnOff.cs</Link>
+ </Compile>
<Compile Include="..\MediaBrowser.Model\Configuration\BaseApplicationConfiguration.cs">
<Link>Configuration\BaseApplicationConfiguration.cs</Link>
</Compile>
diff --git a/MediaBrowser.Model/Configuration/AutoOnOff.cs b/MediaBrowser.Model/Configuration/AutoOnOff.cs
new file mode 100644
index 0000000000..e911a0ff1b
--- /dev/null
+++ b/MediaBrowser.Model/Configuration/AutoOnOff.cs
@@ -0,0 +1,10 @@
+
+namespace MediaBrowser.Model.Configuration
+{
+ public enum AutoOnOff
+ {
+ Auto,
+ Enabled,
+ Disabled
+ }
+}
diff --git a/MediaBrowser.Model/Configuration/ServerConfiguration.cs b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
index ec9e6e10ff..f1d6bbcae6 100644
--- a/MediaBrowser.Model/Configuration/ServerConfiguration.cs
+++ b/MediaBrowser.Model/Configuration/ServerConfiguration.cs
@@ -187,7 +187,6 @@ namespace MediaBrowser.Model.Configuration
public bool EnableAutomaticRestart { get; set; }
- public bool EnableRealtimeMonitor { get; set; }
public PathSubstitution[] PathSubstitutions { get; set; }
public string ServerName { get; set; }
@@ -210,6 +209,8 @@ namespace MediaBrowser.Model.Configuration
public bool DenyIFrameEmbedding { get; set; }
+ public AutoOnOff EnableLibraryMonitor { get; set; }
+
/// <summary>
/// Initializes a new instance of the <see cref="ServerConfiguration" /> class.
/// </summary>
@@ -236,6 +237,7 @@ namespace MediaBrowser.Model.Configuration
// 5 minutes
MinResumeDurationSeconds = 300;
+ EnableLibraryMonitor = AutoOnOff.Auto;
RealtimeLibraryMonitorDelay = 40;
EnableInternetProviders = true;
@@ -253,8 +255,6 @@ namespace MediaBrowser.Model.Configuration
SeasonZeroDisplayName = "Specials";
- EnableRealtimeMonitor = true;
-
UICulture = "en-us";
PeopleMetadataOptions = new PeopleMetadataOptions();
diff --git a/MediaBrowser.Model/MediaBrowser.Model.csproj b/MediaBrowser.Model/MediaBrowser.Model.csproj
index df3cd15f65..3daacdd733 100644
--- a/MediaBrowser.Model/MediaBrowser.Model.csproj
+++ b/MediaBrowser.Model/MediaBrowser.Model.csproj
@@ -96,6 +96,7 @@
<Compile Include="Chapters\RemoteChapterResult.cs" />
<Compile Include="Collections\CollectionCreationResult.cs" />
<Compile Include="Configuration\AccessSchedule.cs" />
+ <Compile Include="Configuration\AutoOnOff.cs" />
<Compile Include="Configuration\ChannelOptions.cs" />
<Compile Include="Configuration\ChapterOptions.cs" />
<Compile Include="Configuration\CinemaModeConfiguration.cs" />
diff --git a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs
index ba5d10eef9..d6a1be9623 100644
--- a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs
+++ b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs
@@ -3,6 +3,7 @@ using MediaBrowser.Common.ScheduledTasks;
using MediaBrowser.Controller.Configuration;
using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Library;
+using MediaBrowser.Model.Configuration;
using MediaBrowser.Model.Logging;
using MediaBrowser.Server.Implementations.ScheduledTasks;
using Microsoft.Win32;
@@ -147,9 +148,25 @@ namespace MediaBrowser.Server.Implementations.IO
Start();
}
+ private bool EnableLibraryMonitor
+ {
+ get
+ {
+ switch (ConfigurationManager.Configuration.EnableLibraryMonitor)
+ {
+ case AutoOnOff.Auto:
+ return Environment.OSVersion.Platform == PlatformID.Win32NT;
+ case AutoOnOff.Enabled:
+ return true;
+ default:
+ return false;
+ }
+ }
+ }
+
public void Start()
{
- if (ConfigurationManager.Configuration.EnableRealtimeMonitor)
+ if (EnableLibraryMonitor)
{
StartInternal();
}
diff --git a/SharedVersion.cs b/SharedVersion.cs
index d1f70ad19f..0478d2aae0 100644
--- a/SharedVersion.cs
+++ b/SharedVersion.cs
@@ -1,4 +1,4 @@
using System.Reflection;
//[assembly: AssemblyVersion("3.0.*")]
-[assembly: AssemblyVersion("3.0.5641.2")]
+[assembly: AssemblyVersion("3.0.5641.3")]