From cff619b0e406823df149704560f7154f210fb0c5 Mon Sep 17 00:00:00 2001 From: Andrei Zavatski Date: Tue, 4 Feb 2020 14:46:22 +0300 Subject: [PATCH] Adjust overlay layout --- osu.Game/Overlays/BeatmapSetOverlay.cs | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/osu.Game/Overlays/BeatmapSetOverlay.cs b/osu.Game/Overlays/BeatmapSetOverlay.cs index e4e928df18..f747cfff16 100644 --- a/osu.Game/Overlays/BeatmapSetOverlay.cs +++ b/osu.Game/Overlays/BeatmapSetOverlay.cs @@ -9,7 +9,6 @@ using osu.Framework.Graphics.Containers; using osu.Framework.Graphics.Shapes; using osu.Framework.Input.Events; using osu.Game.Beatmaps; -using osu.Game.Graphics; using osu.Game.Graphics.Containers; using osu.Game.Online.API.Requests; using osu.Game.Overlays.BeatmapSet; @@ -33,6 +32,8 @@ namespace osu.Game.Overlays // receive input outside our bounds so we can trigger a close event on ourselves. public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => true; + private readonly Box background; + public BeatmapSetOverlay() : base(OverlayColourScheme.Blue) { @@ -41,10 +42,9 @@ namespace osu.Game.Overlays Children = new Drawable[] { - new Box + background = new Box { - RelativeSizeAxes = Axes.Both, - Colour = OsuColour.Gray(0.2f) + RelativeSizeAxes = Axes.Both }, scroll = new OsuScrollContainer { @@ -55,10 +55,20 @@ namespace osu.Game.Overlays RelativeSizeAxes = Axes.X, AutoSizeAxes = Axes.Y, Direction = FillDirection.Vertical, + Spacing = new Vector2(0, 20), Children = new Drawable[] { - Header = new Header(), - info = new Info(), + new ReverseChildIDFillFlowContainer + { + AutoSizeAxes = Axes.Y, + RelativeSizeAxes = Axes.X, + Direction = FillDirection.Vertical, + Children = new Drawable[] + { + Header = new Header(), + info = new Info() + } + }, new ScoresContainer { Beatmap = { BindTarget = Header.Picker.Beatmap } @@ -83,6 +93,8 @@ namespace osu.Game.Overlays private void load(RulesetStore rulesets) { this.rulesets = rulesets; + + background.Colour = ColourProvider.Background6; } protected override void PopOutComplete()