mirror of
https://github.com/ppy/osu.git
synced 2025-03-11 01:47:45 +08:00
Cancel ApplyDefaults()
when requested
Also didn't notice a particular case here, but if all code passes up until we get to the `foreach (var h in nestedHitObjects)` below, then we could end up stuck here for quite a while.
This commit is contained in:
parent
52dad09b20
commit
033952029e
@ -104,6 +104,8 @@ namespace osu.Game.Rulesets.Objects
|
|||||||
/// <param name="cancellationToken">The cancellation token.</param>
|
/// <param name="cancellationToken">The cancellation token.</param>
|
||||||
public void ApplyDefaults(ControlPointInfo controlPointInfo, IBeatmapDifficultyInfo difficulty, CancellationToken cancellationToken = default)
|
public void ApplyDefaults(ControlPointInfo controlPointInfo, IBeatmapDifficultyInfo difficulty, CancellationToken cancellationToken = default)
|
||||||
{
|
{
|
||||||
|
cancellationToken.ThrowIfCancellationRequested();
|
||||||
|
|
||||||
ApplyDefaultsToSelf(controlPointInfo, difficulty);
|
ApplyDefaultsToSelf(controlPointInfo, difficulty);
|
||||||
|
|
||||||
nestedHitObjects.Clear();
|
nestedHitObjects.Clear();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user