types.rs: add JobCanceled event

pull/234/head
Manos Pitsidianakis 4 years ago
parent 5a5408ecd5
commit ed3b2fa6c8
No known key found for this signature in database
GPG Key ID: 73627C2F690DF710

@ -1163,7 +1163,8 @@ impl Component for StatusBar {
self.status = format!("{} | {}", self.mode, std::mem::replace(s, String::new()));
self.dirty = true;
}
UIEvent::StatusEvent(StatusEvent::JobFinished(ref job_id)) => {
UIEvent::StatusEvent(StatusEvent::JobCanceled(ref job_id))
| UIEvent::StatusEvent(StatusEvent::JobFinished(ref job_id)) => {
self.in_progress_jobs.remove(job_id);
if self.in_progress_jobs.is_empty() {
self.progress_spinner.stop();

@ -55,6 +55,7 @@ pub enum StatusEvent {
UpdateStatus(String),
NewJob(JobId),
JobFinished(JobId),
JobCanceled(JobId),
}
/// `ThreadEvent` encapsulates all of the possible values we need to transfer between our threads

Loading…
Cancel
Save