Minor ui tweaks

This commit is contained in:
Asriel Camora
2023-07-15 23:58:59 +04:00
parent 8417ee4fc5
commit 1cc83ca959
4 changed files with 21 additions and 22 deletions
+2 -4
View File
@@ -146,15 +146,13 @@ internal static class ImGuiUtils
public static unsafe void Hyperlink(string text, string url)
{
ImGui.TextUnformatted(text);
UnderlineLastItem(*ImGui.GetStyleColorVec4(ImGuiCol.Button));
if (ImGui.IsItemHovered())
{
ImGui.SetMouseCursor(ImGuiMouseCursor.Hand);
if (ImGui.IsItemClicked(ImGuiMouseButton.Left))
Process.Start(new ProcessStartInfo { FileName = url, UseShellExecute = true });
UnderlineLastItem(*ImGui.GetStyleColorVec4(ImGuiCol.Button));
ImGui.SetTooltip("Open in browser");
ImGui.SetTooltip("Open in Browser");
}
else
UnderlineLastItem(*ImGui.GetStyleColorVec4(ImGuiCol.Text));
}
}