mirror of
https://github.com/ppy/osu
synced 2025-01-10 08:09:40 +00:00
Merge pull request #4331 from nyquillerium/ScrollingExitFix
Fix song select background not being exited in time for main menu
This commit is contained in:
commit
638e89effa
@ -54,10 +54,10 @@ namespace osu.Game.Screens.Menu
|
||||
buttons = new ButtonSystem
|
||||
{
|
||||
OnChart = delegate { this.Push(new ChartListing()); },
|
||||
OnDirect = delegate {this.Push(new OnlineListing()); },
|
||||
OnEdit = delegate {this.Push(new Editor()); },
|
||||
OnDirect = delegate { this.Push(new OnlineListing()); },
|
||||
OnEdit = delegate { this.Push(new Editor()); },
|
||||
OnSolo = onSolo,
|
||||
OnMulti = delegate {this.Push(new Multiplayer()); },
|
||||
OnMulti = delegate { this.Push(new Multiplayer()); },
|
||||
OnExit = this.Exit,
|
||||
}
|
||||
}
|
||||
@ -100,7 +100,7 @@ namespace osu.Game.Screens.Menu
|
||||
|
||||
public void LoadToSolo() => Schedule(onSolo);
|
||||
|
||||
private void onSolo() =>this.Push(consumeSongSelect());
|
||||
private void onSolo() => this.Push(consumeSongSelect());
|
||||
|
||||
private Screen consumeSongSelect()
|
||||
{
|
||||
@ -184,7 +184,7 @@ namespace osu.Game.Screens.Menu
|
||||
{
|
||||
base.OnResuming(last);
|
||||
|
||||
((BackgroundScreenDefault)Background).Next();
|
||||
(Background as BackgroundScreenDefault)?.Next();
|
||||
|
||||
//we may have consumed our preloaded instance, so let's make another.
|
||||
preloadSongSelect();
|
||||
@ -201,7 +201,7 @@ namespace osu.Game.Screens.Menu
|
||||
{
|
||||
if (!e.Repeat && e.ControlPressed && e.ShiftPressed && e.Key == Key.D)
|
||||
{
|
||||
this.Push(new Drawings());
|
||||
this.Push(new Drawings());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -285,7 +285,7 @@ namespace osu.Game.Screens.Select
|
||||
|
||||
public void Edit(BeatmapInfo beatmap = null)
|
||||
{
|
||||
Beatmap.Value = beatmaps.GetWorkingBeatmap(beatmap ?? beatmapNoDebounce);
|
||||
Beatmap.Value = beatmaps.GetWorkingBeatmap(beatmap ?? beatmapNoDebounce);
|
||||
this.Push(new Editor());
|
||||
}
|
||||
|
||||
@ -509,14 +509,15 @@ namespace osu.Game.Screens.Select
|
||||
|
||||
public override bool OnExiting(IScreen next)
|
||||
{
|
||||
if (base.OnExiting(next))
|
||||
return true;
|
||||
|
||||
if (ModSelect.State == Visibility.Visible)
|
||||
{
|
||||
ModSelect.Hide();
|
||||
return true;
|
||||
}
|
||||
|
||||
FinaliseSelection(performStartAction: false);
|
||||
|
||||
beatmapInfoWedge.State = Visibility.Hidden;
|
||||
|
||||
this.FadeOut(100);
|
||||
@ -529,7 +530,7 @@ namespace osu.Game.Screens.Select
|
||||
SelectedMods.UnbindAll();
|
||||
Beatmap.Value.Mods.Value = new Mod[] { };
|
||||
|
||||
return base.OnExiting(next);
|
||||
return false;
|
||||
}
|
||||
|
||||
protected override void Dispose(bool isDisposing)
|
||||
|
Loading…
Reference in New Issue
Block a user