1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-27 10:53:09 +08:00

cancel handle

This commit is contained in:
cdwcgt 2023-02-26 15:28:10 +09:00
parent a20e2685be
commit fdf9544688

View File

@ -137,6 +137,12 @@ namespace osu.Game.Database
});
}, cancellationToken).ContinueWith(t =>
{
if (cancellationToken.IsCancellationRequested)
{
notify.State = ProgressNotificationState.Cancelled;
return false;
}
if (t.IsFaulted)
{
notify.State = ProgressNotificationState.Cancelled;
@ -144,10 +150,8 @@ namespace osu.Game.Database
return false;
}
notify.CompletionText = "Export Complete, Click to open the folder";
notify.State = ProgressNotificationState.Completed;
return true;
}, cancellationToken);
}, CancellationToken.None);
}
/// <summary>