@@ -93,7 +93,7 @@ private async Task<bool> DownloadEvergreen()
9393 {
9494 WebClient wc = new WebClient ( ) ;
9595
96- wc . DownloadProgressChanged += ( a , b ) => { Progressbar . Value = b . ProgressPercentage ; } ;
96+ wc . DownloadProgressChanged += ( a , b ) => { VM . ProgressValue = b . ProgressPercentage ; } ;
9797 wc . DownloadFileCompleted += ( a , b ) =>
9898 {
9999 Install ( ) ;
@@ -111,23 +111,23 @@ private async Task<bool> DownloadEvergreen()
111111
112112 private async void Install ( )
113113 {
114- Progressbar . IsIndeterminate = true ;
114+ VM . IsIndeterminate = true ;
115115 VM . InfoMessage ( true , "Installing..." , "Please wait up to 2 minutes for the Evergreen WebView2 Runtime to install." , InfoBarSeverity . Informational ) ;
116116 bool InstallSuccessful = false ;
117117 await Task . Run ( async ( ) => { InstallSuccessful = await InstallTask ( ) ; } ) ;
118118 if ( InstallSuccessful )
119119 {
120120 VM . Default . EvergreenInstalled = true ;
121121 VM . InfoMessage ( true , "Success!" , "The editor and viewer controls are now fully operational." , InfoBarSeverity . Success ) ;
122- Progressbar . Visibility = Visibility . Collapsed ;
122+ VM . IsVisible = false ;
123123 await Task . Delay ( 2500 ) ;
124- Progressbar . IsIndeterminate = true ;
124+ VM . IsIndeterminate = true ;
125125 RootFrame . Navigate ( typeof ( MainPage ) ) ;
126126 }
127127 else
128128 {
129129 VM . InfoMessage ( true , "Error" , "Something went wrong. Please try again later." , InfoBarSeverity . Error ) ;
130- Progressbar . Visibility = Visibility . Collapsed ;
130+ VM . IsVisible = false ;
131131 }
132132 }
133133
@@ -169,7 +169,7 @@ private async void RootFrame_Loaded(object sender, RoutedEventArgs e)
169169
170170 if ( VM . Default . EvergreenInstalled )
171171 {
172- Progressbar . IsIndeterminate = true ;
172+ VM . IsIndeterminate = true ;
173173 RootFrame . Navigate ( typeof ( MainPage ) ) ;
174174 }
175175 else
0 commit comments