Free cookie consent management tool by TermsFeed Policy Generator

Changeset 3731


Ignore:
Timestamp:
05/10/10 03:53:55 (15 years ago)
Author:
swagner
Message:

Prevented drag operations of items which are null (#947)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Optimization.Views/3.3/RunView.cs

    r3638 r3731  
    167167        ListViewItem listViewItem = (ListViewItem)e.Item;
    168168        IItem item = (IItem)listViewItem.Tag;
    169         DataObject data = new DataObject();
    170         data.SetData("Type", item.GetType());
    171         data.SetData("Value", item);
    172         DragDropEffects result = DoDragDrop(data, DragDropEffects.Copy);
     169        if (item != null) {
     170          DataObject data = new DataObject();
     171          data.SetData("Type", item.GetType());
     172          data.SetData("Value", item);
     173          DragDropEffects result = DoDragDrop(data, DragDropEffects.Copy);
     174        }
    173175      }
    174176    }
Note: See TracChangeset for help on using the changeset viewer.