Fixed signature

This commit is contained in:
2025-08-09 17:24:21 +03:00
parent 20eeafdc41
commit 0a0ae4bee9
3 changed files with 19 additions and 12 deletions

View File

@@ -2,6 +2,7 @@
using Dalamud.Interface;
using Dalamud.Utility;
using Dalamud.Bindings.ImGui;
using System.Text;
namespace CustomizePlus.Core.Helpers;
@@ -67,14 +68,20 @@ public static class CtrlHelper
public static bool ArrowToggle(string label, ref bool value)
{//ImGuiNative.ArrowButton(label, value ? ImGuiDir.Down : ImGuiDir.Right);
var toggled = false;
if (toggled)
unsafe // temporary fix
{
value = !value;
}
var utf8Label = Encoding.UTF8.GetBytes(label + "\0");
return value;
fixed (byte* labelPtr = utf8Label)
{
bool toggled = ImGuiNative.ArrowButton(labelPtr, value ? ImGuiDir.Down : ImGuiDir.Right) != 0;
if (toggled)
value = !value;
return value;
}
}
}
public static void AddHoverText(string text)