From c63d692a02aa04c85b70ee384c792b3d3d6ec151 Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:04:39 +0800 Subject: [PATCH 1/7] Update osu.game to the latest. --- osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj index 1cdb6e341..214400b43 100644 --- a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj +++ b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj @@ -18,7 +18,7 @@ all runtime; build; native; contentfiles; analyzers; buildtransitive - + From 234fa35d8d35d4bb20e6a3a6bce647570550be24 Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:08:50 +0800 Subject: [PATCH 2/7] Get clipboard instance instad of game host. --- .../Overlays/TestSceneOverlayColourProvider.cs | 4 ++-- .../Lyrics/Components/TestSceneLyricEditorColourProvider.cs | 4 ++-- .../Screens/Edit/Beatmaps/Lyrics/LyricEditorClipboard.cs | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/osu.Game.Rulesets.Karaoke.Tests/Overlays/TestSceneOverlayColourProvider.cs b/osu.Game.Rulesets.Karaoke.Tests/Overlays/TestSceneOverlayColourProvider.cs index 4eb8d3fbe..ba7dddb0e 100644 --- a/osu.Game.Rulesets.Karaoke.Tests/Overlays/TestSceneOverlayColourProvider.cs +++ b/osu.Game.Rulesets.Karaoke.Tests/Overlays/TestSceneOverlayColourProvider.cs @@ -78,7 +78,7 @@ public TitleTableColumn(string title) private partial class PreviewColourDrawable : CompositeDrawable { [Resolved] - private GameHost host { get; set; } = null!; + private Clipboard clipboard { get; set; } = null!; private readonly Color4 color; @@ -105,7 +105,7 @@ public PreviewColourDrawable(Color4 color) protected override bool OnClick(ClickEvent e) { - host.GetClipboard()?.SetText(color.ToHex()); + clipboard.SetText(color.ToHex()); return base.OnClick(e); } } diff --git a/osu.Game.Rulesets.Karaoke.Tests/Screens/Edit/Beatmap/Lyrics/Components/TestSceneLyricEditorColourProvider.cs b/osu.Game.Rulesets.Karaoke.Tests/Screens/Edit/Beatmap/Lyrics/Components/TestSceneLyricEditorColourProvider.cs index 208a0c4d3..aa68ee8c8 100644 --- a/osu.Game.Rulesets.Karaoke.Tests/Screens/Edit/Beatmap/Lyrics/Components/TestSceneLyricEditorColourProvider.cs +++ b/osu.Game.Rulesets.Karaoke.Tests/Screens/Edit/Beatmap/Lyrics/Components/TestSceneLyricEditorColourProvider.cs @@ -108,7 +108,7 @@ public TitleTableColumn(string title) private partial class PreviewColourDrawable : CompositeDrawable { [Resolved] - private GameHost host { get; set; } = null!; + private Clipboard clipboard { get; set; } = null!; private readonly Color4 color; @@ -135,7 +135,7 @@ public PreviewColourDrawable(Color4 color) protected override bool OnClick(ClickEvent e) { - host.GetClipboard()?.SetText(color.ToHex()); + clipboard.SetText(color.ToHex()); return base.OnClick(e); } } diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorClipboard.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorClipboard.cs index f075ab4ec..605637419 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorClipboard.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorClipboard.cs @@ -25,7 +25,7 @@ namespace osu.Game.Rulesets.Karaoke.Screens.Edit.Beatmaps.Lyrics; public partial class LyricEditorClipboard : Component, ILyricEditorClipboard { [Resolved] - private GameHost host { get; set; } = null!; + private Clipboard clipboard { get; set; } = null!; [Resolved] private OnScreenDisplay? onScreenDisplay { get; set; } @@ -412,7 +412,7 @@ private void copyObjectToClipboard(T obj) var settings = KaraokeJsonSerializableExtensions.CreateGlobalSettings(); string text = JsonConvert.SerializeObject(obj, settings); - host.GetClipboard()?.SetText(text); + clipboard.SetText(text); } private void saveObjectToTheClipboardContent(T obj) From 240313d75ef3af792bf65ae41368924db015281e Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:09:28 +0800 Subject: [PATCH 3/7] Adjust the const naming. See: https://github.com/ppy/osu/commit/5f880397a94ea968aba752e7ab658c28bab58312 --- .../Overlays/Changelog/Sidebar/ChangelogSidebar.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game.Rulesets.Karaoke/Overlays/Changelog/Sidebar/ChangelogSidebar.cs b/osu.Game.Rulesets.Karaoke/Overlays/Changelog/Sidebar/ChangelogSidebar.cs index 09e2cd1fa..b112f00ea 100644 --- a/osu.Game.Rulesets.Karaoke/Overlays/Changelog/Sidebar/ChangelogSidebar.cs +++ b/osu.Game.Rulesets.Karaoke/Overlays/Changelog/Sidebar/ChangelogSidebar.cs @@ -39,7 +39,7 @@ private void load(OverlayColourProvider colourProvider, Bindable Date: Sun, 16 Jul 2023 19:10:01 +0800 Subject: [PATCH 4/7] Add non-null annotation because technically the value should be be null. --- .../IO/Stores/BaseGlyphStoreTest.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game.Rulesets.Karaoke.Tests/IO/Stores/BaseGlyphStoreTest.cs b/osu.Game.Rulesets.Karaoke.Tests/IO/Stores/BaseGlyphStoreTest.cs index 051de7727..b24b9789a 100644 --- a/osu.Game.Rulesets.Karaoke.Tests/IO/Stores/BaseGlyphStoreTest.cs +++ b/osu.Game.Rulesets.Karaoke.Tests/IO/Stores/BaseGlyphStoreTest.cs @@ -75,8 +75,8 @@ public void CompareGetBaseHeightWithOrigin() [TestCase('#')] public void CompareGetCharacterGlyphWithOrigin(char c) { - var expected = GlyphStore.Get(c); - var actual = CustomizeGlyphStore.Get(c); + var expected = GlyphStore.Get(c)!; + var actual = CustomizeGlyphStore.Get(c)!; // because get character glyph should make sure that this glyph store contains char, so will not be null. Assert.IsNotNull(expected); From c363d701e3aca88a2e0f641d323517d74fe165b7 Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:10:45 +0800 Subject: [PATCH 5/7] Upgrade font and microphone package to the latest. --- osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj index 214400b43..ea8e77950 100644 --- a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj +++ b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj @@ -12,8 +12,8 @@ - - + + all runtime; build; native; contentfiles; analyzers; buildtransitive From 7bed3786d3dafe50f36fd36bc3a57634b2ffb3aa Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:14:51 +0800 Subject: [PATCH 6/7] Update the LocalisationAnalyser package to the latest. --- osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj index ea8e77950..2d5921de9 100644 --- a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj +++ b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj @@ -14,7 +14,7 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive From 2c016289d553fd9f211ba9c96513b1b4a0e1d6ff Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 16 Jul 2023 19:15:16 +0800 Subject: [PATCH 7/7] Update the octokit to the latest. --- osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj index 2d5921de9..a62dca649 100644 --- a/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj +++ b/osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj @@ -11,7 +11,7 @@ - +