diff options
| author | Luke <luke.pulverenti@gmail.com> | 2016-11-03 19:59:50 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-11-03 19:59:50 -0400 |
| commit | c53745548ac2130f4cfbbe0d7a2804c36c8ae4eb (patch) | |
| tree | 6ee298ebb5470c4f3bcbef8d814a0354901469c4 /MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs | |
| parent | 338b04a0c58729ec70aed89924ea6bd12422872b (diff) | |
| parent | 405a5f69c5967b4d919b5fe91396f12cb83e8aa8 (diff) | |
Merge pull request #2267 from MediaBrowser/dev
Dev
Diffstat (limited to 'MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs')
| -rw-r--r-- | MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs index 77981b528..49cb1e75f 100644 --- a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs +++ b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs @@ -4,7 +4,6 @@ using MediaBrowser.Controller.Library; using MediaBrowser.Controller.Plugins; using MediaBrowser.Model.Configuration; using MediaBrowser.Model.Logging; -using Microsoft.Win32; using System; using System.Collections.Concurrent; using System.Collections.Generic; @@ -16,6 +15,8 @@ using MediaBrowser.Model.IO; using MediaBrowser.Controller; using MediaBrowser.Controller.IO; using MediaBrowser.Model.Tasks; +using MediaBrowser.Model.Threading; +using Microsoft.Win32; namespace MediaBrowser.Server.Implementations.IO { @@ -136,12 +137,12 @@ namespace MediaBrowser.Server.Implementations.IO private IServerConfigurationManager ConfigurationManager { get; set; } private readonly IFileSystem _fileSystem; - private readonly IServerApplicationHost _appHost; + private readonly ITimerFactory _timerFactory; /// <summary> /// Initializes a new instance of the <see cref="LibraryMonitor" /> class. /// </summary> - public LibraryMonitor(ILogManager logManager, ITaskManager taskManager, ILibraryManager libraryManager, IServerConfigurationManager configurationManager, IFileSystem fileSystem, IServerApplicationHost appHost) + public LibraryMonitor(ILogManager logManager, ITaskManager taskManager, ILibraryManager libraryManager, IServerConfigurationManager configurationManager, IFileSystem fileSystem, ITimerFactory timerFactory) { if (taskManager == null) { @@ -153,7 +154,7 @@ namespace MediaBrowser.Server.Implementations.IO Logger = logManager.GetLogger(GetType().Name); ConfigurationManager = configurationManager; _fileSystem = fileSystem; - _appHost = appHost; + _timerFactory = timerFactory; SystemEvents.PowerModeChanged += SystemEvents_PowerModeChanged; } @@ -528,7 +529,7 @@ namespace MediaBrowser.Server.Implementations.IO } } - var newRefresher = new FileRefresher(path, _fileSystem, ConfigurationManager, LibraryManager, TaskManager, Logger); + var newRefresher = new FileRefresher(path, _fileSystem, ConfigurationManager, LibraryManager, TaskManager, Logger, _timerFactory); newRefresher.Completed += NewRefresher_Completed; _activeRefreshers.Add(newRefresher); } |
