Update tests and delay push animation until loader is done disappearing

This commit is contained in:
Dean Herbert
2020-03-11 13:20:31 +09:00
parent 4012e878b0
commit ec88f7a712
3 changed files with 23 additions and 13 deletions

View File

@ -5,6 +5,7 @@ using System.Collections.Generic;
using System.Linq;
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shaders;
using osu.Framework.Utils;
using osu.Game.Screens.Menu;
@ -87,8 +88,14 @@ namespace osu.Game.Screens
}
spinnerShow?.Cancel();
spinner.Hide();
this.Push(loadableScreen);
if (spinner.State.Value == Visibility.Visible)
{
spinner.Hide();
Scheduler.AddDelayed(() => this.Push(loadableScreen), LoadingSpinner.TRANSITION_DURATION);
}
else
this.Push(loadableScreen);
}
[BackgroundDependencyLoader]