mirror of
https://github.com/ppy/osu
synced 2024-12-14 19:06:07 +00:00
Inline cancellation token source creation
This commit is contained in:
parent
6f5d4ce2e2
commit
43a1df6e5c
@ -121,7 +121,6 @@ namespace osu.Game.Screens.Play
|
|||||||
}
|
}
|
||||||
|
|
||||||
cts?.Cancel();
|
cts?.Cancel();
|
||||||
cts = new CancellationTokenSource();
|
|
||||||
|
|
||||||
LoadComponentAsync(newColumns, c =>
|
LoadComponentAsync(newColumns, c =>
|
||||||
{
|
{
|
||||||
@ -131,7 +130,7 @@ namespace osu.Game.Screens.Play
|
|||||||
recalculateValues();
|
recalculateValues();
|
||||||
redrawFilled();
|
redrawFilled();
|
||||||
redrawProgress();
|
redrawProgress();
|
||||||
}, cts.Token);
|
}, (cts = new CancellationTokenSource()).Token);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
Loading…
Reference in New Issue
Block a user