Initial jellyfin-multilang rewrite
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
using System.Globalization;
|
||||
using Jellyfin.Plugin.Multilang.Configuration;
|
||||
using MediaBrowser.Common.Configuration;
|
||||
using MediaBrowser.Common.Plugins;
|
||||
using MediaBrowser.Model.Plugins;
|
||||
using MediaBrowser.Model.Serialization;
|
||||
|
||||
namespace Jellyfin.Plugin.Multilang;
|
||||
|
||||
public sealed class Plugin : BasePlugin<PluginConfiguration>, IHasWebPages
|
||||
{
|
||||
public static Plugin? Instance { get; private set; }
|
||||
|
||||
public Plugin(IApplicationPaths applicationPaths, IXmlSerializer xmlSerializer)
|
||||
: base(applicationPaths, xmlSerializer)
|
||||
{
|
||||
Instance = this;
|
||||
}
|
||||
|
||||
public override string Name => "Multilang";
|
||||
|
||||
public override Guid Id => Guid.Parse("9d7c61a5-7a1b-4d1e-9b79-4c8c6d2e8a2a");
|
||||
|
||||
public IEnumerable<PluginPageInfo> GetPages()
|
||||
{
|
||||
yield return new PluginPageInfo
|
||||
{
|
||||
Name = "Multilang",
|
||||
DisplayName = "Multilang",
|
||||
EmbeddedResourcePath = string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0}.Configuration.configPage.html",
|
||||
GetType().Namespace),
|
||||
EnableInMainMenu = true,
|
||||
MenuSection = "plugins",
|
||||
MenuIcon = "translate"
|
||||
};
|
||||
|
||||
yield return new PluginPageInfo
|
||||
{
|
||||
Name = "MultilangUser",
|
||||
DisplayName = "Multilang User Rules",
|
||||
EmbeddedResourcePath = string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0}.Configuration.userRulesPage.html",
|
||||
GetType().Namespace)
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user