diff --git a/MediaBrowser.Api/BrandingService.cs b/MediaBrowser.Api/BrandingService.cs index ac491a997..c900e4d06 100644 --- a/MediaBrowser.Api/BrandingService.cs +++ b/MediaBrowser.Api/BrandingService.cs @@ -34,7 +34,8 @@ namespace MediaBrowser.Api { var result = _config.GetConfiguration("branding"); - return ResultFactory.GetResult(result.CustomCss, "text/css"); + // When null this throws a 405 error under Mono OSX, so default to empty string + return ResultFactory.GetResult(result.CustomCss ?? string.Empty, "text/css"); } } } diff --git a/MediaBrowser.Server.Implementations/Persistence/SqliteItemRepository.cs b/MediaBrowser.Server.Implementations/Persistence/SqliteItemRepository.cs index 5e992d9db..2f01af79b 100644 --- a/MediaBrowser.Server.Implementations/Persistence/SqliteItemRepository.cs +++ b/MediaBrowser.Server.Implementations/Persistence/SqliteItemRepository.cs @@ -129,7 +129,8 @@ namespace MediaBrowser.Server.Implementations.Persistence _connection.RunQueries(queries, _logger); - _connection.AddColumn(_logger, "TypedBaseItems", "StartDate", "DATETIME"); + _connection.AddColumn(_logger, "TypedBaseItems", "Path", "Text"); + _connection.AddColumn(_logger, "TypedBaseItems", "StartDate", "DATETIME"); _connection.AddColumn(_logger, "TypedBaseItems", "EndDate", "DATETIME"); _connection.AddColumn(_logger, "TypedBaseItems", "ChannelId", "Text"); _connection.AddColumn(_logger, "TypedBaseItems", "IsMovie", "BIT"); @@ -163,6 +164,7 @@ namespace MediaBrowser.Server.Implementations.Persistence "guid", "type", "data", + "Path", "StartDate", "EndDate", "ChannelId", @@ -177,7 +179,7 @@ namespace MediaBrowser.Server.Implementations.Persistence "OfficialRating" }; _saveItemCommand = _connection.CreateCommand(); - _saveItemCommand.CommandText = "replace into TypedBaseItems (" + string.Join(",", saveColumns.ToArray()) + ") values (@1, @2, @3, @4, @5, @6, @7, @8, @9, @10, @11, @12, @13, @14, @15)"; + _saveItemCommand.CommandText = "replace into TypedBaseItems (" + string.Join(",", saveColumns.ToArray()) + ") values (@1, @2, @3, @4, @5, @6, @7, @8, @9, @10, @11, @12, @13, @14, @15, @16)"; for (var i = 1; i <= saveColumns.Count; i++) { _saveItemCommand.Parameters.Add(_saveItemCommand, "@" + i.ToString(CultureInfo.InvariantCulture)); @@ -254,7 +256,9 @@ namespace MediaBrowser.Server.Implementations.Persistence _saveItemCommand.GetParameter(index++).Value = item.GetType().FullName; _saveItemCommand.GetParameter(index++).Value = _jsonSerializer.SerializeToBytes(item); - var hasStartDate = item as IHasStartDate; + _saveItemCommand.GetParameter(index++).Value = item.Path; + + var hasStartDate = item as IHasStartDate; if (hasStartDate != null) { _saveItemCommand.GetParameter(index++).Value = hasStartDate.StartDate; diff --git a/MediaBrowser.Server.Implementations/Sync/SyncManager.cs b/MediaBrowser.Server.Implementations/Sync/SyncManager.cs index 8461176b4..798f37d11 100644 --- a/MediaBrowser.Server.Implementations/Sync/SyncManager.cs +++ b/MediaBrowser.Server.Implementations/Sync/SyncManager.cs @@ -32,6 +32,7 @@ using System.IO; using System.Linq; using System.Threading; using System.Threading.Tasks; +using MediaBrowser.Common.ScheduledTasks; namespace MediaBrowser.Server.Implementations.Sync { @@ -51,7 +52,8 @@ namespace MediaBrowser.Server.Implementations.Sync private readonly IConfigurationManager _config; private readonly IUserDataManager _userDataManager; private readonly Func _mediaSourceManager; - private readonly IJsonSerializer _json; + private readonly IJsonSerializer _json; + private readonly ITaskManager _taskManager; private ISyncProvider[] _providers = { }; @@ -61,7 +63,7 @@ namespace MediaBrowser.Server.Implementations.Sync public event EventHandler> SyncJobItemUpdated; public event EventHandler> SyncJobItemCreated; - public SyncManager(ILibraryManager libraryManager, ISyncRepository repo, IImageProcessor imageProcessor, ILogger logger, IUserManager userManager, Func dtoService, IServerApplicationHost appHost, ITVSeriesManager tvSeriesManager, Func mediaEncoder, IFileSystem fileSystem, Func subtitleEncoder, IConfigurationManager config, IUserDataManager userDataManager, Func mediaSourceManager, IJsonSerializer json) + public SyncManager(ILibraryManager libraryManager, ISyncRepository repo, IImageProcessor imageProcessor, ILogger logger, IUserManager userManager, Func dtoService, IServerApplicationHost appHost, ITVSeriesManager tvSeriesManager, Func mediaEncoder, IFileSystem fileSystem, Func subtitleEncoder, IConfigurationManager config, IUserDataManager userDataManager, Func mediaSourceManager, IJsonSerializer json, ITaskManager taskManager) { _libraryManager = libraryManager; _repo = repo; @@ -78,6 +80,7 @@ namespace MediaBrowser.Server.Implementations.Sync _userDataManager = userDataManager; _mediaSourceManager = mediaSourceManager; _json = json; + _taskManager = taskManager; } public void AddParts(IEnumerable providers) @@ -214,6 +217,10 @@ namespace MediaBrowser.Server.Implementations.Sync }, _logger); } + if (returnResult.JobItems.Any (i => i.Status == SyncJobItemStatus.Queued || i.Status == SyncJobItemStatus.Converting)) { + _taskManager.QueueScheduledTask (); + } + return returnResult; } diff --git a/MediaBrowser.Server.Mac/Emby.Server.Mac.csproj b/MediaBrowser.Server.Mac/Emby.Server.Mac.csproj index 003e63c34..1d28e6656 100644 --- a/MediaBrowser.Server.Mac/Emby.Server.Mac.csproj +++ b/MediaBrowser.Server.Mac/Emby.Server.Mac.csproj @@ -259,9 +259,6 @@ - - Resources\dashboard-ui\.DS_Store - Resources\dashboard-ui\about.html @@ -655,9 +652,6 @@ Resources\dashboard-ui\wizarduser.html - - Resources\dashboard-ui\css\.DS_Store - Resources\dashboard-ui\css\card.css @@ -787,45 +781,6 @@ Resources\dashboard-ui\css\images\userflyoutdefault.png - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_disabled_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_disabled_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_off_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_off_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_0_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_0_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_1_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_1_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_2_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_2_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_holo_dark.png - - - Resources\dashboard-ui\css\images\chromecast\ic_media_route_on_holo_light.png - - - Resources\dashboard-ui\css\images\chromecast\ic_notification_media_route.png - Resources\dashboard-ui\css\images\clients\amazon.png @@ -841,6 +796,9 @@ Resources\dashboard-ui\css\images\clients\chrome_companion.png + + Resources\dashboard-ui\css\images\clients\chromecast.png + Resources\dashboard-ui\css\images\clients\dlna.png @@ -1150,6 +1108,9 @@ Resources\dashboard-ui\scripts\appservices.js + + Resources\dashboard-ui\scripts\appsettings.js + Resources\dashboard-ui\scripts\autoorganizelog.js @@ -1420,6 +1381,9 @@ Resources\dashboard-ui\scripts\musicvideos.js + + Resources\dashboard-ui\scripts\mypreferencescommon.js + Resources\dashboard-ui\scripts\mypreferencesdisplay.js @@ -1600,6 +1564,9 @@ Resources\dashboard-ui\thirdparty\fastclick.js + + Resources\dashboard-ui\thirdparty\filesystem.js + Resources\dashboard-ui\thirdparty\headroom.js @@ -1618,6 +1585,9 @@ Resources\dashboard-ui\thirdparty\requirecss.js + + Resources\dashboard-ui\thirdparty\velocity.min.js + Resources\dashboard-ui\thirdparty\apiclient\ajax.js @@ -1642,6 +1612,9 @@ Resources\dashboard-ui\thirdparty\apiclient\events.js + + Resources\dashboard-ui\thirdparty\apiclient\localassetmanager.js + Resources\dashboard-ui\thirdparty\apiclient\logger.js @@ -1681,9 +1654,15 @@ Resources\dashboard-ui\thirdparty\cordova\externalplayer.js + + Resources\dashboard-ui\thirdparty\cordova\filesystem.js + Resources\dashboard-ui\thirdparty\cordova\generaldevice.js + + Resources\dashboard-ui\thirdparty\cordova\iap.js + Resources\dashboard-ui\thirdparty\cordova\imagestore.js @@ -1696,9 +1675,27 @@ Resources\dashboard-ui\thirdparty\cordova\serverdiscovery.js + + Resources\dashboard-ui\thirdparty\cordova\android\androidcredentials.js + + + Resources\dashboard-ui\thirdparty\cordova\android\filesystem.js + + + Resources\dashboard-ui\thirdparty\cordova\android\iap.js + + + Resources\dashboard-ui\thirdparty\cordova\android\imagestore.js + Resources\dashboard-ui\thirdparty\cordova\android\immersive.js + + Resources\dashboard-ui\thirdparty\cordova\android\localassetmanager.js + + + Resources\dashboard-ui\thirdparty\cordova\ios\orientation.js + Resources\dashboard-ui\thirdparty\fontawesome\css\font-awesome.css @@ -2374,6 +2371,24 @@ Resources\dashboard-ui\thirdparty\jstree3.0.8\themes\default-dark\throbber.gif + + Resources\dashboard-ui\thirdparty\materialicons\MaterialIcons-Regular.eot + + + Resources\dashboard-ui\thirdparty\materialicons\MaterialIcons-Regular.ttf + + + Resources\dashboard-ui\thirdparty\materialicons\MaterialIcons-Regular.woff + + + Resources\dashboard-ui\thirdparty\materialicons\MaterialIcons-Regular.woff2 + + + Resources\dashboard-ui\thirdparty\materialicons\codepoints.txt + + + Resources\dashboard-ui\thirdparty\materialicons\style.css + Resources\dashboard-ui\thirdparty\swipebox-master\css\swipebox.css @@ -2395,5 +2410,11 @@ Resources\dashboard-ui\thirdparty\swipebox-master\js\jquery.swipebox.min.js + + Resources\dashboard-ui\voice\voice.css + + + Resources\dashboard-ui\voice\voice.js + \ No newline at end of file diff --git a/MediaBrowser.Server.Mac/Native/BaseMonoApp.cs b/MediaBrowser.Server.Mac/Native/BaseMonoApp.cs index 57610dfc2..da4675b5e 100644 --- a/MediaBrowser.Server.Mac/Native/BaseMonoApp.cs +++ b/MediaBrowser.Server.Mac/Native/BaseMonoApp.cs @@ -19,7 +19,7 @@ namespace MediaBrowser.Server.Mac /// /// Restarts this instance. /// - public virtual void Restart() + public virtual void Restart(StartupOptions options) { throw new NotImplementedException(); } diff --git a/MediaBrowser.Server.Mac/Native/NativeApp.cs b/MediaBrowser.Server.Mac/Native/NativeApp.cs index 4515be051..005fb0914 100644 --- a/MediaBrowser.Server.Mac/Native/NativeApp.cs +++ b/MediaBrowser.Server.Mac/Native/NativeApp.cs @@ -1,4 +1,5 @@ using System; +using MediaBrowser.Server.Startup.Common; namespace MediaBrowser.Server.Mac { @@ -30,7 +31,7 @@ namespace MediaBrowser.Server.Mac /// /// Restarts this instance. /// - public override void Restart() + public override void Restart(StartupOptions options) { MainClass.Restart(); } diff --git a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs index a8bafcf70..0a5624bdf 100644 --- a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs +++ b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs @@ -447,7 +447,7 @@ namespace MediaBrowser.Server.Startup.Common TVSeriesManager = new TVSeriesManager(UserManager, UserDataManager, LibraryManager); RegisterSingleInstance(TVSeriesManager); - SyncManager = new SyncManager(LibraryManager, SyncRepository, ImageProcessor, LogManager.GetLogger("SyncManager"), UserManager, () => DtoService, this, TVSeriesManager, () => MediaEncoder, FileSystemManager, () => SubtitleEncoder, ServerConfigurationManager, UserDataManager, () => MediaSourceManager, JsonSerializer); + SyncManager = new SyncManager(LibraryManager, SyncRepository, ImageProcessor, LogManager.GetLogger("SyncManager"), UserManager, () => DtoService, this, TVSeriesManager, () => MediaEncoder, FileSystemManager, () => SubtitleEncoder, ServerConfigurationManager, UserDataManager, () => MediaSourceManager, JsonSerializer, TaskManager); RegisterSingleInstance(SyncManager); DtoService = new DtoService(LogManager.GetLogger("DtoService"), LibraryManager, UserDataManager, ItemRepository, ImageProcessor, ServerConfigurationManager, FileSystemManager, ProviderManager, () => ChannelManager, SyncManager, this, () => DeviceManager, () => MediaSourceManager, () => LiveTvManager); diff --git a/MediaBrowser.WebDashboard/Api/PackageCreator.cs b/MediaBrowser.WebDashboard/Api/PackageCreator.cs index ae2b6a764..67f84d8b9 100644 --- a/MediaBrowser.WebDashboard/Api/PackageCreator.cs +++ b/MediaBrowser.WebDashboard/Api/PackageCreator.cs @@ -590,7 +590,6 @@ namespace MediaBrowser.WebDashboard.Api "livetvrecording.js", "livetvtimer.js", "livetvseriestimer.js", - "livetvsettings.js", "medialibrarypage.js", "metadataconfigurationpage.js", @@ -618,9 +617,6 @@ namespace MediaBrowser.WebDashboard.Api "userprofilespage.js", "userparentalcontrol.js", "userlibraryaccess.js", - "wizardagreement.js", - "wizardfinishpage.js", - "wizardservice.js", "wizardstartpage.js" }; }