Skip to content

Commit

Permalink
Add escape to SetupNag
Browse files Browse the repository at this point in the history
  • Loading branch information
KazWolfe committed Nov 20, 2023
1 parent 75a6657 commit 00c51f0
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 0 deletions.
27 changes: 27 additions & 0 deletions FFXIVPlugin/Resources/Localization/UIStrings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions FFXIVPlugin/Resources/Localization/UIStrings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -348,4 +348,13 @@ This will not re-enable the plugin.</value>
<data name="MultiboxNag_ChatWarning" xml:space="preserve">
<value>Multiboxing has been detected. XIVDeck might not work properly!</value>
</data>
<data name="SetupNag_MessageWillReturn" xml:space="preserve">
<value>This message will return on every game launch!</value>
</data>
<data name="SetupNag_BypassButton" xml:space="preserve">
<value>Ignore for now</value>
</data>
<data name="SetupNag_BypassHint" xml:space="preserve">
<value>Don't care? Hold CTRL to bypass this dialog!</value>
</data>
</root>
13 changes: 13 additions & 0 deletions FFXIVPlugin/UI/Windows/Nags/SetupNag.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
using Dalamud.Interface;
using Dalamud.Interface.Colors;
using Dalamud.Interface.Components;
using Dalamud.Interface.Utility;
using ImGuiNET;
using XIVDeck.FFXIVPlugin.Resources.Localization;
using XIVDeck.FFXIVPlugin.Resources.Localization;
using XIVDeck.FFXIVPlugin.Utils;

namespace XIVDeck.FFXIVPlugin.UI.Windows.Nags;
Expand Down Expand Up @@ -68,11 +70,22 @@ protected override void _internalDraw() {

ImGui.Spacing();
ImGui.TextColored(ImGuiColors.DalamudGrey, UIStrings.SetupNag_DismissHelp);

ImGui.AlignTextToFramePadding();
ImGui.TextColored(ImGuiColors.DalamudGrey, UIStrings.ForcedUpdateNag_SupportInfo);
ImGui.SameLine();
if (ImGuiComponents.IconButton(FontAwesomeIcon.Headset)) {
Dalamud.Utility.Util.OpenLink(Constants.GoatPlaceDiscord);
}
if (ImGui.IsItemHovered()) ImGui.SetTooltip(UIStrings.SetupNag_JoinDiscord);

if (ImGui.GetIO().KeyCtrl) {
if (ImGui.Button(UIStrings.SetupNag_BypassButton)) {
Hide();
}
ImGuiComponents.HelpMarker(UIStrings.SetupNag_MessageWillReturn);
} else {
ImGui.TextColored(ImGuiColors.DalamudGrey2, UIStrings.SetupNag_BypassHint);
}
}
}

0 comments on commit 00c51f0

Please sign in to comment.