Free cookie consent management tool by TermsFeed Policy Generator

Changeset 12656 for stable


Ignore:
Timestamp:
07/07/15 16:30:06 (9 years ago)
Author:
jkarder
Message:

#2416: merged r12615 and r12634 into stable

Location:
stable
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.Scripting.Views/3.3/VariableStoreView.cs

    r12610 r12656  
    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.