From 425be20e462f32af5ca4a5103383a664f281315e Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Wed, 22 Mar 2023 14:13:42 +0900 Subject: [PATCH 1/3] Fix song select search textbox font size incorrectly having increased --- osu.Game/Screens/Select/FilterControl.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/osu.Game/Screens/Select/FilterControl.cs b/osu.Game/Screens/Select/FilterControl.cs index b44ca8ac04..38520a85b7 100644 --- a/osu.Game/Screens/Select/FilterControl.cs +++ b/osu.Game/Screens/Select/FilterControl.cs @@ -257,6 +257,7 @@ namespace osu.Game.Screens.Select public FilterControlTextBox() { Height += filter_text_size; + TextContainer.Height *= (Height - filter_text_size) / Height; TextContainer.Margin = new MarginPadding { Bottom = filter_text_size }; } From 540b38dc2191691047b7ccf646c2b82541870233 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Thu, 23 Mar 2023 14:01:19 +0900 Subject: [PATCH 2/3] Fix tournament interface save button not usable after changing match progression/round --- osu.Game.Tournament/TournamentGameBase.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/osu.Game.Tournament/TournamentGameBase.cs b/osu.Game.Tournament/TournamentGameBase.cs index 7e19cb3aa5..634cc87a9f 100644 --- a/osu.Game.Tournament/TournamentGameBase.cs +++ b/osu.Game.Tournament/TournamentGameBase.cs @@ -332,13 +332,6 @@ namespace osu.Game.Tournament private void saveChanges() { - foreach (var r in ladder.Rounds) - r.Matches = ladder.Matches.Where(p => p.Round.Value == r).Select(p => p.ID).ToList(); - - ladder.Progressions = ladder.Matches.Where(p => p.Progression.Value != null).Select(p => new TournamentProgression(p.ID, p.Progression.Value.ID)).Concat( - ladder.Matches.Where(p => p.LosersProgression.Value != null).Select(p => new TournamentProgression(p.ID, p.LosersProgression.Value.ID, true))) - .ToList(); - // Serialise before opening stream for writing, so if there's a failure it will leave the file in the previous state. string serialisedLadder = GetSerialisedLadder(); @@ -349,6 +342,13 @@ namespace osu.Game.Tournament public string GetSerialisedLadder() { + foreach (var r in ladder.Rounds) + r.Matches = ladder.Matches.Where(p => p.Round.Value == r).Select(p => p.ID).ToList(); + + ladder.Progressions = ladder.Matches.Where(p => p.Progression.Value != null).Select(p => new TournamentProgression(p.ID, p.Progression.Value.ID)).Concat( + ladder.Matches.Where(p => p.LosersProgression.Value != null).Select(p => new TournamentProgression(p.ID, p.LosersProgression.Value.ID, true))) + .ToList(); + return JsonConvert.SerializeObject(ladder, new JsonSerializerSettings { From e1906a90eb8f6ea79140490304b06ee3453f1508 Mon Sep 17 00:00:00 2001 From: Joseph Madamba Date: Tue, 21 Mar 2023 13:23:08 -0700 Subject: [PATCH 3/3] Use `image@2x` from tournament banner api --- osu.Game.Tests/Visual/Online/TestSceneUserProfileOverlay.cs | 1 + osu.Game/Users/TournamentBanner.cs | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/osu.Game.Tests/Visual/Online/TestSceneUserProfileOverlay.cs b/osu.Game.Tests/Visual/Online/TestSceneUserProfileOverlay.cs index a97c8aff66..4278c46d6a 100644 --- a/osu.Game.Tests/Visual/Online/TestSceneUserProfileOverlay.cs +++ b/osu.Game.Tests/Visual/Online/TestSceneUserProfileOverlay.cs @@ -126,6 +126,7 @@ namespace osu.Game.Tests.Visual.Online Id = 13926, TournamentId = 35, ImageLowRes = "https://assets.ppy.sh/tournament-banners/official/owc2022/profile/winner_US.jpg", + Image = "https://assets.ppy.sh/tournament-banners/official/owc2022/profile/winner_US@2x.jpg", }, Badges = new[] { diff --git a/osu.Game/Users/TournamentBanner.cs b/osu.Game/Users/TournamentBanner.cs index 62e1913412..e7fada1eff 100644 --- a/osu.Game/Users/TournamentBanner.cs +++ b/osu.Game/Users/TournamentBanner.cs @@ -1,7 +1,6 @@ // Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. // See the LICENCE file in the repository root for full licence text. -using System.IO; using Newtonsoft.Json; namespace osu.Game.Users @@ -17,7 +16,7 @@ namespace osu.Game.Users [JsonProperty("image")] public string ImageLowRes = null!; - // TODO: remove when api returns @2x image link: https://github.com/ppy/osu-web/issues/9816 - public string Image => $@"{Path.ChangeExtension(ImageLowRes, null)}@2x{Path.GetExtension(ImageLowRes)}"; + [JsonProperty("image@2x")] + public string Image = null!; } }