mirror of
https://github.com/ppy/osu.git
synced 2025-02-27 21:12:56 +08:00
cancel handle
This commit is contained in:
parent
a20e2685be
commit
fdf9544688
@ -137,6 +137,12 @@ namespace osu.Game.Database
|
|||||||
});
|
});
|
||||||
}, cancellationToken).ContinueWith(t =>
|
}, cancellationToken).ContinueWith(t =>
|
||||||
{
|
{
|
||||||
|
if (cancellationToken.IsCancellationRequested)
|
||||||
|
{
|
||||||
|
notify.State = ProgressNotificationState.Cancelled;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (t.IsFaulted)
|
if (t.IsFaulted)
|
||||||
{
|
{
|
||||||
notify.State = ProgressNotificationState.Cancelled;
|
notify.State = ProgressNotificationState.Cancelled;
|
||||||
@ -144,10 +150,8 @@ namespace osu.Game.Database
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
notify.CompletionText = "Export Complete, Click to open the folder";
|
|
||||||
notify.State = ProgressNotificationState.Completed;
|
|
||||||
return true;
|
return true;
|
||||||
}, cancellationToken);
|
}, CancellationToken.None);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
Loading…
Reference in New Issue
Block a user