From b11d06f36f31317f072e6cd1a27bd7d06b5f0c17 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Wed, 1 May 2013 22:44:52 -0400 Subject: more work on streaming remotely --- MediaBrowser.Controller/Entities/BasePluginFolder.cs | 13 +++++++++++++ MediaBrowser.Controller/Entities/Video.cs | 7 +++++++ .../Providers/ImageFromMediaLocationProvider.cs | 5 ++--- 3 files changed, 22 insertions(+), 3 deletions(-) (limited to 'MediaBrowser.Controller') diff --git a/MediaBrowser.Controller/Entities/BasePluginFolder.cs b/MediaBrowser.Controller/Entities/BasePluginFolder.cs index ca6cfd246f..bf8040a9fe 100644 --- a/MediaBrowser.Controller/Entities/BasePluginFolder.cs +++ b/MediaBrowser.Controller/Entities/BasePluginFolder.cs @@ -29,8 +29,21 @@ namespace MediaBrowser.Controller.Entities { base.Id = value; } + } + + /// + /// Gets or sets the type of the location. + /// + /// The type of the location. + public override LocationType LocationType + { + get + { + return LocationType.Virtual; + } } + /// /// We don't resolve normally so need to fill this in /// diff --git a/MediaBrowser.Controller/Entities/Video.cs b/MediaBrowser.Controller/Entities/Video.cs index b3ed21b19a..bac29f0f5a 100644 --- a/MediaBrowser.Controller/Entities/Video.cs +++ b/MediaBrowser.Controller/Entities/Video.cs @@ -11,6 +11,13 @@ namespace MediaBrowser.Controller.Entities /// public class Video : BaseItem, IHasMediaStreams { + public Video() + { + MediaStreams = new List(); + Chapters = new List(); + PlayableStreamFileNames = new List(); + } + /// /// Gets or sets the type of the video. /// diff --git a/MediaBrowser.Controller/Providers/ImageFromMediaLocationProvider.cs b/MediaBrowser.Controller/Providers/ImageFromMediaLocationProvider.cs index cb3445dd3d..5a9f5890e2 100644 --- a/MediaBrowser.Controller/Providers/ImageFromMediaLocationProvider.cs +++ b/MediaBrowser.Controller/Providers/ImageFromMediaLocationProvider.cs @@ -1,14 +1,13 @@ using MediaBrowser.Controller.Configuration; using MediaBrowser.Controller.Entities; -using MediaBrowser.Controller.IO; using MediaBrowser.Model.Entities; +using MediaBrowser.Model.Logging; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Threading; using System.Threading.Tasks; -using MediaBrowser.Model.Logging; namespace MediaBrowser.Controller.Providers { @@ -29,7 +28,7 @@ namespace MediaBrowser.Controller.Providers /// true if XXXX, false otherwise public override bool Supports(BaseItem item) { - return item.ResolveArgs.IsDirectory && item.LocationType == LocationType.FileSystem; + return item.LocationType == LocationType.FileSystem && item.ResolveArgs.IsDirectory; } /// -- cgit v1.2.3