1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 19:42:55 +08:00

Remove track fade

This commit is contained in:
Susko3 2022-02-24 10:13:27 +01:00
parent 2a2b8912c1
commit 255b3b067b

View File

@ -309,18 +309,8 @@ namespace osu.Game.Screens.Menu
if (e.Action == GlobalAction.Back && host.CanSuspendToBackground) if (e.Action == GlobalAction.Back && host.CanSuspendToBackground)
{ {
bool didSuspend = host.SuspendToBackground(); if (host.SuspendToBackground())
if (didSuspend)
{
// fade the track so the Bass.Pause() on suspend isn't as jarring.
const double fade_time = 500;
musicController.CurrentTrack
.VolumeTo(0, fade_time, Easing.Out).Then()
.VolumeTo(1, fade_time, Easing.In);
return true; return true;
}
} }
return false; return false;