mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 22:07:13 -04:00
expand device identification
This commit is contained in:
parent
f12d8b0c18
commit
78acab6916
56
MediaBrowser.Controller/Dlna/DeviceIdentification.cs
Normal file
56
MediaBrowser.Controller/Dlna/DeviceIdentification.cs
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace MediaBrowser.Controller.Dlna
|
||||||
|
{
|
||||||
|
public class DeviceIdentification
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the name of the friendly.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The name of the friendly.</value>
|
||||||
|
public string FriendlyName { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the model number.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The model number.</value>
|
||||||
|
public string ModelNumber { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the serial number.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The serial number.</value>
|
||||||
|
public string SerialNumber { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the name of the model.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The name of the model.</value>
|
||||||
|
public string ModelName { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the manufacturer.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>
|
||||||
|
/// The manufacturer.
|
||||||
|
/// </value>
|
||||||
|
public string Manufacturer { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the manufacturer URL.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The manufacturer URL.</value>
|
||||||
|
public string ManufacturerUrl { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the headers.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The headers.</value>
|
||||||
|
public List<HttpHeaderInfo> Headers { get; set; }
|
||||||
|
|
||||||
|
public DeviceIdentification()
|
||||||
|
{
|
||||||
|
Headers = new List<HttpHeaderInfo>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class HttpHeaderInfo
|
||||||
|
{
|
||||||
|
public string Name { get; set; }
|
||||||
|
public string Value { get; set; }
|
||||||
|
}
|
||||||
|
}
|
@ -15,32 +15,6 @@ namespace MediaBrowser.Controller.Dlna
|
|||||||
/// <value>The type of the client.</value>
|
/// <value>The type of the client.</value>
|
||||||
public string ClientType { get; set; }
|
public string ClientType { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets the name of the friendly.
|
|
||||||
/// </summary>
|
|
||||||
/// <value>The name of the friendly.</value>
|
|
||||||
public string FriendlyName { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets the model number.
|
|
||||||
/// </summary>
|
|
||||||
/// <value>The model number.</value>
|
|
||||||
public string ModelNumber { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets the name of the model.
|
|
||||||
/// </summary>
|
|
||||||
/// <value>The name of the model.</value>
|
|
||||||
public string ModelName { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets the manufacturer.
|
|
||||||
/// </summary>
|
|
||||||
/// <value>
|
|
||||||
/// The manufacturer.
|
|
||||||
/// </value>
|
|
||||||
public string Manufacturer { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the transcoding profiles.
|
/// Gets or sets the transcoding profiles.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -53,6 +27,12 @@ namespace MediaBrowser.Controller.Dlna
|
|||||||
/// <value>The direct play profiles.</value>
|
/// <value>The direct play profiles.</value>
|
||||||
public DirectPlayProfile[] DirectPlayProfiles { get; set; }
|
public DirectPlayProfile[] DirectPlayProfiles { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or sets the identification.
|
||||||
|
/// </summary>
|
||||||
|
/// <value>The identification.</value>
|
||||||
|
public DeviceIdentification Identification { get; set; }
|
||||||
|
|
||||||
public DeviceProfile()
|
public DeviceProfile()
|
||||||
{
|
{
|
||||||
DirectPlayProfiles = new DirectPlayProfile[] { };
|
DirectPlayProfiles = new DirectPlayProfile[] { };
|
||||||
|
@ -19,11 +19,8 @@ namespace MediaBrowser.Controller.Dlna
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the profile.
|
/// Gets the profile.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="friendlyName">Name of the friendly.</param>
|
/// <param name="deviceInfo">The device information.</param>
|
||||||
/// <param name="modelName">Name of the model.</param>
|
/// <returns>DeviceProfile.</returns>
|
||||||
/// <param name="modelNumber">The model number.</param>
|
DeviceProfile GetProfile(DeviceIdentification deviceInfo);
|
||||||
/// <param name="manufacturer">The manufacturer.</param>
|
|
||||||
/// <returns>DlnaProfile.</</returns>
|
|
||||||
DeviceProfile GetProfile(string friendlyName, string modelName, string modelNumber, string manufacturer);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -73,6 +73,7 @@
|
|||||||
<Compile Include="Channels\IChannelManager.cs" />
|
<Compile Include="Channels\IChannelManager.cs" />
|
||||||
<Compile Include="Collections\CollectionCreationOptions.cs" />
|
<Compile Include="Collections\CollectionCreationOptions.cs" />
|
||||||
<Compile Include="Collections\ICollectionManager.cs" />
|
<Compile Include="Collections\ICollectionManager.cs" />
|
||||||
|
<Compile Include="Dlna\DeviceIdentification.cs" />
|
||||||
<Compile Include="Dlna\DirectPlayProfile.cs" />
|
<Compile Include="Dlna\DirectPlayProfile.cs" />
|
||||||
<Compile Include="Dlna\IDlnaManager.cs" />
|
<Compile Include="Dlna\IDlnaManager.cs" />
|
||||||
<Compile Include="Dlna\DeviceProfile.cs" />
|
<Compile Include="Dlna\DeviceProfile.cs" />
|
||||||
|
@ -3,6 +3,7 @@ using MediaBrowser.Common.IO;
|
|||||||
using MediaBrowser.Controller.Dlna;
|
using MediaBrowser.Controller.Dlna;
|
||||||
using MediaBrowser.Model.Serialization;
|
using MediaBrowser.Model.Serialization;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
|
||||||
namespace MediaBrowser.Dlna
|
namespace MediaBrowser.Dlna
|
||||||
@ -31,9 +32,13 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Samsung TV (B Series)",
|
Name = "Samsung TV (B Series)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = "^TV$",
|
|
||||||
ModelNumber = @"1\.0",
|
Identification = new DeviceIdentification
|
||||||
ModelName = "Samsung DTV DMR",
|
{
|
||||||
|
FriendlyName = "^TV$",
|
||||||
|
ModelNumber = @"1\.0",
|
||||||
|
ModelName = "Samsung DTV DMR"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -82,8 +87,12 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Samsung TV (E/F-series)",
|
Name = "Samsung TV (E/F-series)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"(^\[TV\][A-Z]{2}\d{2}(E|F)[A-Z]?\d{3,4}.*)|^\[TV\] Samsung|(^\[TV\]Samsung [A-Z]{2}\d{2}(E|F)[A-Z]?\d{3,4}.*)",
|
|
||||||
ModelNumber = @"(1\.0)|(AllShare1\.0)",
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"(^\[TV\][A-Z]{2}\d{2}(E|F)[A-Z]?\d{3,4}.*)|^\[TV\] Samsung|(^\[TV\]Samsung [A-Z]{2}\d{2}(E|F)[A-Z]?\d{3,4}.*)",
|
||||||
|
ModelNumber = @"(1\.0)|(AllShare1\.0)"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -130,8 +139,13 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Samsung TV (C/D-series)",
|
Name = "Samsung TV (C/D-series)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"(^TV-\d{2}C\d{3}.*)|(^\[TV\][A-Z]{2}\d{2}(D)[A-Z]?\d{3,4}.*)|^\[TV\] Samsung",
|
|
||||||
ModelNumber = @"(1\.0)|(AllShare1\.0)",
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"(^TV-\d{2}C\d{3}.*)|(^\[TV\][A-Z]{2}\d{2}(D)[A-Z]?\d{3,4}.*)|^\[TV\] Samsung",
|
||||||
|
ModelNumber = @"(1\.0)|(AllShare1\.0)"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
new TranscodingProfile
|
new TranscodingProfile
|
||||||
@ -181,7 +195,12 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Xbox 360",
|
Name = "Xbox 360",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
ModelName = "Xbox 360",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
ModelName = "Xbox 360"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
new TranscodingProfile
|
new TranscodingProfile
|
||||||
@ -215,9 +234,14 @@ namespace MediaBrowser.Dlna
|
|||||||
list.Add(new DeviceProfile
|
list.Add(new DeviceProfile
|
||||||
{
|
{
|
||||||
Name = "Xbox One",
|
Name = "Xbox One",
|
||||||
ModelName = "Xbox One",
|
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = "Xbox-SystemOS",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
ModelName = "Xbox One",
|
||||||
|
FriendlyName = "Xbox-SystemOS"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
new TranscodingProfile
|
new TranscodingProfile
|
||||||
@ -256,7 +280,11 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Sony Bravia (2012)",
|
Name = "Sony Bravia (2012)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"BRAVIA KDL-\d{2}[A-Z]X\d5(\d|G).*",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"BRAVIA KDL-\d{2}[A-Z]X\d5(\d|G).*"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -292,7 +320,11 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "Sony Bravia (2013)",
|
Name = "Sony Bravia (2013)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"BRAVIA (KDL-\d{2}W[689]\d{2}A.*)|(KD-\d{2}X9\d{3}A.*)",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"BRAVIA (KDL-\d{2}W[689]\d{2}A.*)|(KD-\d{2}X9\d{3}A.*)"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -346,8 +378,12 @@ namespace MediaBrowser.Dlna
|
|||||||
//Panasonic Viera (2011|2012) Without AVI Support
|
//Panasonic Viera (2011|2012) Without AVI Support
|
||||||
Name = "Panasonic Viera E/S/ST/VT (2011)",
|
Name = "Panasonic Viera E/S/ST/VT (2011)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"(VIERA (E|S)T?(3|5)0?.*)|(VIERA VT30.*)",
|
|
||||||
Manufacturer = "Panasonic",
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"(VIERA (E|S)T?(3|5)0?.*)|(VIERA VT30.*)",
|
||||||
|
Manufacturer = "Panasonic"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -383,8 +419,12 @@ namespace MediaBrowser.Dlna
|
|||||||
//Panasonic Viera (2011|2012) With AVI Support
|
//Panasonic Viera (2011|2012) With AVI Support
|
||||||
Name = "Panasonic Viera G/GT/DT/UT/VT (2011/2012)",
|
Name = "Panasonic Viera G/GT/DT/UT/VT (2011/2012)",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
FriendlyName = @"(VIERA (G|D|U)T?(3|5)0?.*)|(VIERA VT50.*)",
|
|
||||||
Manufacturer = "Panasonic",
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"(VIERA (G|D|U)T?(3|5)0?.*)|(VIERA VT50.*)",
|
||||||
|
Manufacturer = "Panasonic"
|
||||||
|
},
|
||||||
|
|
||||||
TranscodingProfiles = new[]
|
TranscodingProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -427,9 +467,13 @@ namespace MediaBrowser.Dlna
|
|||||||
list.Add(new DeviceProfile
|
list.Add(new DeviceProfile
|
||||||
{
|
{
|
||||||
Name = "Philips (2010-)",
|
Name = "Philips (2010-)",
|
||||||
FriendlyName = ".*PHILIPS.*",
|
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
ModelName = "WD TV HD Live",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = ".*PHILIPS.*",
|
||||||
|
ModelName = "WD TV HD Live"
|
||||||
|
},
|
||||||
|
|
||||||
DirectPlayProfiles = new[]
|
DirectPlayProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -460,7 +504,11 @@ namespace MediaBrowser.Dlna
|
|||||||
{
|
{
|
||||||
Name = "WDTV Live",
|
Name = "WDTV Live",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
ModelName = "WD TV HD Live",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
ModelName = "WD TV HD Live"
|
||||||
|
},
|
||||||
|
|
||||||
DirectPlayProfiles = new[]
|
DirectPlayProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -483,7 +531,11 @@ namespace MediaBrowser.Dlna
|
|||||||
//Linksys DMA2100us does not need any transcoding of the formats we support statically
|
//Linksys DMA2100us does not need any transcoding of the formats we support statically
|
||||||
Name = "Linksys DMA2100",
|
Name = "Linksys DMA2100",
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
ModelName = "DMA2100us",
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
ModelName = "DMA2100us"
|
||||||
|
},
|
||||||
|
|
||||||
DirectPlayProfiles = new[]
|
DirectPlayProfiles = new[]
|
||||||
{
|
{
|
||||||
@ -504,10 +556,14 @@ namespace MediaBrowser.Dlna
|
|||||||
list.Add(new DeviceProfile
|
list.Add(new DeviceProfile
|
||||||
{
|
{
|
||||||
Name = "Denon AVR",
|
Name = "Denon AVR",
|
||||||
FriendlyName = @"Denon:\[AVR:.*",
|
|
||||||
Manufacturer = "Denon",
|
|
||||||
ClientType = "DLNA",
|
ClientType = "DLNA",
|
||||||
|
|
||||||
|
Identification = new DeviceIdentification
|
||||||
|
{
|
||||||
|
FriendlyName = @"Denon:\[AVR:.*",
|
||||||
|
Manufacturer = "Denon"
|
||||||
|
},
|
||||||
|
|
||||||
DirectPlayProfiles = new[]
|
DirectPlayProfiles = new[]
|
||||||
{
|
{
|
||||||
new DirectPlayProfile
|
new DirectPlayProfile
|
||||||
@ -561,38 +617,51 @@ namespace MediaBrowser.Dlna
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
public DeviceProfile GetProfile(string friendlyName, string modelName, string modelNumber, string manufacturer)
|
public DeviceProfile GetProfile(DeviceIdentification deviceInfo)
|
||||||
{
|
{
|
||||||
foreach (var profile in GetProfiles())
|
return GetProfiles().FirstOrDefault(i => IsMatch(deviceInfo, i.Identification)) ??
|
||||||
|
GetDefaultProfile();
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool IsMatch(DeviceIdentification deviceInfo, DeviceIdentification profileInfo)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.FriendlyName))
|
||||||
{
|
{
|
||||||
if (!string.IsNullOrEmpty(profile.FriendlyName))
|
if (!Regex.IsMatch(deviceInfo.FriendlyName, profileInfo.FriendlyName))
|
||||||
{
|
return false;
|
||||||
if (!Regex.IsMatch(friendlyName, profile.FriendlyName))
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(profile.ModelNumber))
|
|
||||||
{
|
|
||||||
if (!Regex.IsMatch(modelNumber, profile.ModelNumber))
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(profile.ModelName))
|
|
||||||
{
|
|
||||||
if (!Regex.IsMatch(modelName, profile.ModelName))
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(profile.Manufacturer))
|
|
||||||
{
|
|
||||||
if (!Regex.IsMatch(manufacturer, profile.Manufacturer))
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
return profile;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
return GetDefaultProfile();
|
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.ModelNumber))
|
||||||
|
{
|
||||||
|
if (!Regex.IsMatch(deviceInfo.ModelNumber, profileInfo.ModelNumber))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.ModelName))
|
||||||
|
{
|
||||||
|
if (!Regex.IsMatch(deviceInfo.ModelName, profileInfo.ModelName))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.Manufacturer))
|
||||||
|
{
|
||||||
|
if (!Regex.IsMatch(deviceInfo.Manufacturer, profileInfo.Manufacturer))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.ManufacturerUrl))
|
||||||
|
{
|
||||||
|
if (!Regex.IsMatch(deviceInfo.ManufacturerUrl, profileInfo.ManufacturerUrl))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(profileInfo.SerialNumber))
|
||||||
|
{
|
||||||
|
if (!Regex.IsMatch(deviceInfo.SerialNumber, profileInfo.SerialNumber))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,5 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using MediaBrowser.Controller.Dlna;
|
||||||
|
|
||||||
namespace MediaBrowser.Dlna.PlayTo
|
namespace MediaBrowser.Dlna.PlayTo
|
||||||
{
|
{
|
||||||
@ -62,5 +63,17 @@ namespace MediaBrowser.Dlna.PlayTo
|
|||||||
return _services;
|
return _services;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public DeviceIdentification ToDeviceIdentification()
|
||||||
|
{
|
||||||
|
return new DeviceIdentification
|
||||||
|
{
|
||||||
|
Manufacturer = Manufacturer,
|
||||||
|
ModelName = ModelName,
|
||||||
|
ModelNumber = ModelNumber,
|
||||||
|
FriendlyName = Name,
|
||||||
|
ManufacturerUrl = ManufacturerUrl
|
||||||
|
};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -395,7 +395,7 @@ namespace MediaBrowser.Dlna.PlayTo
|
|||||||
|
|
||||||
var deviceInfo = _device.Properties;
|
var deviceInfo = _device.Properties;
|
||||||
|
|
||||||
var playlistItem = PlaylistItem.Create(item, _dlnaManager.GetProfile(deviceInfo.Name, deviceInfo.ModelName, deviceInfo.ModelNumber, deviceInfo.Manufacturer));
|
var playlistItem = PlaylistItem.Create(item, _dlnaManager.GetProfile(deviceInfo.ToDeviceIdentification()));
|
||||||
playlistItem.StartPositionTicks = startPostionTicks;
|
playlistItem.StartPositionTicks = startPostionTicks;
|
||||||
|
|
||||||
if (playlistItem.IsAudio)
|
if (playlistItem.IsAudio)
|
||||||
|
@ -246,7 +246,7 @@ namespace MediaBrowser.Dlna.PlayTo
|
|||||||
/// <returns>The TranscodeSettings for the device</returns>
|
/// <returns>The TranscodeSettings for the device</returns>
|
||||||
private void GetProfileSettings(DeviceInfo deviceProperties)
|
private void GetProfileSettings(DeviceInfo deviceProperties)
|
||||||
{
|
{
|
||||||
var profile = _dlnaManager.GetProfile(deviceProperties.Name, deviceProperties.ModelName, deviceProperties.ModelNumber, deviceProperties.Manufacturer);
|
var profile = _dlnaManager.GetProfile(deviceProperties.ToDeviceIdentification());
|
||||||
|
|
||||||
if (!string.IsNullOrWhiteSpace(profile.Name))
|
if (!string.IsNullOrWhiteSpace(profile.Name))
|
||||||
{
|
{
|
||||||
|
@ -461,6 +461,7 @@ namespace MediaBrowser.WebDashboard.Api
|
|||||||
"extensions.js",
|
"extensions.js",
|
||||||
"site.js",
|
"site.js",
|
||||||
"librarybrowser.js",
|
"librarybrowser.js",
|
||||||
|
"librarylist.js",
|
||||||
"editorsidebar.js",
|
"editorsidebar.js",
|
||||||
"librarymenu.js",
|
"librarymenu.js",
|
||||||
//"chromecast.js",
|
//"chromecast.js",
|
||||||
|
@ -512,6 +512,9 @@
|
|||||||
<Content Include="dashboard-ui\scripts\autoorganizelog.js">
|
<Content Include="dashboard-ui\scripts\autoorganizelog.js">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
<Content Include="dashboard-ui\scripts\librarylist.js">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</Content>
|
||||||
<Content Include="dashboard-ui\scripts\librarymenu.js">
|
<Content Include="dashboard-ui\scripts\librarymenu.js">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
Loading…
Reference in New Issue
Block a user