jellyfin/MediaBrowser.HtmlBrowser/Plugin.cs

35 lines
1.0 KiB
C#
Raw Normal View History

using System.ComponentModel.Composition;
using MediaBrowser.Common.Plugins;
2012-07-12 06:55:27 +00:00
using MediaBrowser.Controller;
using MediaBrowser.Model.Plugins;
2012-07-12 06:55:27 +00:00
namespace MediaBrowser.HtmlBrowser
{
[Export(typeof(BasePlugin))]
public class Plugin : BaseGenericPlugin<BasePluginConfiguration>
2012-07-12 06:55:27 +00:00
{
public override string Name
{
get { return "Html Library Browser"; }
}
public override void Init()
2012-07-12 06:55:27 +00:00
{
var httpServer = Kernel.Instance.HttpServer;
/*httpServer.Where(ctx => ctx.LocalPath.IndexOf("/browser/", StringComparison.OrdinalIgnoreCase) != -1).Subscribe(ctx =>
{
string localPath = ctx.LocalPath;
string srch = "/browser/";
int index = localPath.IndexOf(srch, StringComparison.OrdinalIgnoreCase);
string resource = localPath.Substring(index + srch.Length);
ctx.Respond(new EmbeddedResourceHandler(ctx, resource));
});*/
2012-07-12 06:55:27 +00:00
}
}
}