feat(ui): small progress bar changes

This commit is contained in:
Observer KRypt0n_ 2023-04-13 20:12:05 +02:00
parent c6f1371e0d
commit fb0b8d4f8c
No known key found for this signature in database
GPG key ID: 844DA47BA25FE1E2

View file

@ -132,30 +132,20 @@ impl SimpleAsyncComponent for ProgressBar {
ProgressBarMsg::UpdateFromState(state) => { ProgressBarMsg::UpdateFromState(state) => {
match state { match state {
DiffUpdate::InstallerUpdate(InstallerUpdate::CheckingFreeSpace(_)) => self.caption = Some(tr("checking-free-space")), DiffUpdate::InstallerUpdate(InstallerUpdate::CheckingFreeSpace(_)) => self.caption = Some(tr("checking-free-space")),
DiffUpdate::InstallerUpdate(InstallerUpdate::DownloadingStarted(_)) => self.caption = Some(tr("downloading")),
DiffUpdate::InstallerUpdate(InstallerUpdate::DownloadingStarted(_)) => { DiffUpdate::InstallerUpdate(InstallerUpdate::UnpackingStarted(_)) => self.caption = Some(tr("unpacking")),
self.caption = Some(tr("downloading"));
self.display_fraction = true;
}
DiffUpdate::InstallerUpdate(InstallerUpdate::UnpackingStarted(_)) => {
self.caption = Some(tr("unpacking"));
self.display_fraction = true;
}
DiffUpdate::ApplyingHdiffStarted => { DiffUpdate::ApplyingHdiffStarted => {
self.caption = Some(tr("applying-hdiff")); self.caption = Some(tr("applying-hdiff"));
self.display_fraction = false; self.display_fraction = false;
} },
DiffUpdate::RemovingOutdatedStarted => { DiffUpdate::RemovingOutdatedStarted => {
self.caption = Some(tr("removing-outdated")); self.caption = Some(tr("removing-outdated"));
self.display_fraction = false; self.display_fraction = false;
} },
DiffUpdate::InstallerUpdate(InstallerUpdate::DownloadingProgress(curr, total)) | DiffUpdate::InstallerUpdate(InstallerUpdate::DownloadingProgress(curr, total)) |
DiffUpdate::InstallerUpdate(InstallerUpdate::UnpackingProgress(curr, total)) | DiffUpdate::InstallerUpdate(InstallerUpdate::UnpackingProgress(curr, total)) |