mirror of
https://github.com/osukey/osukey.git
synced 2025-07-05 10:19:54 +09:00
Refactor the menu's max height to be a property
This commit is contained in:
@ -14,13 +14,15 @@ namespace osu.Game.Overlays.Settings
|
|||||||
|
|
||||||
protected new class DropdownControl : OsuEnumDropdown<T>
|
protected new class DropdownControl : OsuEnumDropdown<T>
|
||||||
{
|
{
|
||||||
|
protected virtual int MenuMaxHeight => 200;
|
||||||
|
|
||||||
public DropdownControl()
|
public DropdownControl()
|
||||||
{
|
{
|
||||||
Margin = new MarginPadding { Top = 5 };
|
Margin = new MarginPadding { Top = 5 };
|
||||||
RelativeSizeAxes = Axes.X;
|
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);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user