Use localisation engine instead of asking current culture directly.

This commit is contained in:
Huo Yaoyuan 2017-10-15 16:30:52 +08:00
parent bed5a64ee2
commit 192ebe776f
2 changed files with 2 additions and 2 deletions

View File

@ -402,7 +402,7 @@ private void loadUser()
scoreText.Add(createScoreText("Ranked Score"));
scoreNumberText.Add(createScoreNumberText(user.Statistics.RankedScore.ToString(@"#,0")));
scoreText.Add(createScoreText("Accuracy"));
scoreNumberText.Add(createScoreNumberText($"{user.Statistics.Accuracy.ToString("0.##", CultureInfo.CurrentCulture)}%"));
scoreNumberText.Add(createScoreNumberText($"{user.Statistics.Accuracy.ToString("0.##")}%"));
scoreText.Add(createScoreText("Play Count"));
scoreNumberText.Add(createScoreNumberText(user.Statistics.PlayCount.ToString(@"#,0")));
scoreText.Add(createScoreText("Total Score"));

View File

@ -92,7 +92,7 @@ private void load(OsuColour colour, LocalisationEngine locale, BeatmapSetOverlay
{
stats.Add(new OsuSpriteText
{
Text = $"weighted: {Math.Round(score.PP * weight ?? 0)}pp ({weight.Value.ToString("0%", CultureInfo.CurrentCulture)})",
Current = locale.Format($"weighted: {score.PP * weight ?? 0:0}pp ({weight:0%})"),
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
Colour = colour.GrayA,