1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 12:07:23 +08:00

Simplify weird conditionals

This commit is contained in:
Dean Herbert 2021-08-16 22:07:41 +09:00
parent e39a295c5c
commit 568d027013

View File

@ -266,24 +266,16 @@ namespace osu.Game.Overlays.Settings.Sections.Input
private void updateVisibility()
{
if (!tabletHandler.Enabled.Value)
{
mainSettings.Hide();
noTabletMessage.Hide();
return;
}
bool tabletFound = tablet.Value != null;
if (!tabletFound)
{
mainSettings.Hide();
noTabletMessage.Show();
return;
}
mainSettings.Show();
mainSettings.Hide();
noTabletMessage.Hide();
if (!tabletHandler.Enabled.Value)
return;
if (tablet.Value != null)
mainSettings.Show();
else
noTabletMessage.Show();
}
private void applyAspectRatio(BindableNumber<float> sizeChanged)