mirror of https://github.com/ppy/osu
Share localised strings with expanded display message
This commit is contained in:
parent
3f8cedff3a
commit
5d8bd1de28
|
@ -12,7 +12,7 @@ public static class ToolbarStrings
|
|||
/// <summary>
|
||||
/// "Connection interrupted, will try to reconnect..."
|
||||
/// </summary>
|
||||
public static LocalisableString ConnectionInterruptedWillTryTo => new TranslatableString(getKey(@"connection_interrupted_will_try_to"), @"Connection interrupted, will try to reconnect...");
|
||||
public static LocalisableString AttemptingToReconnect => new TranslatableString(getKey(@"attempting_to_reconnect"), @"Connection interrupted, will try to reconnect...");
|
||||
|
||||
/// <summary>
|
||||
/// "Connecting..."
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
using osu.Game.Graphics.Containers;
|
||||
using osu.Game.Graphics.Sprites;
|
||||
using osu.Game.Graphics.UserInterface;
|
||||
using osu.Game.Localisation;
|
||||
using osu.Game.Online.API;
|
||||
using osu.Game.Users;
|
||||
using osuTK;
|
||||
|
@ -109,7 +110,7 @@ private void onlineStateChanged(ValueChangedEvent<APIState> state) => Schedule((
|
|||
Origin = Anchor.TopCentre,
|
||||
TextAnchor = Anchor.TopCentre,
|
||||
AutoSizeAxes = Axes.Both,
|
||||
Text = state.NewValue == APIState.Failing ? "Connection is failing, will attempt to reconnect... " : "Attempting to connect... ",
|
||||
Text = state.NewValue == APIState.Failing ? ToolbarStrings.AttemptingToReconnect : ToolbarStrings.Connecting,
|
||||
Margin = new MarginPadding { Top = 10, Bottom = 10 },
|
||||
},
|
||||
};
|
||||
|
|
|
@ -107,7 +107,7 @@ private void onlineStateChanged(ValueChangedEvent<APIState> state) => Schedule((
|
|||
break;
|
||||
|
||||
case APIState.Failing:
|
||||
TooltipText = ToolbarStrings.ConnectionInterruptedWillTryTo;
|
||||
TooltipText = ToolbarStrings.AttemptingToReconnect;
|
||||
spinner.Show();
|
||||
break;
|
||||
|
||||
|
|
Loading…
Reference in New Issue