mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-06-29 02:13:36 +02:00
parent
321c440739
commit
38f96af079
|
@ -101,7 +101,7 @@ namespace MediaBrowser.Api
|
|||
{
|
||||
lock (_transcodingLocks)
|
||||
{
|
||||
if (!_transcodingLocks.TryGetValue(outputPath, out var result))
|
||||
if (!_transcodingLocks.TryGetValue(outputPath, out SemaphoreSlim result))
|
||||
{
|
||||
result = new SemaphoreSlim(1, 1);
|
||||
_transcodingLocks[outputPath] = result;
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Api
|
||||
{
|
||||
public interface IHasDtoOptions : IHasItemFields
|
||||
|
|
|
@ -902,7 +902,7 @@ namespace MediaBrowser.Api.Library
|
|||
|
||||
var dtoOptions = GetDtoOptions(_authContext, request);
|
||||
|
||||
var parent = item.GetParent();
|
||||
BaseItem parent = item.GetParent();
|
||||
|
||||
while (parent != null)
|
||||
{
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Common.Configuration
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Channels
|
||||
{
|
||||
public interface IHasCacheKey
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Connect
|
||||
{
|
||||
public class UserLinkResult
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Drawing
|
||||
{
|
||||
public class ImageCollageOptions
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities.Audio
|
||||
{
|
||||
public interface IHasAlbumArtist
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
using MediaBrowser.Model.Serialization;
|
||||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
|
|
|
@ -331,7 +331,7 @@ namespace MediaBrowser.Controller.Entities
|
|||
|
||||
foreach (var child in nonCachedChildren)
|
||||
{
|
||||
if (currentChildren.TryGetValue(child.Id, out var currentChild))
|
||||
if (currentChildren.TryGetValue(child.Id, out BaseItem currentChild))
|
||||
{
|
||||
validChildren.Add(currentChild);
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
using System;
|
||||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
public interface ISupportsPlaceHolders
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
public enum SourceType
|
||||
|
|
|
@ -64,9 +64,9 @@ namespace MediaBrowser.Controller.Entities
|
|||
|
||||
public int? GetYearValue()
|
||||
{
|
||||
if (int.TryParse(Name, NumberStyles.Integer, CultureInfo.InvariantCulture, out var i))
|
||||
if (int.TryParse(Name, NumberStyles.Integer, CultureInfo.InvariantCulture, out var year))
|
||||
{
|
||||
return i;
|
||||
return year;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Library
|
||||
{
|
||||
public class DeleteOptions
|
||||
|
|
|
@ -114,12 +114,15 @@ namespace MediaBrowser.Controller.LiveTv
|
|||
/// </summary>
|
||||
/// <value>The episode number.</value>
|
||||
public int? EpisodeNumber { get; set; }
|
||||
|
||||
public bool IsMovie { get; set; }
|
||||
|
||||
public bool IsKids => Tags.Contains("Kids", StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
public bool IsSports => Tags.Contains("Sports", StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
public bool IsNews => Tags.Contains("News", StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
public bool IsSeries { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -133,10 +136,15 @@ namespace MediaBrowser.Controller.LiveTv
|
|||
public bool IsPremiere => Tags.Contains("Premiere", StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
public int? ProductionYear { get; set; }
|
||||
|
||||
public string EpisodeTitle { get; set; }
|
||||
|
||||
public DateTime? OriginalAirDate { get; set; }
|
||||
|
||||
public bool IsProgramSeries { get; set; }
|
||||
|
||||
public bool IsRepeat { get; set; }
|
||||
|
||||
public string HomePageUrl { get; set; }
|
||||
public float? CommunityRating { get; set; }
|
||||
public string OfficialRating { get; set; }
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.MediaEncoding
|
||||
{
|
||||
public class ImageEncodingOptions
|
||||
|
|
|
@ -25,7 +25,7 @@ namespace MediaBrowser.Controller.Providers
|
|||
|
||||
public FileSystemMetadata[] GetFileSystemEntries(string path)
|
||||
{
|
||||
if (!_cache.TryGetValue(path, out var entries))
|
||||
if (!_cache.TryGetValue(path, out FileSystemMetadata[] entries))
|
||||
{
|
||||
//_logger.LogDebug("Getting files for " + path);
|
||||
|
||||
|
@ -54,7 +54,7 @@ namespace MediaBrowser.Controller.Providers
|
|||
|
||||
public FileSystemMetadata GetFile(string path)
|
||||
{
|
||||
if (!_fileCache.TryGetValue(path, out var file))
|
||||
if (!_fileCache.TryGetValue(path, out FileSystemMetadata file))
|
||||
{
|
||||
file = _fileSystem.GetFileInfo(path);
|
||||
|
||||
|
@ -80,7 +80,7 @@ namespace MediaBrowser.Controller.Providers
|
|||
|
||||
public List<string> GetFilePaths(string path, bool clearCache)
|
||||
{
|
||||
if (clearCache || !_filePathCache.TryGetValue(path, out var result))
|
||||
if (clearCache || !_filePathCache.TryGetValue(path, out List<string> result))
|
||||
{
|
||||
result = _fileSystem.GetFilePaths(path).ToList();
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Providers
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Providers
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Providers
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
using MediaBrowser.Controller.Entities;
|
||||
using MediaBrowser.Model.IO;
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Resolvers
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Security
|
||||
{
|
||||
public interface IEncryptionManager
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Controller.Sync
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -69,6 +69,7 @@ namespace MediaBrowser.LocalMetadata
|
|||
|
||||
public string Name => XmlProviderUtils.Name;
|
||||
|
||||
//After Nfo
|
||||
public virtual int Order => 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@ namespace MediaBrowser.LocalMetadata.Images
|
|||
return item is CollectionFolder && item.SupportsLocalMetadata;
|
||||
}
|
||||
|
||||
// Run after LocalImageProvider
|
||||
public int Order => 1;
|
||||
|
||||
public List<LocalImageInfo> GetImages(BaseItem item, IDirectoryService directoryService)
|
||||
|
|
|
@ -46,7 +46,7 @@ namespace MediaBrowser.LocalMetadata.Images
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Make sure this is last so that all other locations are scanned first
|
||||
public int Order => 1000;
|
||||
|
||||
public List<LocalImageInfo> GetImages(BaseItem item, IDirectoryService directoryService)
|
||||
|
|
|
@ -96,7 +96,7 @@ namespace MediaBrowser.LocalMetadata.Images
|
|||
|
||||
public List<LocalImageInfo> GetImages(BaseItem item, IEnumerable<string> paths, bool arePathsInMediaFolders, IDirectoryService directoryService)
|
||||
{
|
||||
var files = paths.SelectMany(i => _fileSystem.GetFiles(i, BaseItem.SupportedImageExtensions, true, false));
|
||||
IEnumerable<FileSystemMetadata> files = paths.SelectMany(i => _fileSystem.GetFiles(i, BaseItem.SupportedImageExtensions, true, false));
|
||||
|
||||
files = files
|
||||
.OrderBy(i => Array.IndexOf(BaseItem.SupportedImageExtensions, i.Extension ?? string.Empty));
|
||||
|
|
|
@ -676,7 +676,7 @@ namespace MediaBrowser.LocalMetadata.Parsers
|
|||
default:
|
||||
{
|
||||
string readerName = reader.Name;
|
||||
if (_validProviderIds.TryGetValue(readerName, out var providerIdValue))
|
||||
if (_validProviderIds.TryGetValue(readerName, out string providerIdValue))
|
||||
{
|
||||
var id = reader.ReadElementContentAsString();
|
||||
if (!string.IsNullOrWhiteSpace(id))
|
||||
|
|
|
@ -152,7 +152,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
|||
|
||||
private string GetProcessOutput(string path, string arguments)
|
||||
{
|
||||
var process = _processFactory.Create(new ProcessOptions
|
||||
IProcess process = _processFactory.Create(new ProcessOptions
|
||||
{
|
||||
CreateNoWindow = true,
|
||||
UseShellExecute = false,
|
||||
|
|
|
@ -1193,7 +1193,7 @@ namespace MediaBrowser.MediaEncoding.Probing
|
|||
|
||||
if (chapter.tags != null)
|
||||
{
|
||||
if (chapter.tags.TryGetValue("title", out var name))
|
||||
if (chapter.tags.TryGetValue("title", out string name))
|
||||
{
|
||||
info.Name = name;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.ApiClient
|
||||
{
|
||||
public class ServerDiscoveryInfo
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Branding
|
||||
{
|
||||
public class BrandingOptions
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Channels
|
||||
{
|
||||
public class ChannelInfo
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public class AccessSchedule
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public enum DynamicDayOfWeek
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public class EncodingOptions
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public class FanartOptions
|
||||
|
|
|
@ -108,7 +108,7 @@ namespace MediaBrowser.Model.Configuration
|
|||
}
|
||||
}
|
||||
|
||||
if (DefaultImageOptions.TryGetValue(Type, out var options))
|
||||
if (DefaultImageOptions.TryGetValue(Type, out ImageOption[] options))
|
||||
{
|
||||
foreach (var i in options)
|
||||
{
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public class MetadataConfiguration
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Configuration
|
||||
{
|
||||
public class XbmcMetadataOptions
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Connect
|
||||
{
|
||||
public class ConnectUser
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Connect
|
||||
{
|
||||
public class ConnectUserQuery
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Connect
|
||||
{
|
||||
public enum UserLinkType
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
using System;
|
||||
|
||||
namespace MediaBrowser.Model.Devices
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Devices
|
||||
{
|
||||
public class LocalFileInfo
|
||||
|
|
|
@ -31,7 +31,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
string dlnaflags = string.Format(";DLNA.ORG_FLAGS={0}",
|
||||
DlnaMaps.FlagsToString(flagValue));
|
||||
|
||||
var mediaProfile = _profile.GetImageMediaProfile(container,
|
||||
ResponseProfile mediaProfile = _profile.GetImageMediaProfile(container,
|
||||
width,
|
||||
height);
|
||||
|
||||
|
@ -83,7 +83,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
string dlnaflags = string.Format(";DLNA.ORG_FLAGS={0}",
|
||||
DlnaMaps.FlagsToString(flagValue));
|
||||
|
||||
var mediaProfile = _profile.GetAudioMediaProfile(container,
|
||||
ResponseProfile mediaProfile = _profile.GetAudioMediaProfile(container,
|
||||
audioCodec,
|
||||
audioChannels,
|
||||
audioBitrate,
|
||||
|
@ -148,7 +148,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
string dlnaflags = string.Format(";DLNA.ORG_FLAGS={0}",
|
||||
DlnaMaps.FlagsToString(flagValue));
|
||||
|
||||
var mediaProfile = _profile.GetVideoMediaProfile(container,
|
||||
ResponseProfile mediaProfile = _profile.GetVideoMediaProfile(container,
|
||||
audioCodec,
|
||||
videoCodec,
|
||||
width,
|
||||
|
|
|
@ -191,7 +191,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
var conditionProcessor = new ConditionProcessor();
|
||||
|
||||
var anyOff = false;
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsAudioConditionSatisfied(GetModelProfileCondition(c), audioChannels, audioBitrate, audioSampleRate, audioBitDepth))
|
||||
{
|
||||
|
@ -304,7 +304,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
var conditionProcessor = new ConditionProcessor();
|
||||
|
||||
var anyOff = false;
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoConditionSatisfied(GetModelProfileCondition(c), width, height, bitDepth, videoBitrate, videoProfile, videoLevel, videoFramerate, packetLength, timestamp, isAnamorphic, isInterlaced, refFrames, numVideoStreams, numAudioStreams, videoCodecTag, isAvc))
|
||||
{
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dlna
|
||||
{
|
||||
public class DeviceProfileInfo
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dlna
|
||||
{
|
||||
public enum MediaFormatProfile
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dlna
|
||||
{
|
||||
public enum PlaybackErrorCode
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
ValidateAudioInput(options);
|
||||
|
||||
var mediaSources = new List<MediaSourceInfo>();
|
||||
foreach (var i in options.MediaSources)
|
||||
foreach (MediaSourceInfo i in options.MediaSources)
|
||||
{
|
||||
if (string.IsNullOrEmpty(options.MediaSourceId) ||
|
||||
StringHelper.EqualsIgnoreCase(i.Id, options.MediaSourceId))
|
||||
|
@ -42,16 +42,16 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
|
||||
var streams = new List<StreamInfo>();
|
||||
foreach (var i in mediaSources)
|
||||
foreach (MediaSourceInfo i in mediaSources)
|
||||
{
|
||||
var streamInfo = BuildAudioItem(i, options);
|
||||
StreamInfo streamInfo = BuildAudioItem(i, options);
|
||||
if (streamInfo != null)
|
||||
{
|
||||
streams.Add(streamInfo);
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var stream in streams)
|
||||
foreach (StreamInfo stream in streams)
|
||||
{
|
||||
stream.DeviceId = options.DeviceId;
|
||||
stream.DeviceProfileId = options.Profile.Id;
|
||||
|
@ -65,7 +65,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
ValidateInput(options);
|
||||
|
||||
var mediaSources = new List<MediaSourceInfo>();
|
||||
foreach (var i in options.MediaSources)
|
||||
foreach (MediaSourceInfo i in options.MediaSources)
|
||||
{
|
||||
if (string.IsNullOrEmpty(options.MediaSourceId) ||
|
||||
StringHelper.EqualsIgnoreCase(i.Id, options.MediaSourceId))
|
||||
|
@ -75,7 +75,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
|
||||
var streams = new List<StreamInfo>();
|
||||
foreach (var i in mediaSources)
|
||||
foreach (MediaSourceInfo i in mediaSources)
|
||||
{
|
||||
var streamInfo = BuildVideoItem(i, options);
|
||||
if (streamInfo != null)
|
||||
|
@ -84,7 +84,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
}
|
||||
|
||||
foreach (var stream in streams)
|
||||
foreach (StreamInfo stream in streams)
|
||||
{
|
||||
stream.DeviceId = options.DeviceId;
|
||||
stream.DeviceProfileId = options.Profile.Id;
|
||||
|
@ -97,7 +97,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
{
|
||||
var sorted = SortMediaSources(streams, maxBitrate);
|
||||
|
||||
foreach (var stream in sorted)
|
||||
foreach (StreamInfo stream in sorted)
|
||||
{
|
||||
return stream;
|
||||
}
|
||||
|
@ -333,7 +333,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
if (i.Type == CodecType.Audio && i.ContainsAnyCodec(audioCodec, item.Container))
|
||||
{
|
||||
bool applyConditions = true;
|
||||
foreach (var applyCondition in i.ApplyConditions)
|
||||
foreach (ProfileCondition applyCondition in i.ApplyConditions)
|
||||
{
|
||||
if (!conditionProcessor.IsAudioConditionSatisfied(applyCondition, inputAudioChannels, inputAudioBitrate, inputAudioSampleRate, inputAudioBitDepth))
|
||||
{
|
||||
|
@ -345,7 +345,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
|
||||
if (applyConditions)
|
||||
{
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
conditions.Add(c);
|
||||
}
|
||||
|
@ -354,7 +354,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
|
||||
bool all = true;
|
||||
foreach (var c in conditions)
|
||||
foreach (ProfileCondition c in conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsAudioConditionSatisfied(c, inputAudioChannels, inputAudioBitrate, inputAudioSampleRate, inputAudioBitDepth))
|
||||
{
|
||||
|
@ -431,7 +431,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
|
||||
if (applyConditions)
|
||||
{
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
audioTranscodingConditions.Add(c);
|
||||
}
|
||||
|
@ -811,7 +811,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
if (i.Type == CodecType.Video && i.ContainsAnyCodec(transcodingProfile.VideoCodec, transcodingProfile.Container))
|
||||
{
|
||||
bool applyConditions = true;
|
||||
foreach (var applyCondition in i.ApplyConditions)
|
||||
foreach (ProfileCondition applyCondition in i.ApplyConditions)
|
||||
{
|
||||
int? width = videoStream == null ? null : videoStream.Width;
|
||||
int? height = videoStream == null ? null : videoStream.Height;
|
||||
|
@ -867,7 +867,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
if (i.Type == CodecType.VideoAudio && i.ContainsAnyCodec(transcodingProfile.AudioCodec, transcodingProfile.Container))
|
||||
{
|
||||
bool applyConditions = true;
|
||||
foreach (var applyCondition in i.ApplyConditions)
|
||||
foreach (ProfileCondition applyCondition in i.ApplyConditions)
|
||||
{
|
||||
bool? isSecondaryAudio = audioStream == null ? null : item.IsSecondaryAudio(audioStream);
|
||||
int? inputAudioBitrate = audioStream == null ? null : audioStream.BitRate;
|
||||
|
@ -997,7 +997,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
bool isEligibleForDirectPlay,
|
||||
bool isEligibleForDirectStream)
|
||||
{
|
||||
var profile = options.Profile;
|
||||
DeviceProfile profile = options.Profile;
|
||||
|
||||
if (options.ForceDirectPlay)
|
||||
{
|
||||
|
@ -1071,7 +1071,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
int? numVideoStreams = mediaSource.GetStreamCount(MediaStreamType.Video);
|
||||
|
||||
// Check container conditions
|
||||
foreach (var i in conditions)
|
||||
foreach (ProfileCondition i in conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoConditionSatisfied(i, width, height, bitDepth, videoBitrate, videoProfile, videoLevel, videoFramerate, packetLength, timestamp, isAnamorphic, isInterlaced, refFrames, numVideoStreams, numAudioStreams, videoCodecTag, isAvc))
|
||||
{
|
||||
|
@ -1094,7 +1094,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
if (i.Type == CodecType.Video && i.ContainsAnyCodec(videoCodec, container))
|
||||
{
|
||||
bool applyConditions = true;
|
||||
foreach (var applyCondition in i.ApplyConditions)
|
||||
foreach (ProfileCondition applyCondition in i.ApplyConditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoConditionSatisfied(applyCondition, width, height, bitDepth, videoBitrate, videoProfile, videoLevel, videoFramerate, packetLength, timestamp, isAnamorphic, isInterlaced, refFrames, numVideoStreams, numAudioStreams, videoCodecTag, isAvc))
|
||||
{
|
||||
|
@ -1106,7 +1106,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
|
||||
if (applyConditions)
|
||||
{
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
conditions.Add(c);
|
||||
}
|
||||
|
@ -1114,7 +1114,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
}
|
||||
|
||||
foreach (var i in conditions)
|
||||
foreach (ProfileCondition i in conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoConditionSatisfied(i, width, height, bitDepth, videoBitrate, videoProfile, videoLevel, videoFramerate, packetLength, timestamp, isAnamorphic, isInterlaced, refFrames, numVideoStreams, numAudioStreams, videoCodecTag, isAvc))
|
||||
{
|
||||
|
@ -1141,7 +1141,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
if (i.Type == CodecType.VideoAudio && i.ContainsAnyCodec(audioCodec, container))
|
||||
{
|
||||
bool applyConditions = true;
|
||||
foreach (var applyCondition in i.ApplyConditions)
|
||||
foreach (ProfileCondition applyCondition in i.ApplyConditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoAudioConditionSatisfied(applyCondition, audioChannels, audioBitrate, audioSampleRate, audioBitDepth, audioProfile, isSecondaryAudio))
|
||||
{
|
||||
|
@ -1153,7 +1153,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
|
||||
if (applyConditions)
|
||||
{
|
||||
foreach (var c in i.Conditions)
|
||||
foreach (ProfileCondition c in i.Conditions)
|
||||
{
|
||||
conditions.Add(c);
|
||||
}
|
||||
|
@ -1161,7 +1161,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
}
|
||||
|
||||
foreach (var i in conditions)
|
||||
foreach (ProfileCondition i in conditions)
|
||||
{
|
||||
if (!conditionProcessor.IsVideoAudioConditionSatisfied(i, audioChannels, audioBitrate, audioSampleRate, audioBitDepth, audioProfile, isSecondaryAudio))
|
||||
{
|
||||
|
@ -1466,7 +1466,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
|
||||
private void ApplyTranscodingConditions(StreamInfo item, IEnumerable<ProfileCondition> conditions, string qualifier, bool enableQualifiedConditions, bool enableNonQualifiedConditions)
|
||||
{
|
||||
foreach (var condition in conditions)
|
||||
foreach (ProfileCondition condition in conditions)
|
||||
{
|
||||
string value = condition.Value;
|
||||
|
||||
|
|
|
@ -145,7 +145,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
}
|
||||
|
||||
var list = new List<string>();
|
||||
foreach (var pair in BuildParams(this, accessToken))
|
||||
foreach (NameValuePair pair in BuildParams(this, accessToken))
|
||||
{
|
||||
if (string.IsNullOrEmpty(pair.Value))
|
||||
{
|
||||
|
@ -349,7 +349,7 @@ namespace MediaBrowser.Model.Dlna
|
|||
var newList = new List<SubtitleStreamInfo>();
|
||||
|
||||
// First add the selected track
|
||||
foreach (var stream in list)
|
||||
foreach (SubtitleStreamInfo stream in list)
|
||||
{
|
||||
if (stream.DeliveryMethod == SubtitleDeliveryMethod.External)
|
||||
{
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Drawing
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Drawing
|
||||
{
|
||||
public enum ImageOrientation
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dto
|
||||
{
|
||||
public interface IHasServerId
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dto
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dto
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Dto
|
||||
{
|
||||
public class NameValuePair
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
public class EmptyRequestResult
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
public enum ExtraType
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
public class MediaUrl
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -48,7 +48,7 @@ namespace MediaBrowser.Model.Entities
|
|||
return null;
|
||||
}
|
||||
|
||||
instance.ProviderIds.TryGetValue(name, out var id);
|
||||
instance.ProviderIds.TryGetValue(name, out string id);
|
||||
return id;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
public enum Video3DFormat
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Entities
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Globalization
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.IO
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.IO
|
||||
{
|
||||
public interface IShortcutHandler
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.IO
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Library
|
||||
{
|
||||
public enum PlayAccess
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.LiveTv
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.LiveTv
|
||||
{
|
||||
public enum RecordingStatus
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.MediaInfo
|
||||
{
|
||||
public class Container
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.MediaInfo
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.MediaInfo
|
||||
{
|
||||
public class SubtitleTrackEvent
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
using System.IO;
|
||||
|
||||
namespace MediaBrowser.Model.Net
|
||||
|
|
|
@ -132,7 +132,7 @@ namespace MediaBrowser.Model.Net
|
|||
|
||||
var ext = Path.GetExtension(path) ?? string.Empty;
|
||||
|
||||
if (MimeTypeLookup.TryGetValue(ext, out var result))
|
||||
if (MimeTypeLookup.TryGetValue(ext, out string result))
|
||||
{
|
||||
return result;
|
||||
}
|
||||
|
@ -338,7 +338,7 @@ namespace MediaBrowser.Model.Net
|
|||
// handle text/html; charset=UTF-8
|
||||
mimeType = mimeType.Split(';')[0];
|
||||
|
||||
if (ExtensionLookup.TryGetValue(mimeType, out var result))
|
||||
if (ExtensionLookup.TryGetValue(mimeType, out string result))
|
||||
{
|
||||
return result;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Net
|
||||
{
|
||||
public class NetworkShare
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Net
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Net
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Net
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Notifications
|
||||
{
|
||||
public enum NotificationLevel
|
||||
|
|
|
@ -77,7 +77,7 @@ namespace MediaBrowser.Model.Notifications
|
|||
|
||||
public NotificationOption GetOptions(string type)
|
||||
{
|
||||
foreach (var i in Options)
|
||||
foreach (NotificationOption i in Options)
|
||||
{
|
||||
if (StringHelper.EqualsIgnoreCase(type, i.Type)) return i;
|
||||
}
|
||||
|
@ -86,14 +86,14 @@ namespace MediaBrowser.Model.Notifications
|
|||
|
||||
public bool IsEnabled(string type)
|
||||
{
|
||||
var opt = GetOptions(type);
|
||||
NotificationOption opt = GetOptions(type);
|
||||
|
||||
return opt != null && opt.Enabled;
|
||||
}
|
||||
|
||||
public bool IsServiceEnabled(string service, string notificationType)
|
||||
{
|
||||
var opt = GetOptions(notificationType);
|
||||
NotificationOption opt = GetOptions(notificationType);
|
||||
|
||||
return opt == null ||
|
||||
!ListHelper.ContainsIgnoreCase(opt.DisabledServices, service);
|
||||
|
@ -101,7 +101,7 @@ namespace MediaBrowser.Model.Notifications
|
|||
|
||||
public bool IsEnabledToMonitorUser(string type, Guid userId)
|
||||
{
|
||||
var opt = GetOptions(type);
|
||||
NotificationOption opt = GetOptions(type);
|
||||
|
||||
return opt != null && opt.Enabled &&
|
||||
!ListHelper.ContainsIgnoreCase(opt.DisabledMonitorUsers, userId.ToString(""));
|
||||
|
@ -109,7 +109,7 @@ namespace MediaBrowser.Model.Notifications
|
|||
|
||||
public bool IsEnabledToSendToUser(string type, string userId, UserPolicy userPolicy)
|
||||
{
|
||||
var opt = GetOptions(type);
|
||||
NotificationOption opt = GetOptions(type);
|
||||
|
||||
if (opt != null && opt.Enabled)
|
||||
{
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Playlists
|
||||
{
|
||||
public class PlaylistCreationResult
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Plugins
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Providers
|
||||
{
|
||||
public class ExternalIdInfo
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
namespace MediaBrowser.Model.Querying
|
||||
{
|
||||
public class EpisodeQuery
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue