From 374479f837b3e56e527b6682d9d7234f78ea4adf Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 6 Sep 2019 19:00:49 +0900 Subject: [PATCH 01/20] Add truncatino of long usernames in chat --- .../Online/TestSceneChatLineTruncation.cs | 108 ++++++++++++++++++ osu.Game/Overlays/Chat/ChatLine.cs | 10 +- 2 files changed, 116 insertions(+), 2 deletions(-) create mode 100644 osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs diff --git a/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs b/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs new file mode 100644 index 0000000000..888e55ab0a --- /dev/null +++ b/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs @@ -0,0 +1,108 @@ +// Copyright (c) 2007-2018 ppy Pty Ltd . +// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE + +using System; +using System.Collections.Generic; +using NUnit.Framework; +using osu.Framework.Allocation; +using osu.Framework.Graphics; +using osu.Framework.Graphics.Containers; +using osu.Game.Graphics.Containers; +using osu.Game.Online.Chat; +using osu.Game.Overlays.Chat; +using osu.Game.Users; + +namespace osu.Game.Tests.Visual.Online +{ + [TestFixture] + public class TestSceneChatLineTruncation : OsuTestScene + { + private readonly TestChatLineContainer textContainer; + + public override IReadOnlyList RequiredTypes => new[] + { + typeof(ChatLine), + typeof(Message), + typeof(LinkFlowContainer), + typeof(MessageFormatter) + }; + + public TestSceneChatLineTruncation() + { + Add(textContainer = new TestChatLineContainer + { + Padding = new MarginPadding { Left = 20, Right = 20 }, + RelativeSizeAxes = Axes.X, + AutoSizeAxes = Axes.Y, + Direction = FillDirection.Vertical, + }); + } + + [BackgroundDependencyLoader] + private void load() + { + testFormatting(); + } + + private void clear() => AddStep("clear messages", textContainer.Clear); + + private void addMessageWithChecks(string text, bool isAction = false, bool isImportant = false, string username = null) + { + int index = textContainer.Count + 1; + var newLine = new ChatLine(new DummyMessage(text, isAction, isImportant, index, username)); + textContainer.Add(newLine); + } + + private void testFormatting() + { + for (int a = 0; a < 25; a++) + addMessageWithChecks($"Wide {a} character username.", username: new string('w', a)); + addMessageWithChecks("Short name with spaces.", username: "sho rt name"); + addMessageWithChecks("Long name with spaces.", username: "long name with s p a c e s"); + } + + private class DummyMessage : Message + { + private static long messageCounter; + + internal static readonly User TEST_SENDER_BACKGROUND = new User + { + Username = @"i-am-important", + Id = 42, + Colour = "#250cc9", + }; + + internal static readonly User TEST_SENDER = new User + { + Username = @"Somebody", + Id = 1, + }; + + public new DateTimeOffset Timestamp = DateTimeOffset.Now; + + public DummyMessage(string text, bool isAction = false, bool isImportant = false, int number = 0, string username = null) + : base(messageCounter++) + { + Content = text; + IsAction = isAction; + Sender = new User + { + Username = username ?? $"user {number}", + Id = number, + Colour = isImportant ? "#250cc9" : null, + }; + } + } + + private class TestChatLineContainer : FillFlowContainer + { + protected override int Compare(Drawable x, Drawable y) + { + var xC = (ChatLine)x; + var yC = (ChatLine)y; + + return xC.Message.CompareTo(yC.Message); + } + } + } +} diff --git a/osu.Game/Overlays/Chat/ChatLine.cs b/osu.Game/Overlays/Chat/ChatLine.cs index 2576b38ec8..a07b6472a3 100644 --- a/osu.Game/Overlays/Chat/ChatLine.cs +++ b/osu.Game/Overlays/Chat/ChatLine.cs @@ -31,6 +31,8 @@ namespace osu.Game.Overlays.Chat protected virtual float MessagePadding => default_message_padding; + private const float timestamp_padding = 70; + private const float default_horizontal_padding = 15; protected virtual float HorizontalPadding => default_horizontal_padding; @@ -87,7 +89,10 @@ namespace osu.Game.Overlays.Chat { Shadow = false, Colour = hasBackground ? customUsernameColour : username_colours[message.Sender.Id % username_colours.Length], - Font = OsuFont.GetFont(size: TextSize, weight: FontWeight.Bold, italics: true) + Truncate = true, + EllipsisString = ".. :", + Font = OsuFont.GetFont(size: TextSize, weight: FontWeight.Bold, italics: true), + RelativeSizeAxes = Axes.Both, }; if (hasBackground) @@ -141,7 +146,8 @@ namespace osu.Game.Overlays.Chat }, new MessageSender(message.Sender) { - AutoSizeAxes = Axes.Both, + Padding = new MarginPadding { Left = timestamp_padding }, + RelativeSizeAxes = Axes.Both, Origin = Anchor.TopRight, Anchor = Anchor.TopRight, Child = effectedUsername, From c6b8f2db77313f29bdfa106a042a9ba211b009fc Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 6 Sep 2019 19:05:50 +0900 Subject: [PATCH 02/20] Update historic licence header --- osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs | 4 ++-- osu.Game/Overlays/Chat/ChatLine.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs b/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs index 888e55ab0a..4773e84a5e 100644 --- a/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs +++ b/osu.Game.Tests/Visual/Online/TestSceneChatLineTruncation.cs @@ -1,5 +1,5 @@ -// Copyright (c) 2007-2018 ppy Pty Ltd . -// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE +// Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. +// See the LICENCE file in the repository root for full licence text. using System; using System.Collections.Generic; diff --git a/osu.Game/Overlays/Chat/ChatLine.cs b/osu.Game/Overlays/Chat/ChatLine.cs index a07b6472a3..d812e007a0 100644 --- a/osu.Game/Overlays/Chat/ChatLine.cs +++ b/osu.Game/Overlays/Chat/ChatLine.cs @@ -31,7 +31,7 @@ namespace osu.Game.Overlays.Chat protected virtual float MessagePadding => default_message_padding; - private const float timestamp_padding = 70; + private const float timestamp_padding = 70; private const float default_horizontal_padding = 15; From 3435e2a8d3f2e7ab5ef9c3cf0090c72dbe0d0f21 Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Sun, 8 Sep 2019 13:36:58 +0800 Subject: [PATCH 03/20] open login on enter main menu --- osu.Game/Screens/Menu/MainMenu.cs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 499b5089f6..160ff95632 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -11,6 +11,7 @@ using osu.Framework.Screens; using osu.Game.Beatmaps; using osu.Game.Graphics; using osu.Game.Graphics.Containers; +using osu.Game.Online.API; using osu.Game.Overlays; using osu.Game.Screens.Backgrounds; using osu.Game.Screens.Charts; @@ -44,6 +45,12 @@ namespace osu.Game.Screens.Menu [Resolved(canBeNull: true)] private MusicController music { get; set; } + [Resolved(canBeNull: true)] + private LoginOverlay login { get; set; } + + [Resolved] + private IAPIProvider api { get; set; } + private BackgroundScreenDefault background; protected override BackgroundScreen CreateBackground() => background; @@ -128,6 +135,9 @@ namespace osu.Game.Screens.Menu track.Seek(metadata.PreviewTime != -1 ? metadata.PreviewTime : 0.4f * track.Length); track.Start(); } + + if (api?.State == APIState.Offline) + login?.ToggleVisibility(); } Beatmap.ValueChanged += beatmap_ValueChanged; From a67a2899a9d763b94f8b3e689fbeb6a5bc323cde Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Sun, 8 Sep 2019 16:18:15 +0800 Subject: [PATCH 04/20] move api state check to it's own clause --- osu.Game/Screens/Menu/MainMenu.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 160ff95632..10b2f827af 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -135,11 +135,11 @@ namespace osu.Game.Screens.Menu track.Seek(metadata.PreviewTime != -1 ? metadata.PreviewTime : 0.4f * track.Length); track.Start(); } - - if (api?.State == APIState.Offline) - login?.ToggleVisibility(); } + if (last is IntroScreen && api?.State == APIState.Offline) + login?.ToggleVisibility(); + Beatmap.ValueChanged += beatmap_ValueChanged; } From be4f0cc2dd19c8adfced41dd82731c22a951a523 Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Mon, 9 Sep 2019 06:14:49 +0800 Subject: [PATCH 05/20] remove null conditional --- osu.Game/Screens/Menu/MainMenu.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 10b2f827af..276c653345 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -137,7 +137,7 @@ namespace osu.Game.Screens.Menu } } - if (last is IntroScreen && api?.State == APIState.Offline) + if (last is IntroScreen && api.State == APIState.Offline) login?.ToggleVisibility(); Beatmap.ValueChanged += beatmap_ValueChanged; From eeebd517f3e5cafc0245e60668407d1bb131f5e5 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Mon, 9 Sep 2019 12:08:59 +0900 Subject: [PATCH 06/20] Use MaxWidth specification --- osu.Game/Overlays/Chat/ChatLine.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/osu.Game/Overlays/Chat/ChatLine.cs b/osu.Game/Overlays/Chat/ChatLine.cs index d812e007a0..4c37d626c0 100644 --- a/osu.Game/Overlays/Chat/ChatLine.cs +++ b/osu.Game/Overlays/Chat/ChatLine.cs @@ -31,7 +31,7 @@ namespace osu.Game.Overlays.Chat protected virtual float MessagePadding => default_message_padding; - private const float timestamp_padding = 70; + private const float timestamp_padding = 65; private const float default_horizontal_padding = 15; @@ -92,7 +92,9 @@ namespace osu.Game.Overlays.Chat Truncate = true, EllipsisString = ".. :", Font = OsuFont.GetFont(size: TextSize, weight: FontWeight.Bold, italics: true), - RelativeSizeAxes = Axes.Both, + Anchor = Anchor.TopRight, + Origin = Anchor.TopRight, + MaxWidth = default_message_padding - timestamp_padding }; if (hasBackground) From 04a4f9c9a347f45549233517479a35bf4f864f85 Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Mon, 9 Sep 2019 11:26:51 +0800 Subject: [PATCH 07/20] use IsLoggedIn and remove useless clause --- osu.Game/Screens/Menu/MainMenu.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 276c653345..79a3993874 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -137,7 +137,7 @@ namespace osu.Game.Screens.Menu } } - if (last is IntroScreen && api.State == APIState.Offline) + if (!api.IsLoggedIn) login?.ToggleVisibility(); Beatmap.ValueChanged += beatmap_ValueChanged; From c2353cbdfa7193941784799fd8d9bd473d542c27 Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Mon, 9 Sep 2019 13:30:48 +0800 Subject: [PATCH 08/20] move logic to logo action --- osu.Game/Screens/Menu/MainMenu.cs | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 79a3993874..e85d59fc72 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -39,6 +39,8 @@ namespace osu.Game.Screens.Menu private ButtonSystem buttons; + private bool loginPrompted = false; + [Resolved] private GameHost host { get; set; } @@ -137,9 +139,6 @@ namespace osu.Game.Screens.Menu } } - if (!api.IsLoggedIn) - login?.ToggleVisibility(); - Beatmap.ValueChanged += beatmap_ValueChanged; } @@ -152,6 +151,16 @@ namespace osu.Game.Screens.Menu logo.FadeColour(Color4.White, 100, Easing.OutQuint); logo.FadeIn(100, Easing.OutQuint); + logo.Action += () => + { + if (!api.IsLoggedIn && !loginPrompted) + login?.ToggleVisibility(); + + loginPrompted = true; + + return true; + }; + if (resuming) { buttons.State = ButtonSystemState.TopLevel; From ff49c4ae98622e5a05d8d8e3b122a674d1b28ccb Mon Sep 17 00:00:00 2001 From: LeNitrous Date: Mon, 9 Sep 2019 13:50:14 +0800 Subject: [PATCH 09/20] remove redundancies --- osu.Game/Screens/Menu/MainMenu.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index e85d59fc72..4c3566b3e9 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -39,7 +39,7 @@ namespace osu.Game.Screens.Menu private ButtonSystem buttons; - private bool loginPrompted = false; + private bool loginPrompted; [Resolved] private GameHost host { get; set; } From 2d636ce1472a9e19fa15698a012ac1b60b775f59 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Mon, 9 Sep 2019 17:54:53 +0900 Subject: [PATCH 10/20] Update framework --- osu.Android.props | 2 +- osu.Game/osu.Game.csproj | 2 +- osu.iOS.props | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/osu.Android.props b/osu.Android.props index 896b10133d..f76297c197 100644 --- a/osu.Android.props +++ b/osu.Android.props @@ -63,6 +63,6 @@ - + diff --git a/osu.Game/osu.Game.csproj b/osu.Game/osu.Game.csproj index 5f2aad24dc..791d2fe285 100644 --- a/osu.Game/osu.Game.csproj +++ b/osu.Game/osu.Game.csproj @@ -26,7 +26,7 @@ - + diff --git a/osu.iOS.props b/osu.iOS.props index 5027a4ef8c..0560c45edf 100644 --- a/osu.iOS.props +++ b/osu.iOS.props @@ -118,8 +118,8 @@ - - + + From 0790e9e377582117b70688865efa2abcfba2859b Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2019 11:35:26 +0000 Subject: [PATCH 11/20] Bump ppy.osu.Framework.iOS from 2019.905.0 to 2019.909.0 Bumps [ppy.osu.Framework.iOS](https://github.com/ppy/osu-framework) from 2019.905.0 to 2019.909.0. - [Release notes](https://github.com/ppy/osu-framework/releases) - [Commits](https://github.com/ppy/osu-framework/compare/2019.905.0...2019.909.0) Signed-off-by: dependabot-preview[bot] --- osu.iOS.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.iOS.props b/osu.iOS.props index 5027a4ef8c..5645862bf7 100644 --- a/osu.iOS.props +++ b/osu.iOS.props @@ -119,7 +119,7 @@ - + From 7a7c3d21a1a158691daaf39005268e5acdd3b26d Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2019 11:36:58 +0000 Subject: [PATCH 12/20] Bump ppy.osu.Framework from 2019.905.0 to 2019.909.0 Bumps [ppy.osu.Framework](https://github.com/ppy/osu-framework) from 2019.905.0 to 2019.909.0. - [Release notes](https://github.com/ppy/osu-framework/releases) - [Commits](https://github.com/ppy/osu-framework/compare/2019.905.0...2019.909.0) Signed-off-by: dependabot-preview[bot] --- osu.Game/osu.Game.csproj | 2 +- osu.iOS.props | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game/osu.Game.csproj b/osu.Game/osu.Game.csproj index 5f2aad24dc..791d2fe285 100644 --- a/osu.Game/osu.Game.csproj +++ b/osu.Game/osu.Game.csproj @@ -26,7 +26,7 @@ - + diff --git a/osu.iOS.props b/osu.iOS.props index 5027a4ef8c..77756dfd87 100644 --- a/osu.iOS.props +++ b/osu.iOS.props @@ -118,7 +118,7 @@ - + From 3b4750ab9e54033fed4a358041e9b15124feb643 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2019 11:37:09 +0000 Subject: [PATCH 13/20] Bump ppy.osu.Framework.Android from 2019.905.0 to 2019.909.0 Bumps [ppy.osu.Framework.Android](https://github.com/ppy/osu-framework) from 2019.905.0 to 2019.909.0. - [Release notes](https://github.com/ppy/osu-framework/releases) - [Commits](https://github.com/ppy/osu-framework/compare/2019.905.0...2019.909.0) Signed-off-by: dependabot-preview[bot] --- osu.Android.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Android.props b/osu.Android.props index 896b10133d..f76297c197 100644 --- a/osu.Android.props +++ b/osu.Android.props @@ -63,6 +63,6 @@ - + From 0ec642d8261d347ab5b4520f44259747185fb400 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 10 Sep 2019 01:06:37 +0900 Subject: [PATCH 14/20] Show instead of toggle --- osu.Game/Screens/Menu/MainMenu.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 4c3566b3e9..65df98551d 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -154,7 +154,7 @@ namespace osu.Game.Screens.Menu logo.Action += () => { if (!api.IsLoggedIn && !loginPrompted) - login?.ToggleVisibility(); + login?.Show(); loginPrompted = true; From f398f134e171e8284c6b8b3f5b66b10df813ffbe Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 10 Sep 2019 01:12:30 +0900 Subject: [PATCH 15/20] Remove unnecessary bool storage Also delay show slightly for better user experience. --- osu.Game/Screens/Menu/MainMenu.cs | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 65df98551d..978a1bffcd 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -39,8 +39,6 @@ namespace osu.Game.Screens.Menu private ButtonSystem buttons; - private bool loginPrompted; - [Resolved] private GameHost host { get; set; } @@ -151,16 +149,6 @@ namespace osu.Game.Screens.Menu logo.FadeColour(Color4.White, 100, Easing.OutQuint); logo.FadeIn(100, Easing.OutQuint); - logo.Action += () => - { - if (!api.IsLoggedIn && !loginPrompted) - login?.Show(); - - loginPrompted = true; - - return true; - }; - if (resuming) { buttons.State = ButtonSystemState.TopLevel; @@ -170,6 +158,14 @@ namespace osu.Game.Screens.Menu sideFlashes.Delay(FADE_IN_DURATION).FadeIn(64, Easing.InQuint); } + else if (!api.IsLoggedIn) + { + logo.Action += () => + { + Scheduler.AddDelayed(() => login?.Show(), 500); + return true; + }; + } } protected override void LogoSuspending(OsuLogo logo) From 7eb20da820128defcfd3c9a3738f5ee5b3f3b861 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 10 Sep 2019 01:17:58 +0900 Subject: [PATCH 16/20] Add back local bool (required due to action limitations) --- osu.Game/Screens/Menu/MainMenu.cs | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 978a1bffcd..18a3de7f37 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -140,6 +140,8 @@ namespace osu.Game.Screens.Menu Beatmap.ValueChanged += beatmap_ValueChanged; } + private bool loginDisplayed = false; + protected override void LogoArriving(OsuLogo logo, bool resuming) { base.LogoArriving(logo, resuming); @@ -160,11 +162,18 @@ namespace osu.Game.Screens.Menu } else if (!api.IsLoggedIn) { - logo.Action += () => + logo.Action += displayLogin; + } + + bool displayLogin() + { + if (!loginDisplayed) { Scheduler.AddDelayed(() => login?.Show(), 500); - return true; - }; + loginDisplayed = true; + } + + return true; } } From 98e384129c578742fb88408d7b00c2a69cd223a3 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 10 Sep 2019 01:34:48 +0900 Subject: [PATCH 17/20] Remove redundant initialisation --- osu.Game/Screens/Menu/MainMenu.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Screens/Menu/MainMenu.cs b/osu.Game/Screens/Menu/MainMenu.cs index 18a3de7f37..a006877082 100644 --- a/osu.Game/Screens/Menu/MainMenu.cs +++ b/osu.Game/Screens/Menu/MainMenu.cs @@ -140,7 +140,7 @@ namespace osu.Game.Screens.Menu Beatmap.ValueChanged += beatmap_ValueChanged; } - private bool loginDisplayed = false; + private bool loginDisplayed; protected override void LogoArriving(OsuLogo logo, bool resuming) { From f505a3ff1d48efea15967e3c322f6203fb8bf1cb Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 10 Sep 2019 11:44:11 +0900 Subject: [PATCH 18/20] Mark AutoGeneration tests as headless --- osu.Game.Rulesets.Mania.Tests/TestSceneAutoGeneration.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/osu.Game.Rulesets.Mania.Tests/TestSceneAutoGeneration.cs b/osu.Game.Rulesets.Mania.Tests/TestSceneAutoGeneration.cs index 20ac5eaa39..f260357df5 100644 --- a/osu.Game.Rulesets.Mania.Tests/TestSceneAutoGeneration.cs +++ b/osu.Game.Rulesets.Mania.Tests/TestSceneAutoGeneration.cs @@ -3,6 +3,7 @@ using System.Linq; using NUnit.Framework; +using osu.Framework.Testing; using osu.Game.Rulesets.Mania.Beatmaps; using osu.Game.Rulesets.Mania.Objects; using osu.Game.Rulesets.Mania.Replays; @@ -12,6 +13,7 @@ using osu.Game.Tests.Visual; namespace osu.Game.Rulesets.Mania.Tests { [TestFixture] + [HeadlessTest] public class TestSceneAutoGeneration : OsuTestScene { [Test] From 01fd08cba92f1e7c96878147259b1c2b6411abab Mon Sep 17 00:00:00 2001 From: smoogipoo Date: Tue, 10 Sep 2019 17:11:16 +0900 Subject: [PATCH 19/20] Fix broken positioning of effected usernames --- osu.Game/Overlays/Chat/ChatLine.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Overlays/Chat/ChatLine.cs b/osu.Game/Overlays/Chat/ChatLine.cs index 4c37d626c0..d125da8e92 100644 --- a/osu.Game/Overlays/Chat/ChatLine.cs +++ b/osu.Game/Overlays/Chat/ChatLine.cs @@ -148,8 +148,8 @@ namespace osu.Game.Overlays.Chat }, new MessageSender(message.Sender) { + AutoSizeAxes = Axes.Both, Padding = new MarginPadding { Left = timestamp_padding }, - RelativeSizeAxes = Axes.Both, Origin = Anchor.TopRight, Anchor = Anchor.TopRight, Child = effectedUsername, From 717a287d692e207e08231eec334f29076ad82b0c Mon Sep 17 00:00:00 2001 From: smoogipoo Date: Tue, 10 Sep 2019 17:11:26 +0900 Subject: [PATCH 20/20] Use real ellipsis character --- osu.Game/Overlays/Chat/ChatLine.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Overlays/Chat/ChatLine.cs b/osu.Game/Overlays/Chat/ChatLine.cs index d125da8e92..7596231a3d 100644 --- a/osu.Game/Overlays/Chat/ChatLine.cs +++ b/osu.Game/Overlays/Chat/ChatLine.cs @@ -90,7 +90,7 @@ namespace osu.Game.Overlays.Chat Shadow = false, Colour = hasBackground ? customUsernameColour : username_colours[message.Sender.Id % username_colours.Length], Truncate = true, - EllipsisString = ".. :", + EllipsisString = "… :", Font = OsuFont.GetFont(size: TextSize, weight: FontWeight.Bold, italics: true), Anchor = Anchor.TopRight, Origin = Anchor.TopRight,