Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/08/15 15:32:12 (9 years ago)
Author:
dglaser
Message:

#2388: Merged trunk into HiveStatistics branch

Location:
branches/HiveStatistics/sources
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/HiveStatistics/sources

  • branches/HiveStatistics/sources/HeuristicLab.Scripting.Views/3.3/VariableStoreView.cs

    r12182 r12689  
    368368
    369369    protected virtual void Content_CollectionReset(object sender, CollectionItemsChangedEventArgs<KeyValuePair<string, object>> e) {
    370       if (InvokeRequired)
    371         Invoke(new CollectionItemsChangedEventHandler<KeyValuePair<string, object>>(Content_CollectionReset), sender, e);
     370      if (InvokeRequired) Invoke((Action<object, CollectionItemsChangedEventArgs<KeyValuePair<string, object>>>)Content_CollectionReset, sender, e);
    372371      else {
    373372        foreach (var item in e.OldItems)
     
    380379
    381380    private void item_ToStringChanged(object sender, EventArgs e) {
    382       foreach (ListViewItem item in variableListView.Items) {
    383         var variable = item.Tag as KeyValuePair<string, object>?;
    384         if (variable == null || variable.Value.Value != sender) continue;
    385 
    386         string value = (variable.Value.Value ?? "null").ToString();
    387         item.SubItems[1].Text = value;
    388         item.SubItems[2].Text = variable.Value.Value.GetType().ToString();
    389         SetToolTipText(item, item.ImageIndex != 0);
     381      if (InvokeRequired) Invoke((Action<object, EventArgs>)item_ToStringChanged, sender, e);
     382      else {
     383        foreach (ListViewItem item in variableListView.Items) {
     384          var variable = item.Tag as KeyValuePair<string, object>?;
     385          if (variable == null || variable.Value.Value != sender) continue;
     386
     387          string value = (variable.Value.Value ?? "null").ToString();
     388          item.SubItems[1].Text = value;
     389          item.SubItems[2].Text = variable.Value.Value.GetType().ToString();
     390          SetToolTipText(item, item.ImageIndex != 0);
     391        }
    390392      }
    391393    }
Note: See TracChangeset for help on using the changeset viewer.