mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-13 12:14:16 +01:00
Re-apply feedback patches
This commit is contained in:
parent
a2305c7a1d
commit
1fc7c14b51
2 changed files with 35 additions and 16 deletions
|
|
@ -387,11 +387,16 @@ namespace Dalamud.Interface.Internal.Windows
|
||||||
{
|
{
|
||||||
ImGui.Text(Locs.FeedbackModal_Text(this.feedbackPlugin.Name));
|
ImGui.Text(Locs.FeedbackModal_Text(this.feedbackPlugin.Name));
|
||||||
|
|
||||||
if (this.pluginListUpdatable.Any(
|
if (this.feedbackPlugin?.FeedbackMessage != null)
|
||||||
up => up.InstalledPlugin.Manifest.InternalName == this.feedbackPlugin?.InternalName))
|
{
|
||||||
{
|
ImGui.TextWrapped(this.feedbackPlugin.FeedbackMessage);
|
||||||
ImGui.TextColored(ImGuiColors.DalamudRed, Locs.FeedbackModal_HasUpdate);
|
}
|
||||||
}
|
|
||||||
|
if (this.pluginListUpdatable.Any(
|
||||||
|
up => up.InstalledPlugin.Manifest.InternalName == this.feedbackPlugin?.InternalName))
|
||||||
|
{
|
||||||
|
ImGui.TextColored(ImGuiColors.DalamudRed, Locs.FeedbackModal_HasUpdate);
|
||||||
|
}
|
||||||
|
|
||||||
ImGui.Spacing();
|
ImGui.Spacing();
|
||||||
|
|
||||||
|
|
@ -1226,10 +1231,10 @@ namespace Dalamud.Interface.Internal.Windows
|
||||||
|
|
||||||
this.DrawVisitRepoUrlButton(manifest.RepoUrl);
|
this.DrawVisitRepoUrlButton(manifest.RepoUrl);
|
||||||
|
|
||||||
if (!manifest.SourceRepo.IsThirdParty)
|
if (!manifest.SourceRepo.IsThirdParty && manifest.AcceptsFeedback)
|
||||||
{
|
{
|
||||||
this.DrawSendFeedbackButton(manifest);
|
this.DrawSendFeedbackButton(manifest);
|
||||||
}
|
}
|
||||||
|
|
||||||
ImGuiHelpers.ScaledDummy(5);
|
ImGuiHelpers.ScaledDummy(5);
|
||||||
|
|
||||||
|
|
@ -1400,8 +1405,8 @@ namespace Dalamud.Interface.Internal.Windows
|
||||||
ImGui.SameLine();
|
ImGui.SameLine();
|
||||||
ImGui.TextColored(ImGuiColors.DalamudGrey3, downloadText);
|
ImGui.TextColored(ImGuiColors.DalamudGrey3, downloadText);
|
||||||
|
|
||||||
var isThirdParty = manifest.IsThirdParty;
|
var isThirdParty = manifest.IsThirdParty;
|
||||||
var canFeedback = !isThirdParty && !plugin.IsDev && plugin.Manifest.DalamudApiLevel == PluginManager.DalamudApiLevel;
|
var canFeedback = !isThirdParty && !plugin.IsDev && plugin.Manifest.DalamudApiLevel == PluginManager.DalamudApiLevel && plugin.Manifest.AcceptsFeedback;
|
||||||
|
|
||||||
// Installed from
|
// Installed from
|
||||||
if (plugin.IsDev)
|
if (plugin.IsDev)
|
||||||
|
|
|
||||||
|
|
@ -157,9 +157,23 @@ namespace Dalamud.Plugin.Internal.Types
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public List<string>? ImageUrls { get; init; }
|
public List<string>? ImageUrls { get; init; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets an URL for the plugin's icon.
|
/// Gets an URL for the plugin's icon.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string? IconUrl { get; init; }
|
public string? IconUrl { get; init; }
|
||||||
}
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets a value that indicates whether or not this plugin accepts feedback.
|
||||||
|
/// </summary>
|
||||||
|
public bool AcceptsFeedback { get; init; } = true;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets a message that is shown to users when sending feedback.
|
||||||
|
/// </summary>
|
||||||
|
public string? FeedbackMessage { get; init; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets a value indicating the webhook URL feedback is sent to.
|
||||||
|
/// </summary>
|
||||||
|
public string? FeedbackWebhook { get; init; }
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue