|
|
@ -1,5 +1,4 @@
|
|
|
|
using MediaBrowser.Common.Configuration;
|
|
|
|
using MediaBrowser.Common.Configuration;
|
|
|
|
using MediaBrowser.Common.ScheduledTasks;
|
|
|
|
|
|
|
|
using MediaBrowser.Controller.Configuration;
|
|
|
|
using MediaBrowser.Controller.Configuration;
|
|
|
|
using MediaBrowser.Controller.Entities;
|
|
|
|
using MediaBrowser.Controller.Entities;
|
|
|
|
using MediaBrowser.Controller.Entities.Movies;
|
|
|
|
using MediaBrowser.Controller.Entities.Movies;
|
|
|
@ -16,6 +15,7 @@ using System.Threading;
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
using System.IO;
|
|
|
|
using System.IO;
|
|
|
|
using MediaBrowser.Model.Serialization;
|
|
|
|
using MediaBrowser.Model.Serialization;
|
|
|
|
|
|
|
|
using MediaBrowser.Model.Tasks;
|
|
|
|
|
|
|
|
|
|
|
|
namespace MediaBrowser.Providers.MediaInfo
|
|
|
|
namespace MediaBrowser.Providers.MediaInfo
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -88,6 +88,11 @@ namespace MediaBrowser.Providers.MediaInfo
|
|
|
|
}).OfType<Video>()
|
|
|
|
}).OfType<Video>()
|
|
|
|
.ToList();
|
|
|
|
.ToList();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (videos.Count == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
var numComplete = 0;
|
|
|
|
var numComplete = 0;
|
|
|
|
|
|
|
|
|
|
|
|
foreach (var video in videos)
|
|
|
|
foreach (var video in videos)
|
|
|
@ -142,12 +147,18 @@ namespace MediaBrowser.Providers.MediaInfo
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public IEnumerable<ITaskTrigger> GetDefaultTriggers()
|
|
|
|
public IEnumerable<TaskTriggerInfo> GetDefaultTriggers()
|
|
|
|
{
|
|
|
|
|
|
|
|
return new ITaskTrigger[]
|
|
|
|
|
|
|
|
{
|
|
|
|
{
|
|
|
|
new IntervalTrigger{ Interval = TimeSpan.FromHours(8)}
|
|
|
|
return new[] {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Every so often
|
|
|
|
|
|
|
|
new TaskTriggerInfo { Type = TaskTriggerInfo.TriggerInterval, IntervalTicks = TimeSpan.FromHours(24).Ticks}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public string Key
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
get { return "DownloadSubtitles"; }
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|