From abde79dbc80e358130921c271905938c8aede815 Mon Sep 17 00:00:00 2001 From: goaaats Date: Sat, 31 May 2025 12:00:40 +0200 Subject: [PATCH] Re-add toggle window commands to CorePlugin --- Dalamud.CorePlugin/PluginImpl.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Dalamud.CorePlugin/PluginImpl.cs b/Dalamud.CorePlugin/PluginImpl.cs index 951050b33..1942e271b 100644 --- a/Dalamud.CorePlugin/PluginImpl.cs +++ b/Dalamud.CorePlugin/PluginImpl.cs @@ -46,6 +46,8 @@ namespace Dalamud.CorePlugin #else private readonly WindowSystem windowSystem = new("Dalamud.CorePlugin"); + private readonly PluginWindow window; + private Localization localization; private IPluginLog pluginLog; @@ -63,7 +65,8 @@ namespace Dalamud.CorePlugin this.Interface = pluginInterface; this.pluginLog = log; - this.windowSystem.AddWindow(new PluginWindow()); + this.window = new PluginWindow(); + this.windowSystem.AddWindow(this.window); this.Interface.UiBuilder.Draw += this.OnDraw; this.Interface.UiBuilder.OpenConfigUi += this.OnOpenConfigUi; @@ -136,12 +139,12 @@ namespace Dalamud.CorePlugin { this.pluginLog.Information("Command called!"); - // this.window.IsOpen = true; + this.window.IsOpen ^= true; } private void OnOpenConfigUi() { - // this.window.IsOpen = true; + this.window.IsOpen = true; } private void OnOpenMainUi()