1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 20:13:21 +08:00

Fix revert-to-default button appearing on disabled settings regardless of value

This commit is contained in:
Salman Ahmed 2024-01-18 14:20:07 +03:00
parent 22cfc86050
commit b97c3ac9ee

View File

@ -115,7 +115,12 @@ namespace osu.Game.Overlays
Enabled.Value = !current.Disabled;
this.FadeTo(current.Disabled ? 0.2f : (current.IsDefault ? 0 : 1), fade_duration, Easing.OutQuint);
if (current.IsDefault)
this.FadeTo(0, fade_duration, Easing.OutQuint);
else if (current.Disabled)
this.FadeTo(0.2f, fade_duration, Easing.OutQuint);
else
this.FadeTo(1, fade_duration, Easing.OutQuint);
if (IsHovered && Enabled.Value)
{