From 96100a2200b424b774b4fb778b7affb41c3c434d Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Wed, 20 Jun 2018 17:41:48 +0900 Subject: [PATCH] Remove schedule logic (seems unnecessary) --- osu.Game/Screens/Multi/Screens/Match/Header.cs | 4 ++-- osu.Game/Screens/Multi/Screens/Match/Match.cs | 2 +- osu.Game/Screens/Select/MatchSongSelect.cs | 7 +------ 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/osu.Game/Screens/Multi/Screens/Match/Header.cs b/osu.Game/Screens/Multi/Screens/Match/Header.cs index 19e9dc4ad4..2bd015a2d1 100644 --- a/osu.Game/Screens/Multi/Screens/Match/Header.cs +++ b/osu.Game/Screens/Multi/Screens/Match/Header.cs @@ -34,7 +34,7 @@ namespace osu.Game.Screens.Multi.Screens.Match set => cover.BeatmapSet = value; } - public Action OnWantsSelectBeatmap; + public Action OnRequestSelectBeatmap; public Header() { @@ -89,7 +89,7 @@ namespace osu.Game.Screens.Multi.Screens.Match }, }; - beatmapButton.Action = () => OnWantsSelectBeatmap?.Invoke(); + beatmapButton.Action = () => OnRequestSelectBeatmap?.Invoke(); } [BackgroundDependencyLoader] diff --git a/osu.Game/Screens/Multi/Screens/Match/Match.cs b/osu.Game/Screens/Multi/Screens/Match/Match.cs index b231ed89e5..ce3f7825a4 100644 --- a/osu.Game/Screens/Multi/Screens/Match/Match.cs +++ b/osu.Game/Screens/Multi/Screens/Match/Match.cs @@ -50,7 +50,7 @@ namespace osu.Game.Screens.Multi.Screens.Match }, }; - header.OnWantsSelectBeatmap = () => Push(new MatchSongSelect()); + header.OnRequestSelectBeatmap = () => Push(new MatchSongSelect()); beatmapBind.BindTo(room.Beatmap); beatmapBind.BindValueChanged(b => diff --git a/osu.Game/Screens/Select/MatchSongSelect.cs b/osu.Game/Screens/Select/MatchSongSelect.cs index a0c96d0cee..339392d5cf 100644 --- a/osu.Game/Screens/Select/MatchSongSelect.cs +++ b/osu.Game/Screens/Select/MatchSongSelect.cs @@ -7,12 +7,7 @@ namespace osu.Game.Screens.Select { protected override bool OnStart() { - Schedule(() => - { - // needs to be scheduled else we enter an infinite feedback loop. - if (IsCurrentScreen) Exit(); - }); - + if (IsCurrentScreen) Exit(); return true; } }