mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 01:42:55 +08:00
Apply NRT to results statistics displays
This commit is contained in:
parent
414f023817
commit
ee9144c3bd
@ -1,8 +1,6 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Localisation;
|
using osu.Framework.Localisation;
|
||||||
using osu.Game.Graphics;
|
using osu.Game.Graphics;
|
||||||
@ -22,7 +20,7 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
{
|
{
|
||||||
private readonly double accuracy;
|
private readonly double accuracy;
|
||||||
|
|
||||||
private RollingCounter<double> counter;
|
private RollingCounter<double> counter = null!;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates a new <see cref="AccuracyStatistic"/>.
|
/// Creates a new <see cref="AccuracyStatistic"/>.
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
using osu.Framework.Extensions.Color4Extensions;
|
using osu.Framework.Extensions.Color4Extensions;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Colour;
|
using osu.Framework.Graphics.Colour;
|
||||||
@ -22,7 +20,7 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
{
|
{
|
||||||
private readonly bool isPerfect;
|
private readonly bool isPerfect;
|
||||||
|
|
||||||
private Drawable perfectText;
|
private Drawable perfectText = null!;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates a new <see cref="ComboStatistic"/>.
|
/// Creates a new <see cref="ComboStatistic"/>.
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Containers;
|
using osu.Framework.Graphics.Containers;
|
||||||
using osu.Framework.Localisation;
|
using osu.Framework.Localisation;
|
||||||
@ -21,7 +19,7 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
private readonly int count;
|
private readonly int count;
|
||||||
private readonly int? maxCount;
|
private readonly int? maxCount;
|
||||||
|
|
||||||
private RollingCounter<int> counter;
|
private RollingCounter<int> counter = null!;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates a new <see cref="CounterStatistic"/>.
|
/// Creates a new <see cref="CounterStatistic"/>.
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
@ -32,7 +30,7 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
|
|
||||||
private readonly CancellationTokenSource cancellationTokenSource = new CancellationTokenSource();
|
private readonly CancellationTokenSource cancellationTokenSource = new CancellationTokenSource();
|
||||||
|
|
||||||
private RollingCounter<int> counter;
|
private RollingCounter<int> counter = null!;
|
||||||
|
|
||||||
public PerformanceStatistic(ScoreInfo score)
|
public PerformanceStatistic(ScoreInfo score)
|
||||||
: base(BeatmapsetsStrings.ShowScoreboardHeaderspp)
|
: base(BeatmapsetsStrings.ShowScoreboardHeaderspp)
|
||||||
@ -107,7 +105,7 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
|
|
||||||
protected override void Dispose(bool isDisposing)
|
protected override void Dispose(bool isDisposing)
|
||||||
{
|
{
|
||||||
cancellationTokenSource?.Cancel();
|
cancellationTokenSource.Cancel();
|
||||||
base.Dispose(isDisposing);
|
base.Dispose(isDisposing);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Extensions.Color4Extensions;
|
using osu.Framework.Extensions.Color4Extensions;
|
||||||
using osu.Framework.Extensions.LocalisationExtensions;
|
using osu.Framework.Extensions.LocalisationExtensions;
|
||||||
@ -21,10 +19,10 @@ namespace osu.Game.Screens.Ranking.Expanded.Statistics
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public abstract partial class StatisticDisplay : CompositeDrawable
|
public abstract partial class StatisticDisplay : CompositeDrawable
|
||||||
{
|
{
|
||||||
protected SpriteText HeaderText { get; private set; }
|
protected SpriteText HeaderText { get; private set; } = null!;
|
||||||
|
|
||||||
private readonly LocalisableString header;
|
private readonly LocalisableString header;
|
||||||
private Drawable content;
|
private Drawable content = null!;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates a new <see cref="StatisticDisplay"/>.
|
/// Creates a new <see cref="StatisticDisplay"/>.
|
||||||
|
Loading…
Reference in New Issue
Block a user