mirror of
https://github.com/ppy/osu.git
synced 2025-02-15 23:42:55 +08:00
Refactor the menu's max height to be a property
This commit is contained in:
parent
bdc440f11c
commit
9cb9ef5c56
@ -14,13 +14,15 @@ namespace osu.Game.Overlays.Settings
|
||||
|
||||
protected new class DropdownControl : OsuEnumDropdown<T>
|
||||
{
|
||||
protected virtual int MenuMaxHeight => 200;
|
||||
|
||||
public DropdownControl()
|
||||
{
|
||||
Margin = new MarginPadding { Top = 5 };
|
||||
RelativeSizeAxes = Axes.X;
|
||||
}
|
||||
|
||||
protected override DropdownMenu CreateMenu() => base.CreateMenu().With(m => m.MaxHeight = 200);
|
||||
protected override DropdownMenu CreateMenu() => base.CreateMenu().With(m => m.MaxHeight = MenuMaxHeight);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user