mirror of
https://github.com/osukey/osukey.git
synced 2025-05-16 11:07:35 +09:00
Fix in a slightly different and hopefully more understandable way
This commit is contained in:
parent
f56b85ce27
commit
ee1ccb8bcb
@ -426,7 +426,7 @@ namespace osu.Game.Screens.Select
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// selection has been changed as the result of a user interaction.
|
/// Selection has been changed as the result of a user interaction.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void performUpdateSelected()
|
private void performUpdateSelected()
|
||||||
{
|
{
|
||||||
@ -435,7 +435,7 @@ namespace osu.Game.Screens.Select
|
|||||||
|
|
||||||
selectionChangedDebounce?.Cancel();
|
selectionChangedDebounce?.Cancel();
|
||||||
|
|
||||||
if (beatmap == null)
|
if (beatmapNoDebounce == null)
|
||||||
run();
|
run();
|
||||||
else
|
else
|
||||||
selectionChangedDebounce = Scheduler.AddDelayed(run, 200);
|
selectionChangedDebounce = Scheduler.AddDelayed(run, 200);
|
||||||
@ -448,11 +448,11 @@ namespace osu.Game.Screens.Select
|
|||||||
{
|
{
|
||||||
Mods.Value = Array.Empty<Mod>();
|
Mods.Value = Array.Empty<Mod>();
|
||||||
|
|
||||||
// the ruleset transfer may cause a deselection of the current beatmap (due to incompatibility).
|
// transferRulesetValue() may trigger a refilter. If the current selection does not match the new ruleset, we want to switch away from it.
|
||||||
// this can happen via Carousel.FlushPendingFilterOperations().
|
// The default logic on WorkingBeatmap change is to switch to a matching ruleset (see workingBeatmapChanged()), but we don't want that here.
|
||||||
// to ensure a good state, re-transfer no-debounce values.
|
// We perform an early selection attempt and clear out the beatmap selection to avoid a second ruleset change (revert).
|
||||||
performUpdateSelected();
|
if (beatmap != null && !Carousel.SelectBeatmap(beatmap, false))
|
||||||
return;
|
beatmap = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
// We may be arriving here due to another component changing the bindable Beatmap.
|
// We may be arriving here due to another component changing the bindable Beatmap.
|
||||||
@ -716,7 +716,7 @@ namespace osu.Game.Screens.Select
|
|||||||
if (decoupledRuleset.Value?.Equals(Ruleset.Value) == true)
|
if (decoupledRuleset.Value?.Equals(Ruleset.Value) == true)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
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 we have a pending filter operation, we want to run it now.
|
// if we have a pending filter operation, we want to run it now.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user