mirror of
https://github.com/ppy/osu.git
synced 2024-12-16 00:52:59 +08:00
Fix ranked status dropdown expanding below the panels
This commit is contained in:
parent
2f10b72cb2
commit
649fc8362b
@ -2,6 +2,7 @@
|
||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using OpenTK;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
@ -81,7 +82,7 @@ namespace osu.Game.Overlays
|
||||
Padding = new MarginPadding { Top = Header.HEIGHT },
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new FillFlowContainer
|
||||
new ContentFlow
|
||||
{
|
||||
RelativeSizeAxes = Axes.X,
|
||||
AutoSizeAxes = Axes.Y,
|
||||
@ -118,7 +119,7 @@ namespace osu.Game.Overlays
|
||||
var p = new List<DirectPanel>();
|
||||
|
||||
foreach (BeatmapSetInfo b in BeatmapSets)
|
||||
p.Add(displayStyle == PanelDisplayStyle.Grid ? (DirectPanel)(new DirectGridPanel(b) { Width = 400}) :
|
||||
p.Add(displayStyle == PanelDisplayStyle.Grid ? (DirectPanel)(new DirectGridPanel(b) { Width = 400 }) :
|
||||
(DirectPanel)(new DirectListPanel(b)));
|
||||
|
||||
panels.Children = p;
|
||||
@ -138,5 +139,16 @@ namespace osu.Game.Overlays
|
||||
|
||||
filter.Search.HoldFocus = false;
|
||||
}
|
||||
|
||||
private class ContentFlow : FillFlowContainer<Drawable>
|
||||
{
|
||||
protected override IComparer<Drawable> DepthComparer => new ReverseCreationOrderDepthComparer();
|
||||
protected override IEnumerable<Drawable> FlowingChildren => base.FlowingChildren.Reverse();
|
||||
|
||||
public ContentFlow()
|
||||
{
|
||||
Direction = FillDirection.Vertical;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user