1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 06:47:24 +08:00

Move IsLoaded check inside BeatmapCarousel

This commit is contained in:
Dean Herbert 2023-01-18 12:00:47 +09:00
parent 8e1002b744
commit 4ad79a8a0a
2 changed files with 6 additions and 6 deletions

View File

@ -596,6 +596,9 @@ namespace osu.Game.Screens.Select
public void FlushPendingFilterOperations() public void FlushPendingFilterOperations()
{ {
if (!IsLoaded)
return;
if (PendingFilter?.Completed == false) if (PendingFilter?.Completed == false)
{ {
applyActiveCriteria(false); applyActiveCriteria(false);

View File

@ -860,12 +860,9 @@ namespace osu.Game.Screens.Select
Logger.Log($"decoupled ruleset transferred (\"{decoupledRuleset.Value}\" -> \"{Ruleset.Value}\")"); Logger.Log($"decoupled ruleset transferred (\"{decoupledRuleset.Value}\" -> \"{Ruleset.Value}\")");
rulesetNoDebounce = decoupledRuleset.Value = Ruleset.Value; rulesetNoDebounce = decoupledRuleset.Value = Ruleset.Value;
if (Carousel.IsLoaded) // if we have a pending filter operation, we want to run it now.
{ // it could change selection (ie. if the ruleset has been changed).
// if we have a pending filter operation, we want to run it now. Carousel.FlushPendingFilterOperations();
// it could change selection (ie. if the ruleset has been changed).
Carousel.FlushPendingFilterOperations();
}
return true; return true;
} }