jellyfin/MediaBrowser.HtmlBrowser/Handlers/EmbeddedResourceHandler.cs
2012-07-21 14:39:47 -04:00

23 lines
613 B
C#

using System.IO;
using System.Reflection;
using MediaBrowser.Common.Net.Handlers;
namespace MediaBrowser.HtmlBrowser.Handlers
{
class EmbeddedResourceHandler : BaseEmbeddedResourceHandler
{
public EmbeddedResourceHandler(string resourcePath)
: base(resourcePath)
{
}
protected override Stream GetEmbeddedResourceStream()
{
string path = ResourcePath.Replace("/", ".");
return Assembly.GetExecutingAssembly().GetManifestResourceStream("MediaBrowser.HtmlBrowser.Html." + path);
}
}
}