@@ -24,25 +24,23 @@ impl UltraLogApp {
2424 . default_width ( 420.0 )
2525 . anchor ( egui:: Align2 :: CENTER_CENTER , [ 0.0 , 0.0 ] )
2626 . order ( egui:: Order :: Foreground )
27- . show ( ctx, |ui| {
28- match & self . update_state {
29- UpdateState :: UpdateAvailable ( info) => {
30- let info_clone = info. clone ( ) ;
31- self . render_update_available ( ui, info_clone, & mut should_close) ;
32- }
33- UpdateState :: Downloading => {
34- self . render_downloading ( ui) ;
35- }
36- UpdateState :: ReadyToInstall ( path) => {
37- let path_clone = path. clone ( ) ;
38- self . render_ready_to_install ( ui, & path_clone, & mut should_close) ;
39- }
40- UpdateState :: Error ( e) => {
41- let error = e. clone ( ) ;
42- self . render_update_error ( ui, & error, & mut should_close) ;
43- }
44- _ => { }
27+ . show ( ctx, |ui| match & self . update_state {
28+ UpdateState :: UpdateAvailable ( info) => {
29+ let info_clone = info. clone ( ) ;
30+ self . render_update_available ( ui, info_clone, & mut should_close) ;
31+ }
32+ UpdateState :: Downloading => {
33+ self . render_downloading ( ui) ;
4534 }
35+ UpdateState :: ReadyToInstall ( path) => {
36+ let path_clone = path. clone ( ) ;
37+ self . render_ready_to_install ( ui, & path_clone, & mut should_close) ;
38+ }
39+ UpdateState :: Error ( e) => {
40+ let error = e. clone ( ) ;
41+ self . render_update_error ( ui, & error, & mut should_close) ;
42+ }
43+ _ => { }
4644 } ) ;
4745
4846 if !open || should_close {
@@ -63,7 +61,11 @@ impl UltraLogApp {
6361 ui. vertical_centered ( |ui| {
6462 ui. add_space ( 10.0 ) ;
6563
66- ui. label ( egui:: RichText :: new ( "A new version is available!" ) . size ( 18.0 ) . strong ( ) ) ;
64+ ui. label (
65+ egui:: RichText :: new ( "A new version is available!" )
66+ . size ( 18.0 )
67+ . strong ( ) ,
68+ ) ;
6769
6870 ui. add_space ( 15.0 ) ;
6971
@@ -189,7 +191,9 @@ impl UltraLogApp {
189191 if let Err ( e) = crate :: updater:: install_update ( path) {
190192 self . show_toast_error ( & e) ;
191193 } else {
192- self . show_toast_success ( "Update file opened. Follow the installer instructions." ) ;
194+ self . show_toast_success (
195+ "Update file opened. Follow the installer instructions." ,
196+ ) ;
193197 * should_close = true ;
194198 self . update_state = UpdateState :: Idle ;
195199 }
0 commit comments