Add initial game-wide beatmap flow.

This commit is contained in:
Dean Herbert
2016-10-28 19:55:48 +09:00
parent 0f5614ffa2
commit 74f1a9622f
10 changed files with 197 additions and 51 deletions

View File

@ -2,6 +2,7 @@
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Collections.Generic;
using System.Linq;
using osu.Framework;
using osu.Framework.Graphics;
@ -27,6 +28,8 @@ namespace osu.Game.Beatmaps.Drawable
private BeatmapGroupState state;
public IEnumerable<BeatmapPanel> BeatmapPanels;
public BeatmapGroupState State
{
get { return state; }
@ -62,6 +65,16 @@ namespace osu.Game.Beatmaps.Drawable
AutoSizeAxes = Axes.Y;
RelativeSizeAxes = Axes.X;
BeatmapPanels = beatmapSet.Beatmaps.Select(b =>
new BeatmapPanel(this.beatmapSet, b)
{
GainedSelection = panelGainedSelection,
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
RelativeSizeAxes = Axes.X,
});
Children = new[]
{
new FlowContainer
@ -87,15 +100,7 @@ namespace osu.Game.Beatmaps.Drawable
Spacing = new Vector2(0, 5),
Direction = FlowDirection.VerticalOnly,
Alpha = 0,
Children = this.beatmapSet.Beatmaps.Select(b =>
new BeatmapPanel(this.beatmapSet, b)
{
GainedSelection = panelGainedSelection,
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
RelativeSizeAxes = Axes.X,
}
)
Children = BeatmapPanels
}
}
}