Skip to content
This repository has been archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
fix: add help button.
Browse files Browse the repository at this point in the history
  • Loading branch information
ArchiDog1998 committed Jul 18, 2023
1 parent 9238516 commit 8985779
Showing 1 changed file with 36 additions and 1 deletion.
37 changes: 36 additions & 1 deletion ActionTimelineEx/Windows/SettingsWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using ActionTimelineEx.Configurations;
using Dalamud.Interface;
using Dalamud.Interface.Windowing;
using Dalamud.Utility;
using ECommons.Commands;
using ECommons.DalamudServices;
using ImGuiNET;
Expand Down Expand Up @@ -45,12 +46,46 @@ public override void Draw()
}
if (ImGui.BeginTabItem("Help"))
{
CmdManager.DrawHelp();
DrawHelp();
ImGui.EndTabItem();
}
ImGui.EndTabBar();
}

private void DrawHelp()
{
ImGui.PushFont(UiBuilder.IconFont);
if (ImGui.Button($"{FontAwesomeIcon.Code.ToIconString()}##Github"))
{
Util.OpenLink("https://github.com/ArchiDog1998/ActionTimelineEx");
}

ImGui.SameLine();

if (ImGui.Button($"{FontAwesomeIcon.History.ToIconString()}##ChangeLog"))
{
Util.OpenLink("https://github.com/ArchiDog1998/ActionTimelineEx/blob/release/CHANGELOG.md");
}
ImGui.SameLine();

ImGui.PushStyleColor(ImGuiCol.Button, 0xFF5E5BFF);
ImGui.PushStyleColor(ImGuiCol.ButtonActive, 0xDD5E5BFF);
ImGui.PushStyleColor(ImGuiCol.ButtonHovered, 0xAA5E5BFF);
if (ImGui.Button($"{FontAwesomeIcon.Coffee.ToIconString()}##Support"))
{
Util.OpenLink("https://ko-fi.com/archited");
}

ImGui.PopStyleColor(3);
ImGui.PopFont();

if (ImGui.BeginChild("Help Information", new Vector2(0f, -1f), true))
{
CmdManager.DrawHelp();
ImGui.EndChild();
}
}

private ushort _aboutAdd = 0;
private void DrawGeneralSetting()
{
Expand Down

0 comments on commit 8985779

Please sign in to comment.