Refactor SeedSettingsControl and related controls

This commit is contained in:
Henry Lin
2021-06-26 11:19:14 +08:00
parent 31c786e1c3
commit 3b822cd5cf
5 changed files with 70 additions and 77 deletions

View File

@ -7,15 +7,11 @@ namespace osu.Game.Overlays.Settings
{
public class SettingsNumberBox : SettingsItem<string>
{
protected override Drawable CreateControl() => new NumberBox
protected override Drawable CreateControl() => new OutlinedNumberBox
{
Margin = new MarginPadding { Top = 5 },
RelativeSizeAxes = Axes.X,
CommitOnFocusLost = true
};
public class NumberBox : SettingsTextBox.TextBox
{
protected override bool CanAddCharacter(char character) => char.IsNumber(character);
}
}
}