mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 22:56:36 +09:00
Add details test scene + fix metrics not getting updated correctly
This commit is contained in:
@ -16,10 +16,11 @@ namespace osu.Game.Overlays.BeatmapSet
|
||||
{
|
||||
public class Details : FillFlowContainer
|
||||
{
|
||||
protected readonly UserRatings Ratings;
|
||||
|
||||
private readonly PreviewButton preview;
|
||||
private readonly BasicStats basic;
|
||||
private readonly AdvancedStats advanced;
|
||||
private readonly UserRatings ratings;
|
||||
|
||||
private BeatmapSetInfo beatmapSet;
|
||||
|
||||
@ -33,6 +34,7 @@ namespace osu.Game.Overlays.BeatmapSet
|
||||
beatmapSet = value;
|
||||
|
||||
basic.BeatmapSet = preview.BeatmapSet = BeatmapSet;
|
||||
updateDisplay();
|
||||
}
|
||||
}
|
||||
|
||||
@ -46,13 +48,12 @@ namespace osu.Game.Overlays.BeatmapSet
|
||||
if (value == beatmap) return;
|
||||
|
||||
basic.Beatmap = advanced.Beatmap = beatmap = value;
|
||||
updateDisplay();
|
||||
}
|
||||
}
|
||||
|
||||
private void updateDisplay()
|
||||
{
|
||||
ratings.Metrics = BeatmapSet?.Metrics;
|
||||
Ratings.Metrics = BeatmapSet?.Metrics;
|
||||
}
|
||||
|
||||
public Details()
|
||||
@ -87,7 +88,7 @@ namespace osu.Game.Overlays.BeatmapSet
|
||||
},
|
||||
new DetailBox
|
||||
{
|
||||
Child = ratings = new UserRatings
|
||||
Child = Ratings = new UserRatings
|
||||
{
|
||||
RelativeSizeAxes = Axes.X,
|
||||
Height = 95,
|
||||
|
Reference in New Issue
Block a user