diff --git a/Dalamud/Interface/Internal/Windows/SelfTest/Steps/ToastSelfTestStep.cs b/Dalamud/Interface/Internal/Windows/SelfTest/Steps/ToastSelfTestStep.cs index 1c82e274c..cd34fa30b 100644 --- a/Dalamud/Interface/Internal/Windows/SelfTest/Steps/ToastSelfTestStep.cs +++ b/Dalamud/Interface/Internal/Windows/SelfTest/Steps/ToastSelfTestStep.cs @@ -1,5 +1,7 @@ using Dalamud.Game.Gui.Toast; +using ImGuiNET; + namespace Dalamud.Interface.Internal.Windows.SelfTest.Steps; /// @@ -7,23 +9,42 @@ namespace Dalamud.Interface.Internal.Windows.SelfTest.Steps; /// internal class ToastSelfTestStep : ISelfTestStep { + private bool sentToasts = false; + /// public string Name => "Test Toasts"; /// public SelfTestStepResult RunStep() { - var toastGui = Service.Get(); + if (!this.sentToasts) + { + var toastGui = Service.Get(); + toastGui.ShowNormal("Normal Toast"); + toastGui.ShowError("Error Toast"); + toastGui.ShowQuest("Quest Toast"); + this.sentToasts = true; + } - toastGui.ShowNormal("Normal Toast"); - toastGui.ShowError("Error Toast"); + ImGui.Text("Did you see a normal toast, a quest toast and an error toast?"); - return SelfTestStepResult.Pass; + if (ImGui.Button("Yes")) + { + return SelfTestStepResult.Pass; + } + + ImGui.SameLine(); + if (ImGui.Button("No")) + { + return SelfTestStepResult.Fail; + } + + return SelfTestStepResult.Waiting; } /// public void CleanUp() { - // ignored + this.sentToasts = false; } }