2012-07-12 06:55:27 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Reactive.Linq;
|
2012-07-13 03:50:50 +00:00
|
|
|
|
using MediaBrowser.Common.Net.Handlers;
|
2012-07-12 06:55:27 +00:00
|
|
|
|
using MediaBrowser.Common.Plugins;
|
|
|
|
|
using MediaBrowser.Controller;
|
|
|
|
|
|
|
|
|
|
namespace MediaBrowser.HtmlBrowser
|
|
|
|
|
{
|
|
|
|
|
public class Plugin : BasePlugin<BasePluginConfiguration>
|
|
|
|
|
{
|
|
|
|
|
protected override void InitInternal()
|
|
|
|
|
{
|
2012-07-13 03:50:50 +00:00
|
|
|
|
var httpServer = Kernel.Instance.HttpServer;
|
|
|
|
|
|
|
|
|
|
/*httpServer.Where(ctx => ctx.Request.Url.LocalPath.EndsWith("/browser/index.html", StringComparison.OrdinalIgnoreCase)).Subscribe(ctx => ctx.Respond(new EmbeddedResourceHandler(ctx, "MediaBrowser.HtmlBrowser.Html.index.html")));
|
|
|
|
|
|
|
|
|
|
httpServer.Where(ctx => ctx.Request.Url.LocalPath.EndsWith("/browser/resource", StringComparison.OrdinalIgnoreCase)).Subscribe(ctx => ctx.Respond(new EmbeddedResourceHandler(ctx)));
|
|
|
|
|
|
|
|
|
|
httpServer.Where(ctx => ctx.Request.Url.LocalPath.EndsWith("/browser/favicon.ico", StringComparison.OrdinalIgnoreCase)).Subscribe(ctx => ctx.Respond(new EmbeddedResourceHandler(ctx, "MediaBrowser.HtmlBrowser.Html.css.images.favicon.ico")));*/
|
2012-07-12 06:55:27 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|