diff --git a/osu.Game/Localisation/BeatmapLeaderboardWedgeStrings.cs b/osu.Game/Localisation/BeatmapLeaderboardWedgeStrings.cs index 124bf93ec4..68c1920a1b 100644 --- a/osu.Game/Localisation/BeatmapLeaderboardWedgeStrings.cs +++ b/osu.Game/Localisation/BeatmapLeaderboardWedgeStrings.cs @@ -39,6 +39,36 @@ namespace osu.Game.Localisation /// public static LocalisableString Team => new TranslatableString(getKey(@"team"), @"Team"); + /// + /// "Sort" + /// + public static LocalisableString Sort => new TranslatableString(getKey(@"sort"), @"Sort"); + + /// + /// "Score" + /// + public static LocalisableString Score => new TranslatableString(getKey(@"score"), @"Score"); + + /// + /// "Accuracy" + /// + public static LocalisableString Accuracy => new TranslatableString(getKey(@"accuracy"), @"Accuracy"); + + /// + /// "Max Combo" + /// + public static LocalisableString MaxCombo => new TranslatableString(getKey(@"max_combo"), @"Max Combo"); + + /// + /// "Misses" + /// + public static LocalisableString Misses => new TranslatableString(getKey(@"misses"), @"Misses"); + + /// + /// "Date" + /// + public static LocalisableString Date => new TranslatableString(getKey(@"date"), @"Date"); + private static string getKey(string key) => $@"{prefix}:{key}"; } } diff --git a/osu.Game/Screens/Select/Leaderboards/LeaderboardSortMode.cs b/osu.Game/Screens/Select/Leaderboards/LeaderboardSortMode.cs index edf38fa8cc..d5fb2f3c54 100644 --- a/osu.Game/Screens/Select/Leaderboards/LeaderboardSortMode.cs +++ b/osu.Game/Screens/Select/Leaderboards/LeaderboardSortMode.cs @@ -1,19 +1,26 @@ // Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. // See the LICENCE file in the repository root for full licence text. -using System.ComponentModel; +using osu.Framework.Localisation; +using osu.Game.Localisation; namespace osu.Game.Screens.Select.Leaderboards { public enum LeaderboardSortMode { + [LocalisableDescription(typeof(BeatmapLeaderboardWedgeStrings), nameof(BeatmapLeaderboardWedgeStrings.Score))] Score, + + [LocalisableDescription(typeof(BeatmapLeaderboardWedgeStrings), nameof(BeatmapLeaderboardWedgeStrings.Accuracy))] Accuracy, - [Description("Max Combo")] + [LocalisableDescription(typeof(BeatmapLeaderboardWedgeStrings), nameof(BeatmapLeaderboardWedgeStrings.MaxCombo))] MaxCombo, + [LocalisableDescription(typeof(BeatmapLeaderboardWedgeStrings), nameof(BeatmapLeaderboardWedgeStrings.Misses))] Misses, + + [LocalisableDescription(typeof(BeatmapLeaderboardWedgeStrings), nameof(BeatmapLeaderboardWedgeStrings.Date))] Date, } } diff --git a/osu.Game/Screens/SelectV2/BeatmapDetailsArea_Header.cs b/osu.Game/Screens/SelectV2/BeatmapDetailsArea_Header.cs index b51bbe37bc..06feaf829b 100644 --- a/osu.Game/Screens/SelectV2/BeatmapDetailsArea_Header.cs +++ b/osu.Game/Screens/SelectV2/BeatmapDetailsArea_Header.cs @@ -69,10 +69,17 @@ namespace osu.Game.Screens.SelectV2 Height = 30, Spacing = new Vector2(5f, 0f), Direction = FillDirection.Horizontal, - Padding = new MarginPadding { Left = 125, Right = 133 }, + Padding = new MarginPadding { Left = 258 }, Children = new Drawable[] { - sortDropdown = new ShearedDropdown("Sort") + selectedModsToggle = new ShearedToggleButton + { + Anchor = Anchor.CentreRight, + Origin = Anchor.CentreRight, + Text = UserInterfaceStrings.SelectedMods, + Height = 30f, + }, + sortDropdown = new ShearedDropdown(BeatmapLeaderboardWedgeStrings.Sort) { Anchor = Anchor.TopRight, Origin = Anchor.TopRight, @@ -90,19 +97,6 @@ namespace osu.Game.Screens.SelectV2 }, }, }, - new Container - { - Anchor = Anchor.CentreRight, - Origin = Anchor.CentreRight, - Size = new Vector2(128f, 30f), - Child = selectedModsToggle = new ShearedToggleButton - { - Anchor = Anchor.Centre, - Origin = Anchor.Centre, - Text = @"Selected Mods", - Height = 30, - }, - }, }, }, };