From b4ac51aa1052c895ade917c5b4d314c09d3b29d8 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sun, 5 Jan 2014 20:59:21 -0500 Subject: Added SupportsAutoRunAtStartup --- MediaBrowser.Controller/IServerApplicationHost.cs | 6 ++++++ MediaBrowser.Controller/LiveTv/LiveTvAudioRecording.cs | 9 ++++++++- MediaBrowser.Controller/LiveTv/LiveTvVideoRecording.cs | 9 ++++++++- 3 files changed, 22 insertions(+), 2 deletions(-) (limited to 'MediaBrowser.Controller') diff --git a/MediaBrowser.Controller/IServerApplicationHost.cs b/MediaBrowser.Controller/IServerApplicationHost.cs index f96c2536e6..f3312d2cb8 100644 --- a/MediaBrowser.Controller/IServerApplicationHost.cs +++ b/MediaBrowser.Controller/IServerApplicationHost.cs @@ -25,5 +25,11 @@ namespace MediaBrowser.Controller /// /// The HTTP server URL prefix. string HttpServerUrlPrefix { get; } + + /// + /// Gets a value indicating whether [supports automatic run at startup]. + /// + /// true if [supports automatic run at startup]; otherwise, false. + bool SupportsAutoRunAtStartup { get; } } } diff --git a/MediaBrowser.Controller/LiveTv/LiveTvAudioRecording.cs b/MediaBrowser.Controller/LiveTv/LiveTvAudioRecording.cs index 8676540fd0..93de9d5c34 100644 --- a/MediaBrowser.Controller/LiveTv/LiveTvAudioRecording.cs +++ b/MediaBrowser.Controller/LiveTv/LiveTvAudioRecording.cs @@ -11,7 +11,14 @@ namespace MediaBrowser.Controller.LiveTv /// System.String. public override string GetUserDataKey() { - return GetClientTypeName() + "-" + Name; + var name = GetClientTypeName(); + + if (!string.IsNullOrEmpty(RecordingInfo.ProgramId)) + { + return name + "-" + RecordingInfo.ProgramId; + } + + return name + "-" + RecordingInfo.Name + (RecordingInfo.EpisodeTitle ?? string.Empty); } public RecordingInfo RecordingInfo { get; set; } diff --git a/MediaBrowser.Controller/LiveTv/LiveTvVideoRecording.cs b/MediaBrowser.Controller/LiveTv/LiveTvVideoRecording.cs index 9dfc7f828d..bc4ed54934 100644 --- a/MediaBrowser.Controller/LiveTv/LiveTvVideoRecording.cs +++ b/MediaBrowser.Controller/LiveTv/LiveTvVideoRecording.cs @@ -11,7 +11,14 @@ namespace MediaBrowser.Controller.LiveTv /// System.String. public override string GetUserDataKey() { - return GetClientTypeName() + "-" + Name; + var name = GetClientTypeName(); + + if (!string.IsNullOrEmpty(RecordingInfo.ProgramId)) + { + return name + "-" + RecordingInfo.ProgramId; + } + + return name + "-" + RecordingInfo.Name + (RecordingInfo.EpisodeTitle ?? string.Empty); } public RecordingInfo RecordingInfo { get; set; } -- cgit v1.2.3