void Download_ProgressDone(object sender, ReceivedDataEventArgs e) { if (!e.isCancel && e.fileName == verifyingKey) { veriStatus = true; } else if (!e.isCancel && e.fileName == provingKey) { provStatus = true; } if (veriStatus && provStatus) { checkParamsDone = true; if (start.isEnableAutoBackup()) { command += " -backupwallet"; } Task.Run(() => api.startWallet(command)); } if (e.isCancel) { startWallet.CancelAsync(); } }
protected void OnDownloadProgressDone(ReceivedDataEventArgs e) { if (downloadProgressDone != null) { downloadProgressDone(this, e); } }
protected void OnProgressDone(ReceivedDataEventArgs e) { if (progressDone != null) { progressDone(this, e); } }
void Download_ProgressChange(object sender, ReceivedDataEventArgs e) { switch (e.fileName) { case verifyingKey: pbProcess.Invoke(new Action(() => pbProcess.Value = e.progress * 100)); break; case provingKey: pbProving.Invoke(new Action(() => pbProving.Value = e.progress * 100)); break; case groth16Key: pbGroth.Invoke(new Action(() => pbGroth.Value = e.progress * 100)); break; case saplingSpend: pbSpend.Invoke(new Action(() => pbSpend.Value = e.progress * 100)); break; case saplingOutput: pbOutput.Invoke(new Action(() => pbOutput.Value = e.progress * 100)); break; } }
void NewVersion_ProgressDone(object sender, ReceivedDataEventArgs e) { if (e.isCancel == false) { try { isFinished = true; ProcessStartInfo startInfo = new ProcessStartInfo(); startInfo.CreateNoWindow = false; startInfo.UseShellExecute = true; startInfo.FileName = Path.GetTempPath() + "\\SimpleWallet.exe"; Process.Start(startInfo); } catch (Exception ex) { } this.Invoke(new Action(() => this.Close())); } }
void NewVersion_ProgressDone(object sender, ReceivedDataEventArgs e) { if (e.isCancel == false) { try { isFinished = true; ProcessStartInfo startInfo = new ProcessStartInfo(); startInfo.CreateNoWindow = false; startInfo.UseShellExecute = true; //startInfo.FileName = Path.GetTempPath() + "\\SimpleWallet_new.exe"; //MessageBox.Show(Path.GetTempPath() + "\\SimpleWallet_new.exe"); startInfo.FileName = System.IO.Path.GetDirectoryName(System.Windows.Forms.Application.ExecutablePath) + "\\SimpleWallet_new.exe"; MessageBox.Show(System.IO.Path.GetDirectoryName(System.Windows.Forms.Application.ExecutablePath) + "\\SimpleWallet_new.exe"); Process.Start(startInfo); } catch (Exception ex) { } this.Invoke(new Action(() => this.Close())); } }
void Download_ProgressChange(object sender, ReceivedDataEventArgs e) { pbProcess.Invoke(new Action(() => pbProcess.Value = e.progress * 100)); }
void NewVersion_ProgressChange(object sender, ReceivedDataEventArgs e) { pbDownloading.Invoke(new Action(() => pbDownloading.Value = e.progress * 100)); }