- Timestamp:
- 11/16/17 10:30:21 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/EnhancedProgress/HeuristicLab.Clients.OKB.Views/3.3/RunCreation/Views/OKBExperimentUploadView.cs
r15446 r15477 188 188 if (InvokeRequired) { Invoke((Action<object, EventArgs>)RunCreationClient_Refreshing, sender, e); return; } 189 189 var message = "Refreshing algorithms and problems..."; 190 MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().AddOperationProgressToView(this, message);190 Progress.ShowMarquee(this, message); 191 191 refreshing = true; 192 192 SetEnabledStateOfControls(); … … 195 195 private void RunCreationClient_Refreshed(object sender, EventArgs e) { 196 196 if (InvokeRequired) { Invoke((Action<object, EventArgs>)RunCreationClient_Refreshed, sender, e); return; } 197 MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().RemoveOperationProgressFromView(this);197 Progress.Hide(this); 198 198 refreshing = false; 199 199 SetEnabledStateOfControls(); … … 203 203 var task = System.Threading.Tasks.Task.Factory.StartNew(UploadAsync); 204 204 task.ContinueWith((t) => { 205 MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().RemoveOperationProgressFromView(this);205 Progress.Hide(this); 206 206 PluginInfrastructure.ErrorHandling.ShowErrorDialog("An exception occured while uploading the runs to the OKB.", t.Exception); 207 207 }, TaskContinuationOptions.OnlyOnFaulted); … … 210 210 private void UploadAsync() { 211 211 var message = "Uploading runs to OKB..."; 212 IProgress progress = MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().AddOperationProgressToView(this, message, 0);212 IProgress progress = Progress.Show(this, message); 213 213 double count = dataGridView.Rows.Count; 214 214 int i = 0; … … 226 226 progress.ProgressValue = ((double)i) / count; 227 227 } 228 MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().RemoveOperationProgressFromView(this);228 Progress.Hide(this); 229 229 ClearRuns(); 230 230 }
Note: See TracChangeset
for help on using the changeset viewer.