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

Merge pull request #28765 from bdach/editor-menu-max-height

Fix editor menus overflowing off screen
This commit is contained in:
Dan Balasescu 2024-07-08 19:13:30 +09:00 committed by GitHub
commit b2bdb67a3e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 2 deletions

View File

@ -71,7 +71,10 @@ namespace osu.Game.Screens.Edit.Components.Menus
});
}
protected override Framework.Graphics.UserInterface.Menu CreateSubMenu() => new SubMenu();
protected override Framework.Graphics.UserInterface.Menu CreateSubMenu() => new SubMenu
{
MaxHeight = MaxHeight,
};
protected override DrawableMenuItem CreateDrawableMenuItem(MenuItem item) => new DrawableEditorBarMenuItem(item);
@ -143,7 +146,10 @@ namespace osu.Game.Screens.Edit.Components.Menus
BackgroundColour = colourProvider.Background2;
}
protected override Framework.Graphics.UserInterface.Menu CreateSubMenu() => new SubMenu();
protected override Framework.Graphics.UserInterface.Menu CreateSubMenu() => new SubMenu
{
MaxHeight = MaxHeight,
};
protected override DrawableMenuItem CreateDrawableMenuItem(MenuItem item)
{

View File

@ -343,6 +343,7 @@ namespace osu.Game.Screens.Edit
Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft,
RelativeSizeAxes = Axes.Both,
MaxHeight = 600,
Items = new[]
{
new MenuItem(CommonStrings.MenuBarFile)