mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-30 05:46:30 +01:00
add new guide settings
This commit is contained in:
@@ -215,13 +215,26 @@ namespace MediaBrowser.Model.Dlna
|
||||
list.Add(new NameValuePair("MaxWidth", item.MaxWidth.HasValue ? StringHelper.ToStringCultureInvariant(item.MaxWidth.Value) : string.Empty));
|
||||
list.Add(new NameValuePair("MaxHeight", item.MaxHeight.HasValue ? StringHelper.ToStringCultureInvariant(item.MaxHeight.Value) : string.Empty));
|
||||
|
||||
if (StringHelper.EqualsIgnoreCase(item.SubProtocol, "hls"))
|
||||
var forceStartPosition = false;
|
||||
long startPositionTicks = item.StartPositionTicks;
|
||||
//if (item.MediaSource.DateLiveStreamOpened.HasValue && startPositionTicks == 0)
|
||||
//{
|
||||
// var elapsed = DateTime.UtcNow - item.MediaSource.DateLiveStreamOpened.Value;
|
||||
// elapsed -= TimeSpan.FromSeconds(20);
|
||||
// if (elapsed.TotalSeconds >= 0)
|
||||
// {
|
||||
// startPositionTicks = elapsed.Ticks + startPositionTicks;
|
||||
// forceStartPosition = true;
|
||||
// }
|
||||
//}
|
||||
|
||||
if (StringHelper.EqualsIgnoreCase(item.SubProtocol, "hls") && !forceStartPosition)
|
||||
{
|
||||
list.Add(new NameValuePair("StartTimeTicks", string.Empty));
|
||||
}
|
||||
else
|
||||
{
|
||||
list.Add(new NameValuePair("StartTimeTicks", StringHelper.ToStringCultureInvariant(item.StartPositionTicks)));
|
||||
list.Add(new NameValuePair("StartTimeTicks", StringHelper.ToStringCultureInvariant(startPositionTicks)));
|
||||
}
|
||||
|
||||
list.Add(new NameValuePair("Level", item.VideoLevel.HasValue ? StringHelper.ToStringCultureInvariant(item.VideoLevel.Value) : string.Empty));
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
|
||||
using MediaBrowser.Model.Entities;
|
||||
|
||||
namespace MediaBrowser.Model.LiveTv
|
||||
{
|
||||
/// <summary>
|
||||
@@ -85,9 +86,18 @@ namespace MediaBrowser.Model.LiveTv
|
||||
public bool? IsSports { get; set; }
|
||||
public bool? IsSeries { get; set; }
|
||||
|
||||
public string[] SortBy { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The sort order to return results with
|
||||
/// </summary>
|
||||
/// <value>The sort order.</value>
|
||||
public SortOrder? SortOrder { get; set; }
|
||||
|
||||
public LiveTvChannelQuery()
|
||||
{
|
||||
EnableUserData = true;
|
||||
SortBy = new string[] { };
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -60,7 +60,6 @@ namespace MediaBrowser.Model.LiveTv
|
||||
public TunerHostInfo()
|
||||
{
|
||||
IsEnabled = true;
|
||||
AllowHWTranscoding = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user