mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-12 02:30:23 +01:00
rework media versions to be based on original item id
This commit is contained in:
@@ -538,35 +538,26 @@ namespace MediaBrowser.Model.ApiClient
|
||||
/// <summary>
|
||||
/// Reports to the server that the user has begun playing an item
|
||||
/// </summary>
|
||||
/// <param name="itemId">The item id.</param>
|
||||
/// <param name="userId">The user id.</param>
|
||||
/// <param name="isSeekable">if set to <c>true</c> [is seekable].</param>
|
||||
/// <param name="queueableMediaTypes">The list of media types that the client is capable of queuing onto the playlist. See MediaType class.</param>
|
||||
/// <param name="info">The information.</param>
|
||||
/// <returns>Task{UserItemDataDto}.</returns>
|
||||
/// <exception cref="ArgumentNullException">itemId</exception>
|
||||
Task ReportPlaybackStartAsync(string itemId, string userId, bool isSeekable, List<string> queueableMediaTypes);
|
||||
Task ReportPlaybackStartAsync(PlaybackStartInfo info);
|
||||
|
||||
/// <summary>
|
||||
/// Reports playback progress to the server
|
||||
/// </summary>
|
||||
/// <param name="itemId">The item id.</param>
|
||||
/// <param name="userId">The user id.</param>
|
||||
/// <param name="positionTicks">The position ticks.</param>
|
||||
/// <param name="isPaused">if set to <c>true</c> [is paused].</param>
|
||||
/// <param name="isMuted">if set to <c>true</c> [is muted].</param>
|
||||
/// <param name="info">The information.</param>
|
||||
/// <returns>Task{UserItemDataDto}.</returns>
|
||||
/// <exception cref="ArgumentNullException">itemId</exception>
|
||||
Task ReportPlaybackProgressAsync(string itemId, string userId, long? positionTicks, bool isPaused, bool isMuted);
|
||||
Task ReportPlaybackProgressAsync(PlaybackProgressInfo info);
|
||||
|
||||
/// <summary>
|
||||
/// Reports to the server that the user has stopped playing an item
|
||||
/// </summary>
|
||||
/// <param name="itemId">The item id.</param>
|
||||
/// <param name="userId">The user id.</param>
|
||||
/// <param name="positionTicks">The position ticks.</param>
|
||||
/// <param name="info">The information.</param>
|
||||
/// <returns>Task{UserItemDataDto}.</returns>
|
||||
/// <exception cref="ArgumentNullException">itemId</exception>
|
||||
Task ReportPlaybackStoppedAsync(string itemId, string userId, long? positionTicks);
|
||||
Task ReportPlaybackStoppedAsync(PlaybackStopInfo info);
|
||||
|
||||
/// <summary>
|
||||
/// Instructs antoher client to browse to a library item.
|
||||
|
||||
@@ -147,7 +147,7 @@ namespace MediaBrowser.Model.Configuration
|
||||
/// different directories and files.
|
||||
/// </summary>
|
||||
/// <value>The file watcher delay.</value>
|
||||
public int RealtimeWatcherDelay { get; set; }
|
||||
public int RealtimeMonitorDelay { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets a value indicating whether [enable dashboard response caching].
|
||||
@@ -239,7 +239,7 @@ namespace MediaBrowser.Model.Configuration
|
||||
MaxResumePct = 90;
|
||||
MinResumeDurationSeconds = Convert.ToInt32(TimeSpan.FromMinutes(5).TotalSeconds);
|
||||
|
||||
RealtimeWatcherDelay = 20;
|
||||
RealtimeMonitorDelay = 30;
|
||||
|
||||
RecentItemDays = 10;
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace MediaBrowser.Model.Dto
|
||||
{
|
||||
public class MediaVersionInfo
|
||||
{
|
||||
public string ItemId { get; set; }
|
||||
public string Id { get; set; }
|
||||
|
||||
public string Path { get; set; }
|
||||
|
||||
@@ -23,8 +23,6 @@ namespace MediaBrowser.Model.Dto
|
||||
|
||||
public List<MediaStream> MediaStreams { get; set; }
|
||||
|
||||
public List<ChapterInfoDto> Chapters { get; set; }
|
||||
|
||||
public bool IsPrimaryVersion { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,6 +69,12 @@ namespace MediaBrowser.Model.Entities
|
||||
/// </summary>
|
||||
/// <value>The thumb item identifier.</value>
|
||||
public string BackdropItemId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the media version identifier.
|
||||
/// </summary>
|
||||
/// <value>The media version identifier.</value>
|
||||
public string MediaVersionId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets a value indicating whether this instance has primary image.
|
||||
|
||||
@@ -132,6 +132,7 @@
|
||||
<Compile Include="Search\SearchQuery.cs" />
|
||||
<Compile Include="Session\BrowseRequest.cs" />
|
||||
<Compile Include="Session\MessageCommand.cs" />
|
||||
<Compile Include="Session\PlaybackReports.cs" />
|
||||
<Compile Include="Session\PlayRequest.cs" />
|
||||
<Compile Include="Session\PlaystateCommand.cs" />
|
||||
<Compile Include="Logging\ILogManager.cs" />
|
||||
|
||||
56
MediaBrowser.Model/Session/PlaybackReports.cs
Normal file
56
MediaBrowser.Model/Session/PlaybackReports.cs
Normal file
@@ -0,0 +1,56 @@
|
||||
|
||||
namespace MediaBrowser.Model.Session
|
||||
{
|
||||
/// <summary>
|
||||
/// Class PlaybackStartInfo.
|
||||
/// </summary>
|
||||
public class PlaybackStartInfo
|
||||
{
|
||||
public string UserId { get; set; }
|
||||
|
||||
public string ItemId { get; set; }
|
||||
|
||||
public string MediaVersionId { get; set; }
|
||||
|
||||
public bool IsSeekable { get; set; }
|
||||
|
||||
public string[] QueueableMediaTypes { get; set; }
|
||||
|
||||
public PlaybackStartInfo()
|
||||
{
|
||||
QueueableMediaTypes = new string[] { };
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Class PlaybackProgressInfo.
|
||||
/// </summary>
|
||||
public class PlaybackProgressInfo
|
||||
{
|
||||
public string UserId { get; set; }
|
||||
|
||||
public string ItemId { get; set; }
|
||||
|
||||
public string MediaVersionId { get; set; }
|
||||
|
||||
public long? PositionTicks { get; set; }
|
||||
|
||||
public bool IsPaused { get; set; }
|
||||
|
||||
public bool IsMuted { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Class PlaybackStopInfo.
|
||||
/// </summary>
|
||||
public class PlaybackStopInfo
|
||||
{
|
||||
public string UserId { get; set; }
|
||||
|
||||
public string ItemId { get; set; }
|
||||
|
||||
public string MediaVersionId { get; set; }
|
||||
|
||||
public long? PositionTicks { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -7,6 +7,10 @@ namespace MediaBrowser.Model.Session
|
||||
|
||||
public bool SupportsFullscreenToggle { get; set; }
|
||||
|
||||
public bool SupportsOsdToggle { get; set; }
|
||||
|
||||
public bool SupportsNavigationControl { get; set; }
|
||||
|
||||
public SessionCapabilities()
|
||||
{
|
||||
PlayableMediaTypes = new string[] {};
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
using System.Diagnostics;
|
||||
using MediaBrowser.Model.Entities;
|
||||
using MediaBrowser.Model.Entities;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace MediaBrowser.Model.Session
|
||||
{
|
||||
@@ -147,6 +147,18 @@ namespace MediaBrowser.Model.Session
|
||||
/// <value><c>true</c> if [supports remote control]; otherwise, <c>false</c>.</value>
|
||||
public bool SupportsRemoteControl { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets a value indicating whether [supports osd toggle].
|
||||
/// </summary>
|
||||
/// <value><c>true</c> if [supports osd toggle]; otherwise, <c>false</c>.</value>
|
||||
public bool SupportsOsdToggle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets a value indicating whether [supports navigation commands].
|
||||
/// </summary>
|
||||
/// <value><c>true</c> if [supports navigation commands]; otherwise, <c>false</c>.</value>
|
||||
public bool SupportsNavigationControl { get; set; }
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
public SessionInfoDto()
|
||||
|
||||
Reference in New Issue
Block a user