- Timestamp:
- 04/16/13 13:13:41 (11 years ago)
- Location:
- branches/OaaS
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/OaaS
- Property svn:ignore
-
old new 21 21 protoc.exe 22 22 _ReSharper.HeuristicLab 3.3 Tests 23 Google.ProtocolBuffers-2.4.1.473.dll 23 24 packages
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/OaaS/HeuristicLab.Core.Views/3.3/CheckedItemListView.cs
r7259 r9363 20 20 #endregion 21 21 22 using System; 23 using System.Drawing; 22 24 using System.Linq; 23 using System.Drawing;24 25 using System.Windows.Forms; 25 26 using HeuristicLab.Collections; … … 51 52 Content.CheckedItemsChanged -= new CollectionItemsChangedEventHandler<IndexedItem<T>>(Content_CheckedItemsChanged); 52 53 base.DeregisterContentEvents(); 54 } 55 56 protected override void OnContentChanged() { 57 base.OnContentChanged(); 58 if (Content != null) { 59 SetNumberOfCheckItems(); 60 } 53 61 } 54 62 … … 133 141 itemsListView.Items[item.Index].Checked = Content.ItemChecked(item.Value); 134 142 } 143 SetNumberOfCheckItems(); 135 144 } 136 145 } 146 protected override void Content_CollectionReset(object sender, CollectionItemsChangedEventArgs<IndexedItem<T>> e) { 147 base.Content_CollectionReset(sender, e); 148 SetNumberOfCheckItems(); 149 } 150 protected override void Content_ItemsAdded(object sender, CollectionItemsChangedEventArgs<IndexedItem<T>> e) { 151 base.Content_ItemsAdded(sender, e); 152 SetNumberOfCheckItems(); 153 } 154 protected override void Content_ItemsMoved(object sender, CollectionItemsChangedEventArgs<IndexedItem<T>> e) { 155 base.Content_ItemsMoved(sender, e); 156 SetNumberOfCheckItems(); 157 } 158 protected override void Content_ItemsRemoved(object sender, CollectionItemsChangedEventArgs<IndexedItem<T>> e) { 159 base.Content_ItemsRemoved(sender, e); 160 SetNumberOfCheckItems(); 161 } 162 protected override void Content_ItemsReplaced(object sender, CollectionItemsChangedEventArgs<IndexedItem<T>> e) { 163 base.Content_ItemsReplaced(sender, e); 164 SetNumberOfCheckItems(); 165 } 137 166 #endregion 167 168 private void SetNumberOfCheckItems() { 169 if (InvokeRequired) { 170 Invoke((Action)SetNumberOfCheckItems); 171 } else { 172 this.itemsGroupBox.Text = String.Format("Items (Checked: {0}/{1})", Content.CheckedItems.Count(), Content.Count); 173 } 174 } 138 175 } 139 176 }
Note: See TracChangeset
for help on using the changeset viewer.