Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some comment actions not being lowercased #21707

Merged
merged 2 commits into from
Dec 19, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion osu.Game/Overlays/Comments/CommentReportButton.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

using osu.Framework.Allocation;
using osu.Framework.Extensions;
using osu.Framework.Extensions.LocalisationExtensions;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Cursor;
Expand Down Expand Up @@ -53,7 +54,7 @@ private void load()
}
};

link.AddLink(UsersStrings.ReportButtonText, this.ShowPopover);
link.AddLink(ReportStrings.CommentButton.ToLower(), this.ShowPopover);
}

private void report(CommentReportReason reason, string comments)
Expand Down
3 changes: 2 additions & 1 deletion osu.Game/Overlays/Comments/DrawableComment.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
using osu.Framework.Graphics.Shapes;
using osu.Framework.Extensions.IEnumerableExtensions;
using System.Collections.Specialized;
using osu.Framework.Extensions.LocalisationExtensions;
using osu.Framework.Localisation;
using osu.Framework.Platform;
using osu.Game.Graphics.UserInterface;
Expand Down Expand Up @@ -335,7 +336,7 @@ private void load(OverlayColourProvider colourProvider)
actionsContainer.AddArbitraryDrawable(Empty().With(d => d.Width = 10));

if (Comment.UserId.HasValue && Comment.UserId.Value == api.LocalUser.Value.Id)
actionsContainer.AddLink(CommonStrings.ButtonsDelete, deleteComment);
actionsContainer.AddLink(CommonStrings.ButtonsDelete.ToLower(), deleteComment);
else
actionsContainer.AddArbitraryDrawable(new CommentReportButton(Comment));

Expand Down