1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 14:17:26 +08:00

Expose panel height from non-drawable models

This commit is contained in:
Dean Herbert 2020-10-12 12:37:41 +09:00
parent a393bbe8f7
commit 9193f5b0ba
3 changed files with 6 additions and 0 deletions

View File

@ -12,6 +12,8 @@ namespace osu.Game.Screens.Select.Carousel
{
public class CarouselBeatmapSet : CarouselGroupEagerSelect
{
public float TotalHeight => DrawableCarouselBeatmapSet.HEIGHT + BeatmapSet.Beatmaps.Count * DrawableCarouselBeatmap.HEIGHT;
public IEnumerable<CarouselBeatmap> Beatmaps => InternalChildren.OfType<CarouselBeatmap>();
public BeatmapSetInfo BeatmapSet;

View File

@ -31,6 +31,8 @@ namespace osu.Game.Screens.Select.Carousel
{
public class DrawableCarouselBeatmap : DrawableCarouselItem, IHasContextMenu
{
public const float HEIGHT = MAX_HEIGHT;
private readonly BeatmapInfo beatmap;
private Sprite background;

View File

@ -29,6 +29,8 @@ namespace osu.Game.Screens.Select.Carousel
{
public class DrawableCarouselBeatmapSet : DrawableCarouselItem, IHasContextMenu
{
public const float HEIGHT = MAX_HEIGHT;
private Action<BeatmapSetInfo> restoreHiddenRequested;
private Action<int> viewDetails;