diff --git a/src/system/auto_update.rs b/src/system/auto_update.rs index 40ff3a2..44257b9 100644 --- a/src/system/auto_update.rs +++ b/src/system/auto_update.rs @@ -131,7 +131,7 @@ impl Update { new_version, cargo_crate_version!() ); - if new_version.as_str() > "cargo_crate_version!()" { + if new_version.as_str() > cargo_crate_version!() { Some(r) // New version is available } else { None // No new version diff --git a/src/ui/activities/auth/misc.rs b/src/ui/activities/auth/misc.rs index a18dd03..b1c62df 100644 --- a/src/ui/activities/auth/misc.rs +++ b/src/ui/activities/auth/misc.rs @@ -164,7 +164,9 @@ impl AuthActivity { // Umount release notes self.umount_release_notes(); // Mount wait box - self.mount_wait("Installing update. Please wait…"); + self.mount_wait("Installing update. Please wait…", Color::LightYellow); + // Refresh UI + self.view(); // Install update let result = Update::default().show_progress(false).upgrade(); // Umount wait diff --git a/src/ui/activities/auth/view.rs b/src/ui/activities/auth/view.rs index 91863df..d9bc988 100644 --- a/src/ui/activities/auth/view.rs +++ b/src/ui/activities/auth/view.rs @@ -579,10 +579,10 @@ impl AuthActivity { Box::new(Paragraph::new( ParagraphPropsBuilder::default() .with_borders(Borders::ALL, BorderType::Thick, color) + .with_foreground(color) .bold() .with_text_alignment(Alignment::Center) .with_texts(vec![TextSpan::from(text.as_ref().to_string())]) - .with_foreground(color) .build(), )), ); @@ -600,13 +600,14 @@ impl AuthActivity { /// ### mount_error /// /// Mount wait box - pub(super) fn mount_wait(&mut self, text: &str) { + pub(super) fn mount_wait(&mut self, text: &str, color: Color) { // Mount self.view.mount( super::COMPONENT_TEXT_WAIT, Box::new(Paragraph::new( ParagraphPropsBuilder::default() - .with_borders(Borders::ALL, BorderType::Thick, Color::Reset) + .with_borders(Borders::ALL, BorderType::Thick, color) + .with_foreground(color) .bold() .with_text_alignment(Alignment::Center) .with_texts(vec![TextSpan::from(text)])