xbox 360 dlna fixes

This commit is contained in:
Luke Pulverenti 2016-01-14 16:41:23 -05:00
parent 3e1058995c
commit 7fe2809483
4 changed files with 15 additions and 9 deletions

View File

@ -14,7 +14,7 @@ namespace MediaBrowser.Dlna.Profiles
Name = "Xbox 360";
// Required according to above
ModelName = "Windows Media Connect";
ModelName = "Windows Media Player Sharing";
ModelNumber = "12.0";
@ -25,7 +25,6 @@ namespace MediaBrowser.Dlna.Profiles
ManufacturerUrl = "http://www.microsoft.com";
XDlnaDoc = "DMS-1.50";
ModelDescription = "Emby : UPnP Media Server";
ModelNumber = "001";
TimelineOffsetSeconds = 40;
RequiresPlainFolders = true;

View File

@ -11,9 +11,9 @@
<FriendlyName>${HostName}: 1</FriendlyName>
<Manufacturer>Microsoft Corporation</Manufacturer>
<ManufacturerUrl>http://www.microsoft.com</ManufacturerUrl>
<ModelName>Windows Media Connect</ModelName>
<ModelName>Windows Media Player Sharing</ModelName>
<ModelDescription>Emby : UPnP Media Server</ModelDescription>
<ModelNumber>001</ModelNumber>
<ModelNumber>12.0</ModelNumber>
<ModelUrl>http://go.microsoft.com/fwlink/?LinkId=105926</ModelUrl>
<EnableAlbumArtInDidl>false</EnableAlbumArtInDidl>
<EnableSingleAlbumArtLimit>false</EnableSingleAlbumArtLimit>

View File

@ -92,10 +92,7 @@ namespace MediaBrowser.Dlna.Server
builder.Append("<device>");
AppendDeviceProperties(builder);
if (_profile.EnableDlnaProtocol)
{
AppendIconList(builder);
}
AppendIconList(builder);
AppendServiceList(builder);
builder.Append("</device>");
}
@ -111,6 +108,13 @@ namespace MediaBrowser.Dlna.Server
builder.Append("<dlna:X_DLNADOC xmlns:dlna=\"urn:schemas-dlna-org:device-1-0\">M-DMS-1.50</dlna:X_DLNADOC>");
builder.Append("<dlna:X_DLNADOC xmlns:dlna=\"urn:schemas-dlna-org:device-1-0\">" + SecurityElement.Escape(_profile.XDlnaDoc ?? string.Empty) + "</dlna:X_DLNADOC>");
}
else
{
builder.Append("<dlna:X_DLNACAP>" + SecurityElement.Escape(_profile.XDlnaCap ?? string.Empty) + "</dlna:X_DLNACAP>");
builder.Append("<dlna:X_DLNADOC>" + SecurityElement.Escape(_profile.XDlnaDoc ?? string.Empty) + "</dlna:X_DLNADOC>");
builder.Append("<dlna:X_DLNADOC>M-DMS-1.50</dlna:X_DLNADOC>");
}
builder.Append("<friendlyName>" + SecurityElement.Escape(GetFriendlyName()) + "</friendlyName>");
builder.Append("<manufacturer>" + SecurityElement.Escape(_profile.Manufacturer ?? string.Empty) + "</manufacturer>");

View File

@ -58,7 +58,10 @@ namespace MediaBrowser.Server.Implementations.HttpServer
if (hasOptions != null)
{
hasOptions.Options["Server"] = "Mono-HTTPAPI/1.1";
if (!hasOptions.Options.ContainsKey("Server"))
{
hasOptions.Options["Server"] = "Mono-HTTPAPI/1.1, UPnP/1.0 DLNADOC/1.50";
}
// Content length has to be explicitly set on on HttpListenerResponse or it won't be happy
string contentLength;