loc: style editor, feedback tweaks

This commit is contained in:
goat 2021-09-28 03:54:45 +02:00
parent 886c088dec
commit 71165b599b
No known key found for this signature in database
GPG key ID: F18F057873895461
4 changed files with 26 additions and 7 deletions

View file

@ -1,7 +1,8 @@
using System; using System;
using System.Diagnostics.CodeAnalysis; using System.Diagnostics.CodeAnalysis;
using System.Numerics; using System.Numerics;
using Dalamud.Interface;
using Dalamud.Interface.Colors;
using Dalamud.Interface.Windowing; using Dalamud.Interface.Windowing;
using ImGuiNET; using ImGuiNET;
@ -12,6 +13,9 @@ namespace Dalamud.CorePlugin
/// </summary> /// </summary>
internal class PluginWindow : Window, IDisposable internal class PluginWindow : Window, IDisposable
{ {
private Vector4 bgCol = ImGuiColors.HealerGreen;
private Vector4 textCol = ImGuiColors.DalamudWhite;
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="PluginWindow"/> class. /// Initializes a new instance of the <see cref="PluginWindow"/> class.
/// </summary> /// </summary>
@ -37,6 +41,21 @@ namespace Dalamud.CorePlugin
/// <inheritdoc/> /// <inheritdoc/>
public override void Draw() public override void Draw()
{ {
ImGui.ColorPicker4("bg", ref this.bgCol);
ImGui.ColorPicker4("text", ref this.textCol);
ImGui.PushStyleColor(ImGuiCol.ChildBg, this.bgCol);
ImGui.PushStyleColor(ImGuiCol.Text, this.textCol);
if (ImGui.BeginChild("##changelog", new Vector2(-1, 100), true, ImGuiWindowFlags.NoNavFocus | ImGuiWindowFlags.NoNavInputs | ImGuiWindowFlags.AlwaysAutoResize))
{
ImGui.Text("Changelog:");
ImGuiHelpers.ScaledDummy(2);
ImGui.TextWrapped("* ASIhif ai fdh adhsfuoadf\n* IUHoiaudsfh adsof hioaudshfuio husiodfh\n* A iiaojfdpasd ijopadfnklafwjenalkfjensgdlkjnasasdfbhnj");
}
ImGui.EndChild();
ImGui.PopStyleColor(2);
} }
} }
} }

View file

@ -470,7 +470,7 @@ namespace Dalamud.Interface.Internal.Windows
if (ImGui.BeginPopupModal(modalTitle, ref this.feedbackModalDrawing, ImGuiWindowFlags.AlwaysAutoResize | ImGuiWindowFlags.NoScrollbar)) if (ImGui.BeginPopupModal(modalTitle, ref this.feedbackModalDrawing, ImGuiWindowFlags.AlwaysAutoResize | ImGuiWindowFlags.NoScrollbar))
{ {
ImGui.Text(Locs.FeedbackModal_Text); ImGui.Text(Locs.FeedbackModal_Text(this.feedbackPlugin.Name));
ImGui.Spacing(); ImGui.Spacing();
ImGui.InputTextMultiline("###FeedbackContent", ref this.feedbackModalBody, 1000, new Vector2(400, 200)); ImGui.InputTextMultiline("###FeedbackContent", ref this.feedbackModalBody, 1000, new Vector2(400, 200));
@ -1342,7 +1342,7 @@ namespace Dalamud.Interface.Internal.Windows
this.DrawDeletePluginButton(plugin); this.DrawDeletePluginButton(plugin);
this.DrawVisitRepoUrlButton(plugin.Manifest.RepoUrl); this.DrawVisitRepoUrlButton(plugin.Manifest.RepoUrl);
if (!isThirdParty) if (!isThirdParty && !plugin.IsDev)
{ {
this.DrawSendFeedbackButton(plugin.Manifest); this.DrawSendFeedbackButton(plugin.Manifest);
} }
@ -2292,7 +2292,7 @@ namespace Dalamud.Interface.Internal.Windows
public static string FeedbackModal_Title => Loc.Localize("InstallerFeedback", "Send Feedback"); public static string FeedbackModal_Title => Loc.Localize("InstallerFeedback", "Send Feedback");
public static string FeedbackModal_Text => Loc.Localize("InstallerFeedbackInfo", "You can send feedback to the developer of this plugin here.\nYou can include your Discord tag or email address if you wish to give them the opportunity to answer."); public static string FeedbackModal_Text(string pluginName) => Loc.Localize("InstallerFeedbackInfo", "You can send feedback to the developer of \"{0}\" here.\nYou can include your Discord tag or email address if you wish to give them the opportunity to answer.").Format(pluginName);
public static string FeedbackModal_Hint => Loc.Localize("InstallerFeedbackHint", "All plugin developers will be able to see your feedback.\nPlease never include any personal or revealing information.\nIf you chose to include the last error message, information like your Windows username may be included.\n\nThe collected feedback is not stored on our end and immediately relayed to Discord."); public static string FeedbackModal_Hint => Loc.Localize("InstallerFeedbackHint", "All plugin developers will be able to see your feedback.\nPlease never include any personal or revealing information.\nIf you chose to include the last error message, information like your Windows username may be included.\n\nThe collected feedback is not stored on our end and immediately relayed to Discord.");

View file

@ -198,7 +198,7 @@ namespace Dalamud.Interface.Internal.Windows.StyleEditor
{ {
var style = ImGui.GetStyle(); var style = ImGui.GetStyle();
if (ImGui.BeginTabItem("Variables")) if (ImGui.BeginTabItem(Loc.Localize("StyleEditorVariables", "Variables")))
{ {
ImGui.BeginChild($"ScrollingVars", ImGuiHelpers.ScaledVector2(0, -32), true, ImGuiWindowFlags.HorizontalScrollbar | ImGuiWindowFlags.NoBackground); ImGui.BeginChild($"ScrollingVars", ImGuiHelpers.ScaledVector2(0, -32), true, ImGuiWindowFlags.HorizontalScrollbar | ImGuiWindowFlags.NoBackground);
@ -250,7 +250,7 @@ namespace Dalamud.Interface.Internal.Windows.StyleEditor
ImGui.EndTabItem(); ImGui.EndTabItem();
} }
if (ImGui.BeginTabItem("Colors")) if (ImGui.BeginTabItem(Loc.Localize("StyleEditorColors", "Colors")))
{ {
ImGui.BeginChild("ScrollingColors", ImGuiHelpers.ScaledVector2(0, -30), true, ImGuiWindowFlags.HorizontalScrollbar | ImGuiWindowFlags.NoBackground); ImGui.BeginChild("ScrollingColors", ImGuiHelpers.ScaledVector2(0, -30), true, ImGuiWindowFlags.HorizontalScrollbar | ImGuiWindowFlags.NoBackground);

View file

@ -13,7 +13,7 @@ namespace Dalamud.Support
/// </summary> /// </summary>
internal static class BugBait internal static class BugBait
{ {
private const string BugBaitUrl = "https://dalamud-bugbait.goatsoft.workers.dev/feedback"; private const string BugBaitUrl = "https://kiko.goats.dev/feedback";
/// <summary> /// <summary>
/// Send feedback to Discord. /// Send feedback to Discord.