mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 16:43:00 +08:00
Consume SoloStatisticsWatcher
updates in toolbar button
This commit is contained in:
parent
14052ae1cc
commit
eae43f5fd9
@ -26,7 +26,7 @@ namespace osu.Game.Overlays.Toolbar
|
||||
private Statistic<decimal> pp = null!;
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load()
|
||||
private void load(SoloStatisticsWatcher? soloStatisticsWatcher)
|
||||
{
|
||||
RelativeSizeAxes = Axes.Y;
|
||||
AutoSizeAxes = Axes.X;
|
||||
@ -45,6 +45,9 @@ namespace osu.Game.Overlays.Toolbar
|
||||
pp = new Statistic<decimal>(RankingsStrings.StatPerformance, string.Empty, Comparer<decimal>.Create((before, after) => Math.Sign(after - before))),
|
||||
}
|
||||
};
|
||||
|
||||
if (soloStatisticsWatcher != null)
|
||||
((IBindable<SoloStatisticsUpdate?>)LatestUpdate).BindTo(soloStatisticsWatcher.LatestUpdate);
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
|
@ -41,9 +41,6 @@ namespace osu.Game.Screens.Ranking
|
||||
|
||||
public override bool? AllowGlobalTrackControl => true;
|
||||
|
||||
// Temporary for now to stop dual transitions. Should respect the current toolbar mode, but there's no way to do so currently.
|
||||
public override bool HideOverlaysOnEnter => true;
|
||||
|
||||
public readonly Bindable<ScoreInfo> SelectedScore = new Bindable<ScoreInfo>();
|
||||
|
||||
[CanBeNull]
|
||||
|
Loading…
Reference in New Issue
Block a user