Add label for external audio/sub tracks

This commit is contained in:
Joe Rogers
2022-03-10 22:20:35 +01:00
parent 388e0cba9f
commit 1a307db7eb
5 changed files with 62 additions and 21 deletions

View File

@@ -140,6 +140,8 @@ namespace MediaBrowser.Model.Entities
public string LocalizedForced { get; set; }
public string LocalizedExternal { get; set; }
public string DisplayTitle
{
get
@@ -184,6 +186,11 @@ namespace MediaBrowser.Model.Entities
attributes.Add(string.IsNullOrEmpty(LocalizedDefault) ? "Default" : LocalizedDefault);
}
if (IsExternal)
{
attributes.Add(string.IsNullOrEmpty(LocalizedExternal) ? "External" : LocalizedExternal);
}
if (!string.IsNullOrEmpty(Title))
{
var result = new StringBuilder(Title);
@@ -274,6 +281,11 @@ namespace MediaBrowser.Model.Entities
attributes.Add(Codec.ToUpperInvariant());
}
if (IsExternal)
{
attributes.Add(string.IsNullOrEmpty(LocalizedExternal) ? "External" : LocalizedExternal);
}
if (!string.IsNullOrEmpty(Title))
{
var result = new StringBuilder(Title);