Free cookie consent management tool by TermsFeed Policy Generator

Changeset 11067


Ignore:
Timestamp:
07/01/14 14:52:03 (10 years ago)
Author:
jkarder
Message:

#2195: set cursor to 'waiting' while loading samples

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Optimizer/3.3/StartPage.cs

    r11052 r11067  
    6565        using (Stream stream = assembly.GetManifestResourceStream(typeof(StartPage), "Documents.FirstSteps.rtf"))
    6666          firstStepsRichTextBox.LoadFile(stream, RichTextBoxStreamType.RichText);
    67       }
    68       catch (Exception) { }
     67      } catch (Exception) { }
    6968
    7069      samplesListView.Enabled = false;
     
    113112
    114113        OnAllSamplesLoaded();
    115       }
    116       finally {
     114      } finally {
    117115        MainFormManager.GetMainForm<HeuristicLab.MainForm.WindowsForms.MainForm>().RemoveOperationProgressFromView(samplesListView);
    118116      }
     
    126124          OnSampleLoaded(item, group, 1.0 / count);
    127125        }
    128       }
    129       catch (Exception) { }
     126      } catch (Exception) { }
    130127    }
    131128
     
    173170
    174171    private void samplesListView_DoubleClick(object sender, EventArgs e) {
    175       if (samplesListView.SelectedItems.Count == 1)
    176         MainFormManager.MainForm.ShowContent((IContent)((IItem)samplesListView.SelectedItems[0].Tag).Clone());
     172      if (samplesListView.SelectedItems.Count == 1) {
     173        var mainForm = MainFormManager.GetMainForm<MainForm.WindowsForms.MainForm>();
     174        try {
     175          mainForm.SetWaitCursor();
     176          mainForm.ShowContent((IContent)((IItem)samplesListView.SelectedItems[0].Tag).Clone());
     177        } finally {
     178          mainForm.ResetWaitCursor();
     179        }
     180
     181      }
    177182    }
    178183    private void samplesListView_ItemDrag(object sender, ItemDragEventArgs e) {
Note: See TracChangeset for help on using the changeset viewer.