mirror of
https://github.com/ppy/osu.git
synced 2026-05-23 01:40:03 +08:00
Use LocalisableString interpolation to make strings update properly
This commit is contained in:
@@ -266,8 +266,8 @@ namespace osu.Game.Tournament.Screens.Schedule
|
||||
}
|
||||
|
||||
protected override LocalisableString Format() => Date < DateTimeOffset.Now
|
||||
? $"Started {base.Format()}"
|
||||
: $"Starting {base.Format()}";
|
||||
? LocalisableString.Interpolate($"Started {base.Format()}")
|
||||
: LocalisableString.Interpolate($"Starting {base.Format()}");
|
||||
}
|
||||
|
||||
public partial class ScheduleContainer : Container
|
||||
|
||||
@@ -71,7 +71,7 @@ namespace osu.Game.Screens.OnlinePlay.Lounge.Components
|
||||
var diffToNow = Date.Subtract(DateTimeOffset.Now);
|
||||
|
||||
if (diffToNow.TotalSeconds < -5)
|
||||
return $"Closed {base.Format()}";
|
||||
return LocalisableString.Interpolate($"Closed {base.Format()}");
|
||||
|
||||
if (diffToNow.TotalSeconds < 0)
|
||||
return "Closed";
|
||||
@@ -79,7 +79,7 @@ namespace osu.Game.Screens.OnlinePlay.Lounge.Components
|
||||
if (diffToNow.TotalSeconds < 5)
|
||||
return "Closing soon";
|
||||
|
||||
return $"Closing {base.Format()}";
|
||||
return LocalisableString.Interpolate($"Closing {base.Format()}");
|
||||
}
|
||||
|
||||
protected override void Dispose(bool isDisposing)
|
||||
|
||||
Reference in New Issue
Block a user