Changeset 5068
- Timestamp:
- 12/07/10 16:46:54 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Core.Views/3.3/ItemCollectionView.cs
r5057 r5068 55 55 Content.ItemsRemoved -= new CollectionItemsChangedEventHandler<T>(Content_ItemsRemoved); 56 56 Content.CollectionReset -= new CollectionItemsChangedEventHandler<T>(Content_CollectionReset); 57 foreach (T item in listViewItemMapping.Keys) { 58 item.ItemImageChanged -= new EventHandler(Item_ItemImageChanged); 59 item.ToStringChanged -= new EventHandler(Item_ToStringChanged); 60 } 57 61 base.DeregisterContentEvents(); 58 62 } … … 126 130 T item = (listViewItem.Tag as T); 127 131 itemsListView.Items.Add(listViewItem); 128 i tem.ItemImageChanged += new EventHandler(Item_ItemImageChanged);129 item.ToStringChanged += new EventHandler(Item_ToStringChanged);130 if (!listViewItemMapping.ContainsKey(item))132 if (!listViewItemMapping.ContainsKey(item)) { 133 item.ItemImageChanged += new EventHandler(Item_ItemImageChanged); 134 item.ToStringChanged += new EventHandler(Item_ToStringChanged); 131 135 listViewItemMapping.Add(item, new List<ListViewItem>()); 136 } 132 137 listViewItemMapping[item].Add(listViewItem); 133 138 sortAscendingButton.Enabled = itemsListView.Items.Count > 1;
Note: See TracChangeset
for help on using the changeset viewer.