feat: start of UI dev menu for Dalamud

This commit is contained in:
goat 2020-01-13 21:07:15 +09:00
parent 24450cf830
commit fc5a8bc38e

View file

@ -97,12 +97,42 @@ namespace Dalamud {
}
}
private bool isImguiDrawDemoWindow = true;
private bool isImguiDrawDemoWindow = false;
private bool isImguiDrawWelcome = true;
#if DEBUG
private bool isImguiDrawDevMenu = true;
#else
private bool isImguiDrawDevMenu = false;
#endif
private bool neverDrawWelcome = false;
private void BuildDalamudUi() {
if (this.isImguiDrawDevMenu) {
if (ImGui.BeginMainMenuBar()) {
if (ImGui.BeginMenu("Dalamud DEBUG")) {
if (ImGui.MenuItem("Open Log window")) {
}
ImGui.MenuItem("Draw ImGui demo", "", ref this.isImguiDrawDemoWindow);
ImGui.Separator();
if (ImGui.MenuItem("Unload Dalamud"))
{
Unload();
}
if (ImGui.MenuItem("Kill game"))
{
Process.GetCurrentProcess().Kill();
}
}
}
}
if (this.isImguiDrawDemoWindow)
ImGui.ShowDemoWindow();
@ -115,6 +145,7 @@ namespace Dalamud {
ImGui.Text($"dalamud says hello. ({this.assemblyVersion})");
ImGui.Checkbox("Don't show this message again", ref this.neverDrawWelcome);
ImGui.Spacing();
ImGui.Spacing();
if (ImGui.Button("Close")) {
this.isImguiDrawWelcome = false;