mirror of
https://github.com/ppy/osu.git
synced 2025-02-15 20:53:00 +08:00
Tidy up visual appearance of settings and add a reset button
This commit is contained in:
parent
2dc2cb04c3
commit
9b70f0ee1f
@ -66,6 +66,8 @@ namespace osu.Game.Overlays.Settings.Sections.Input
|
|||||||
offsetY.MaxValue = val.NewValue.Height;
|
offsetY.MaxValue = val.NewValue.Height;
|
||||||
sizeY.Default = sizeY.MaxValue = val.NewValue.Height;
|
sizeY.Default = sizeY.MaxValue = val.NewValue.Height;
|
||||||
|
|
||||||
|
areaSize.Default = new Size(sizeX.Default, sizeY.Default);
|
||||||
|
|
||||||
updateDisplay();
|
updateDisplay();
|
||||||
}, true);
|
}, true);
|
||||||
}
|
}
|
||||||
@ -77,31 +79,44 @@ namespace osu.Game.Overlays.Settings.Sections.Input
|
|||||||
|
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
new SettingsSlider<int>
|
|
||||||
{
|
|
||||||
LabelText = "Offset X",
|
|
||||||
Current = offsetX
|
|
||||||
},
|
|
||||||
new SettingsSlider<int>
|
|
||||||
{
|
|
||||||
LabelText = "Offset Y",
|
|
||||||
Current = offsetY
|
|
||||||
},
|
|
||||||
new SettingsSlider<int>
|
|
||||||
{
|
|
||||||
LabelText = "Size X",
|
|
||||||
Current = sizeX
|
|
||||||
},
|
|
||||||
new SettingsSlider<int>
|
|
||||||
{
|
|
||||||
LabelText = "Size Y",
|
|
||||||
Current = sizeY
|
|
||||||
},
|
|
||||||
new TabletAreaSelection(tabletHandler)
|
new TabletAreaSelection(tabletHandler)
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
Height = 300,
|
Height = 300,
|
||||||
}
|
},
|
||||||
|
new SettingsButton
|
||||||
|
{
|
||||||
|
Text = "Reset to full area",
|
||||||
|
Action = () =>
|
||||||
|
{
|
||||||
|
areaOffset.SetDefault();
|
||||||
|
areaSize.SetDefault();
|
||||||
|
},
|
||||||
|
},
|
||||||
|
new SettingsCheckbox
|
||||||
|
{
|
||||||
|
LabelText = "Lock aspect ratio",
|
||||||
|
},
|
||||||
|
new SettingsSlider<int>
|
||||||
|
{
|
||||||
|
LabelText = "X Offset",
|
||||||
|
Current = offsetX
|
||||||
|
},
|
||||||
|
new SettingsSlider<int>
|
||||||
|
{
|
||||||
|
LabelText = "Y Offset",
|
||||||
|
Current = offsetY
|
||||||
|
},
|
||||||
|
new SettingsSlider<int>
|
||||||
|
{
|
||||||
|
LabelText = "Width",
|
||||||
|
Current = sizeX
|
||||||
|
},
|
||||||
|
new SettingsSlider<int>
|
||||||
|
{
|
||||||
|
LabelText = "Height",
|
||||||
|
Current = sizeY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user