catastropy averted?
This commit is contained in:
@@ -0,0 +1,68 @@
|
||||
using System;
|
||||
using System.Numerics;
|
||||
using Dalamud.Bindings.ImGui;
|
||||
|
||||
namespace WorldMapFixer;
|
||||
|
||||
internal class PluginUI : IDisposable
|
||||
{
|
||||
private Configuration configuration;
|
||||
|
||||
private bool settingsVisible;
|
||||
|
||||
public bool SettingsVisible
|
||||
{
|
||||
get
|
||||
{
|
||||
return settingsVisible;
|
||||
}
|
||||
set
|
||||
{
|
||||
settingsVisible = value;
|
||||
}
|
||||
}
|
||||
|
||||
public PluginUI(Configuration configuration)
|
||||
{
|
||||
this.configuration = configuration;
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
}
|
||||
|
||||
public void Draw()
|
||||
{
|
||||
DrawSettingsWindow();
|
||||
}
|
||||
|
||||
public void DrawSettingsWindow()
|
||||
{
|
||||
//IL_0023: Unknown result type (might be due to invalid IL or missing references)
|
||||
//IL_0048: Unknown result type (might be due to invalid IL or missing references)
|
||||
//IL_007e: Unknown result type (might be due to invalid IL or missing references)
|
||||
//IL_008b: Unknown result type (might be due to invalid IL or missing references)
|
||||
//IL_0091: Unknown result type (might be due to invalid IL or missing references)
|
||||
if (!SettingsVisible)
|
||||
{
|
||||
return;
|
||||
}
|
||||
ImGui.SetNextWindowSize(new Vector2(450f, 100f), (ImGuiCond)1);
|
||||
if (ImGui.Begin(ImU8String.op_Implicit("World Map Enhancer Settings"), ref settingsVisible, (ImGuiWindowFlags)58))
|
||||
{
|
||||
bool enabled = configuration.Enabled;
|
||||
if (ImGui.Checkbox(ImU8String.op_Implicit("Enable zooming out with right click"), ref enabled))
|
||||
{
|
||||
configuration.Enabled = enabled;
|
||||
configuration.Save();
|
||||
}
|
||||
int rightClickDelay = configuration.RightClickDelay;
|
||||
if (ImGui.InputInt(ImU8String.op_Implicit("Right click release delay"), ref rightClickDelay, 25, 100, default(ImU8String), (ImGuiInputTextFlags)0))
|
||||
{
|
||||
configuration.RightClickDelay = rightClickDelay;
|
||||
configuration.Save();
|
||||
}
|
||||
}
|
||||
ImGui.End();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user