1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-21 02:32:56 +08:00

Allow OsuButton be auto-sized

This commit is contained in:
ansel 2022-11-29 05:44:40 +03:00
parent d20dc3668e
commit 25ddd20b2e

View File

@ -175,6 +175,17 @@ namespace osu.Game.Graphics.UserInterface
base.OnMouseUp(e);
}
public new Axes AutoSizeAxes
{
get => base.AutoSizeAxes;
set
{
base.AutoSizeAxes = value;
Content.RelativeSizeAxes = ~value;
Content.AutoSizeAxes = value;
}
}
protected virtual SpriteText CreateText() => new OsuSpriteText
{
Depth = -1,