mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 10:52:53 +08:00
Merge pull request #4240 from ThePyrotechnic/MissingSource
Improve layout of beatmap details pane when source is unknown
This commit is contained in:
commit
a11a7fa6f1
@ -21,7 +21,7 @@ namespace osu.Game.Tests.Visual
|
||||
Padding = new MarginPadding(150),
|
||||
});
|
||||
|
||||
AddStep("beatmap all metrics", () => details.Beatmap = new BeatmapInfo
|
||||
AddStep("all metrics", () => details.Beatmap = new BeatmapInfo
|
||||
{
|
||||
Version = "All Metrics",
|
||||
Metadata = new BeatmapMetadata
|
||||
@ -45,7 +45,30 @@ namespace osu.Game.Tests.Visual
|
||||
},
|
||||
});
|
||||
|
||||
AddStep("beatmap ratings", () => details.Beatmap = new BeatmapInfo
|
||||
AddStep("all except source", () => details.Beatmap = new BeatmapInfo
|
||||
{
|
||||
Version = "All Metrics",
|
||||
Metadata = new BeatmapMetadata
|
||||
{
|
||||
Tags = "this beatmap has all the metrics",
|
||||
},
|
||||
BaseDifficulty = new BeatmapDifficulty
|
||||
{
|
||||
CircleSize = 7,
|
||||
DrainRate = 1,
|
||||
OverallDifficulty = 5.7f,
|
||||
ApproachRate = 3.5f,
|
||||
},
|
||||
StarDifficulty = 5.3f,
|
||||
Metrics = new BeatmapMetrics
|
||||
{
|
||||
Ratings = Enumerable.Range(0, 11),
|
||||
Fails = Enumerable.Range(1, 100).Select(i => i % 12 - 6),
|
||||
Retries = Enumerable.Range(-2, 100).Select(i => i % 12 - 6),
|
||||
},
|
||||
});
|
||||
|
||||
AddStep("ratings", () => details.Beatmap = new BeatmapInfo
|
||||
{
|
||||
Version = "Only Ratings",
|
||||
Metadata = new BeatmapMetadata
|
||||
@ -67,7 +90,7 @@ namespace osu.Game.Tests.Visual
|
||||
},
|
||||
});
|
||||
|
||||
AddStep("beatmap fails retries", () => details.Beatmap = new BeatmapInfo
|
||||
AddStep("fails retries", () => details.Beatmap = new BeatmapInfo
|
||||
{
|
||||
Version = "Only Retries and Fails",
|
||||
Metadata = new BeatmapMetadata
|
||||
@ -90,7 +113,7 @@ namespace osu.Game.Tests.Visual
|
||||
},
|
||||
});
|
||||
|
||||
AddStep("beatmap no metrics", () => details.Beatmap = new BeatmapInfo
|
||||
AddStep("no metrics", () => details.Beatmap = new BeatmapInfo
|
||||
{
|
||||
Version = "No Metrics",
|
||||
Metadata = new BeatmapMetadata
|
||||
|
@ -116,6 +116,7 @@ namespace osu.Game.Screens.Select
|
||||
RelativeSizeAxes = Axes.X,
|
||||
AutoSizeAxes = Axes.Y,
|
||||
LayoutDuration = transition_duration,
|
||||
LayoutEasing = Easing.OutQuad,
|
||||
Spacing = new Vector2(spacing * 2),
|
||||
Margin = new MarginPadding { Top = spacing * 2 },
|
||||
Children = new[]
|
||||
@ -336,10 +337,12 @@ namespace osu.Game.Screens.Select
|
||||
{
|
||||
if (string.IsNullOrEmpty(value))
|
||||
{
|
||||
textContainer.FadeOut(transition_duration);
|
||||
this.FadeOut(transition_duration);
|
||||
return;
|
||||
}
|
||||
|
||||
this.FadeIn(transition_duration);
|
||||
|
||||
setTextAsync(value);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user