move prescan tasks to postscan

This commit is contained in:
Luke Pulverenti 2013-12-08 17:09:06 -05:00
parent 91b5a8101f
commit 3c9b0a1fb6
6 changed files with 9 additions and 9 deletions

View File

@ -130,7 +130,7 @@ namespace MediaBrowser.Controller.Library
{
get
{
return IsDirectory && Path.Equals(_appPaths.RootFolderPath, StringComparison.OrdinalIgnoreCase);
return IsDirectory && string.Equals(Path, _appPaths.RootFolderPath, StringComparison.OrdinalIgnoreCase);
}
}

View File

@ -16,7 +16,7 @@ using System.Threading.Tasks;
namespace MediaBrowser.Providers.Movies
{
class FanArtMovieUpdatesPrescanTask : ILibraryPrescanTask
class FanArtMovieUpdatesPrescanTask : ILibraryPostScanTask
{
private const string UpdatesUrl = "http://api.fanart.tv/webservice/newmovies/{0}/{1}/";

View File

@ -16,7 +16,7 @@ using System.Threading.Tasks;
namespace MediaBrowser.Providers.Movies
{
public class MovieUpdatesPreScanTask : ILibraryPrescanTask
public class MovieUpdatesPreScanTask : ILibraryPostScanTask
{
/// <summary>
/// The updates URL

View File

@ -15,7 +15,7 @@ using System.Threading.Tasks;
namespace MediaBrowser.Providers.Music
{
class FanArtUpdatesPrescanTask : ILibraryPrescanTask
class FanArtUpdatesPrescanTask : ILibraryPostScanTask
{
private const string UpdatesUrl = "http://api.fanart.tv/webservice/newmusic/{0}/{1}/";

View File

@ -16,7 +16,7 @@ using System.Threading.Tasks;
namespace MediaBrowser.Providers.TV
{
class FanArtTvUpdatesPrescanTask : ILibraryPrescanTask
class FanArtTvUpdatesPrescanTask : ILibraryPostScanTask
{
private const string UpdatesUrl = "http://api.fanart.tv/webservice/newtv/{0}/{1}/";

View File

@ -88,7 +88,7 @@ namespace MediaBrowser.ServerApplication
Cursor = Cursors.Wait;
await Task.Run(() =>
{
IEnumerable<BaseItem> children = CurrentUser.Name == "Physical" ? _libraryManager.RootFolder.Children : _libraryManager.RootFolder.GetChildren(CurrentUser, true);
IEnumerable<BaseItem> children = CurrentUser.Name == "Physical" ? new[] { _libraryManager.RootFolder } : _libraryManager.RootFolder.GetChildren(CurrentUser, true);
children = OrderByName(children, CurrentUser);
foreach (Folder folder in children)
@ -237,9 +237,9 @@ namespace MediaBrowser.ServerApplication
{
previews.Add(new PreviewItem(item.GetImage(ImageType.Thumb), "Thumb"));
}
previews.AddRange(
item.BackdropImagePaths.Select(
image => new PreviewItem(image, "Backdrop")));
previews.AddRange(
item.BackdropImagePaths.Select(
image => new PreviewItem(image, "Backdrop")));
});
lstPreviews.ItemsSource = previews;
lstPreviews.Items.Refresh();