diff options
Diffstat (limited to 'MediaBrowser.Controller/Entities/Video.cs')
| -rw-r--r-- | MediaBrowser.Controller/Entities/Video.cs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/MediaBrowser.Controller/Entities/Video.cs b/MediaBrowser.Controller/Entities/Video.cs index dc9769d53f..f4104b29d1 100644 --- a/MediaBrowser.Controller/Entities/Video.cs +++ b/MediaBrowser.Controller/Entities/Video.cs @@ -129,6 +129,7 @@ namespace MediaBrowser.Controller.Entities public bool IsPlaceHolder { get; set; } public bool IsShortcut { get; set; } + public string ShortcutPath { get; set; } /// <summary> /// Gets or sets the tags. @@ -578,6 +579,28 @@ namespace MediaBrowser.Controller.Entities PlayableStreamFileNames = i.PlayableStreamFileNames.ToList() }; + if (i.IsShortcut) + { + info.Path = i.ShortcutPath; + + if (info.Path.StartsWith("Http", StringComparison.OrdinalIgnoreCase)) + { + info.Protocol = MediaProtocol.Http; + } + else if (info.Path.StartsWith("Rtmp", StringComparison.OrdinalIgnoreCase)) + { + info.Protocol = MediaProtocol.Rtmp; + } + else if (info.Path.StartsWith("Rtsp", StringComparison.OrdinalIgnoreCase)) + { + info.Protocol = MediaProtocol.Rtsp; + } + else + { + info.Protocol = MediaProtocol.File; + } + } + if (string.IsNullOrEmpty(info.Container)) { if (i.VideoType == VideoType.VideoFile || i.VideoType == VideoType.Iso) |
