mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 17:32:54 +08:00
Adjust editor transparent tweens to be less "flashy"
Touched on in https://github.com/ppy/osu/discussions/28581. After a bit more usage of the editor I do agree with this and think that making the fades a bit more gentle helps a lot.
This commit is contained in:
parent
c100d1ab65
commit
aadcc5384d
@ -269,9 +269,16 @@ namespace osu.Game.Rulesets.Edit
|
|||||||
|
|
||||||
composerFocusMode.BindValueChanged(_ =>
|
composerFocusMode.BindValueChanged(_ =>
|
||||||
{
|
{
|
||||||
float targetAlpha = composerFocusMode.Value ? 0.5f : 1;
|
if (!composerFocusMode.Value)
|
||||||
leftToolboxBackground.FadeTo(targetAlpha, 400, Easing.OutQuint);
|
{
|
||||||
rightToolboxBackground.FadeTo(targetAlpha, 400, Easing.OutQuint);
|
leftToolboxBackground.FadeIn(750, Easing.OutQuint);
|
||||||
|
rightToolboxBackground.FadeIn(750, Easing.OutQuint);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
leftToolboxBackground.Delay(600).FadeTo(0.5f, 4000, Easing.OutQuint);
|
||||||
|
rightToolboxBackground.Delay(600).FadeTo(0.5f, 4000, Easing.OutQuint);
|
||||||
|
}
|
||||||
}, true);
|
}, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -82,10 +82,13 @@ namespace osu.Game.Screens.Edit
|
|||||||
saveInProgress.BindValueChanged(_ => TestGameplayButton.Enabled.Value = !saveInProgress.Value, true);
|
saveInProgress.BindValueChanged(_ => TestGameplayButton.Enabled.Value = !saveInProgress.Value, true);
|
||||||
composerFocusMode.BindValueChanged(_ =>
|
composerFocusMode.BindValueChanged(_ =>
|
||||||
{
|
{
|
||||||
float targetAlpha = composerFocusMode.Value ? 0.5f : 1;
|
|
||||||
|
|
||||||
foreach (var c in this.ChildrenOfType<BottomBarContainer>())
|
foreach (var c in this.ChildrenOfType<BottomBarContainer>())
|
||||||
c.Background.FadeTo(targetAlpha, 400, Easing.OutQuint);
|
{
|
||||||
|
if (!composerFocusMode.Value)
|
||||||
|
c.Background.FadeIn(750, Easing.OutQuint);
|
||||||
|
else
|
||||||
|
c.Background.Delay(600).FadeTo(0.5f, 4000, Easing.OutQuint);
|
||||||
|
}
|
||||||
}, true);
|
}, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -132,7 +132,13 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
|||||||
{
|
{
|
||||||
base.LoadComplete();
|
base.LoadComplete();
|
||||||
|
|
||||||
composerFocusMode.BindValueChanged(_ => timelineBackground.FadeTo(composerFocusMode.Value ? 0.5f : 1, 400, Easing.OutQuint), true);
|
composerFocusMode.BindValueChanged(_ =>
|
||||||
|
{
|
||||||
|
if (!composerFocusMode.Value)
|
||||||
|
timelineBackground.FadeIn(750, Easing.OutQuint);
|
||||||
|
else
|
||||||
|
timelineBackground.Delay(600).FadeTo(0.5f, 4000, Easing.OutQuint);
|
||||||
|
}, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user