674 references to NotifyCollectionChangedAction
Microsoft.Maui.Controls (151)
BindableLayout\BindableLayout.cs (1)
509 if (e.Action == NotifyCollectionChangedAction.Replace)
Element\Element.cs (5)
851 case NotifyCollectionChangedAction.Add: 857 case NotifyCollectionChangedAction.Move: 859 case NotifyCollectionChangedAction.Remove: 865 case NotifyCollectionChangedAction.Replace: 875 case NotifyCollectionChangedAction.Reset:
FormattedString.cs (1)
88 base.OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, removed));
GestureElement.cs (5)
38 case NotifyCollectionChangedAction.Add: 41 case NotifyCollectionChangedAction.Remove: 44 case NotifyCollectionChangedAction.Replace: 48 case NotifyCollectionChangedAction.Reset: 74 base.OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, removed));
IndicatorView\IndicatorView.cs (1)
168 OnCollectionChanged(ItemsSource, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
Internals\NotifyCollectionChangedEventArgsEx.cs (11)
13 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action) : base(action) 19 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, IList changedItems) : base(action, changedItems) 25 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, IList newItems, IList oldItems) : base(action, newItems, oldItems) 31 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, IList newItems, IList oldItems, int startingIndex) : base(action, newItems, oldItems, startingIndex) 37 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, IList changedItems, int startingIndex) : base(action, changedItems, startingIndex) 43 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, IList changedItems, int index, int oldIndex) : base(action, changedItems, index, oldIndex) 49 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, object changedItem) : base(action, changedItem) 55 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, object changedItem, int index) : base(action, changedItem, index) 61 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, object changedItem, int index, int oldIndex) : base(action, changedItem, index, oldIndex) 67 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, object newItem, object oldItem) : base(action, newItem, oldItem) 73 public NotifyCollectionChangedEventArgsEx(int count, NotifyCollectionChangedAction action, object newItem, object oldItem, int index) : base(action, newItem, oldItem, index)
Internals\NotifyCollectionChangedEventArgsExtensions.cs (20)
25 public static NotifyCollectionChangedAction Apply(this NotifyCollectionChangedEventArgs self, Action<object, int, bool> insert, Action<object, int> removeAt, Action reset) 38 case NotifyCollectionChangedAction.Add: 40 goto case NotifyCollectionChangedAction.Reset; 47 case NotifyCollectionChangedAction.Move: 49 goto case NotifyCollectionChangedAction.Reset; 63 case NotifyCollectionChangedAction.Remove: 65 goto case NotifyCollectionChangedAction.Reset; 71 case NotifyCollectionChangedAction.Replace: 73 goto case NotifyCollectionChangedAction.Reset; 82 case NotifyCollectionChangedAction.Reset: 84 return NotifyCollectionChangedAction.Reset; 95 case NotifyCollectionChangedAction.Add: 96 return new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Add, e.NewItems, e.NewStartingIndex); 98 case NotifyCollectionChangedAction.Remove: 99 return new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Remove, e.OldItems, e.OldStartingIndex); 101 case NotifyCollectionChangedAction.Move: 102 return new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Move, e.OldItems, e.NewStartingIndex, e.OldStartingIndex); 104 case NotifyCollectionChangedAction.Replace: 105 return new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Replace, e.NewItems, e.OldItems, e.OldStartingIndex); 108 return new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Reset);
Items\MarshalingObservableCollection.cs (7)
42 : base(NotifyCollectionChangedAction.Reset) => Items = items; 54 if (args.Action == NotifyCollectionChangedAction.Reset) 72 case NotifyCollectionChangedAction.Add: 75 case NotifyCollectionChangedAction.Move: 78 case NotifyCollectionChangedAction.Remove: 81 case NotifyCollectionChangedAction.Replace: 84 case NotifyCollectionChangedAction.Reset:
Label\Label.cs (8)
319 case NotifyCollectionChangedAction.Add: 322 case NotifyCollectionChangedAction.Remove: 325 case NotifyCollectionChangedAction.Replace: 329 case NotifyCollectionChangedAction.Reset: 340 case NotifyCollectionChangedAction.Add: 343 case NotifyCollectionChangedAction.Remove: 346 case NotifyCollectionChangedAction.Replace: 350 case NotifyCollectionChangedAction.Reset:
LegacyLayouts\Layout.cs (2)
117 new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, InternalChildren)); 619 if (e.Action == NotifyCollectionChangedAction.Move)
ListProxy.cs (1)
162 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
MultiPage.cs (10)
225 case NotifyCollectionChangedAction.Add: 227 goto case NotifyCollectionChangedAction.Reset; 243 case NotifyCollectionChangedAction.Remove: 245 goto case NotifyCollectionChangedAction.Reset; 260 case NotifyCollectionChangedAction.Move: 262 goto case NotifyCollectionChangedAction.Reset; 300 case NotifyCollectionChangedAction.Replace: 302 goto case NotifyCollectionChangedAction.Reset; 318 case NotifyCollectionChangedAction.Reset: 361 OnPagesChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
ObservableList.cs (6)
25 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, items, index)); 41 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, items, originalIndex)); 66 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, items, newIndex, oldIndex)); 78 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, items, index)); 90 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, items)); 110 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, ritems, oldItems, startIndex));
ObservableWrapper.cs (15)
180 case NotifyCollectionChangedAction.Add: 182 goto case NotifyCollectionChangedAction.Reset; 189 handler(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, e.NewItems, outerIndex)); 191 case NotifyCollectionChangedAction.Move: 193 goto case NotifyCollectionChangedAction.Reset; 201 handler(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, e.NewItems, outerNewIndex, outerOldIndex)); 203 case NotifyCollectionChangedAction.Remove: 205 goto case NotifyCollectionChangedAction.Reset; 212 var args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, removedItem, outerRemovedIndex); 215 case NotifyCollectionChangedAction.Replace: 217 goto case NotifyCollectionChangedAction.Reset; 228 goto case NotifyCollectionChangedAction.Reset; 233 var replaceArgs = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, newReplaceItem, oldReplaceItem, index); 236 case NotifyCollectionChangedAction.Reset: 237 handler(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
Page\Page.cs (1)
98 InternalChildrenOnCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, InternalChildren));
Picker\Picker.cs (2)
294 case NotifyCollectionChangedAction.Add: 297 case NotifyCollectionChangedAction.Remove:
ResourceDictionary.cs (3)
101 case NotifyCollectionChangedAction.Add: 111 if (e.Action == NotifyCollectionChangedAction.Move) 116 if (e.Action == NotifyCollectionChangedAction.Reset)
Shell\ShellElementCollection.cs (1)
122 CollectionChanged?.Invoke(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, list));
TemplatedItemsList.cs (47)
729 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 800 case NotifyCollectionChangedAction.Add: 802 goto case NotifyCollectionChangedAction.Reset; 815 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, newItems, e.NewStartingIndex)); 819 case NotifyCollectionChangedAction.Remove: 821 goto case NotifyCollectionChangedAction.Reset; 839 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, oldItems, e.OldStartingIndex)); 843 case NotifyCollectionChangedAction.Replace: 845 goto case NotifyCollectionChangedAction.Reset; 865 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, newItems, oldItems, e.OldStartingIndex)); 869 case NotifyCollectionChangedAction.Move: 871 goto case NotifyCollectionChangedAction.Reset; 912 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, oldItems, e.OldStartingIndex, e.NewStartingIndex)); 916 case NotifyCollectionChangedAction.Reset: 962 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 970 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 1008 case NotifyCollectionChangedAction.Add: 1017 e = new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Add, items, e.NewStartingIndex); 1021 goto case NotifyCollectionChangedAction.Reset; 1026 case NotifyCollectionChangedAction.Move: 1028 goto case NotifyCollectionChangedAction.Reset; 1055 e = new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Move, itemsToMove, e.NewStartingIndex, e.OldStartingIndex); 1058 case NotifyCollectionChangedAction.Remove: 1077 e = new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Remove, items, e.OldStartingIndex); 1081 goto case NotifyCollectionChangedAction.Reset; 1085 case NotifyCollectionChangedAction.Replace: 1096 e = new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Replace, newItems, oldItems, e.NewStartingIndex); 1100 goto case NotifyCollectionChangedAction.Reset; 1105 case NotifyCollectionChangedAction.Reset: 1106 e = new NotifyCollectionChangedEventArgsEx(count, NotifyCollectionChangedAction.Reset); 1167 case NotifyCollectionChangedAction.Add: 1172 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, e.NewItems[i], e.NewStartingIndex + i)); 1176 case NotifyCollectionChangedAction.Remove: 1181 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, e.OldItems[i], e.OldStartingIndex + i)); 1185 case NotifyCollectionChangedAction.Replace: 1190 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, e.NewItems[i], e.OldItems[i], e.OldStartingIndex + i)); 1195 OnProxyCollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 1320 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, list.ShortName, old, index)); 1343 case NotifyCollectionChangedAction.Add: 1344 e = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, ConvertItems(e.NewItems), e.NewStartingIndex); 1347 case NotifyCollectionChangedAction.Move: 1348 e = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, ConvertItems(e.OldItems), e.NewStartingIndex, e.OldStartingIndex); 1351 case NotifyCollectionChangedAction.Remove: 1352 e = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, ConvertItems(e.OldItems), e.OldStartingIndex); 1355 case NotifyCollectionChangedAction.Replace: 1356 e = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, ConvertItems(e.NewItems), ConvertItems(e.OldItems), e.OldStartingIndex); 1374 OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
View\View.cs (4)
123 case NotifyCollectionChangedAction.Add: 126 case NotifyCollectionChangedAction.Remove: 129 case NotifyCollectionChangedAction.Replace: 133 case NotifyCollectionChangedAction.Reset:
Microsoft.VisualStudio.LanguageServices (2)
ValueTracking\TreeViewItemBase.cs (2)
110if (args.Action is not NotifyCollectionChangedAction.Add and not NotifyCollectionChangedAction.Remove)
netstandard (1)
netstandard.cs (1)
163[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
PresentationCore (17)
System\Windows\FreezableCollection.cs (13)
163OnCollectionChanged(NotifyCollectionChangedAction.Reset, 0, null, 0, null); 207OnCollectionChanged(NotifyCollectionChangedAction.Add, 0, null, index, value); 242OnCollectionChanged(NotifyCollectionChangedAction.Remove, index, oldValue, 0, null); 266OnCollectionChanged(NotifyCollectionChangedAction.Remove, index, oldValue, 0, null); 332OnCollectionChanged(NotifyCollectionChangedAction.Replace, index, oldValue, index, value); 686OnCollectionChanged(NotifyCollectionChangedAction.Add, 0, null, index-1, value); 712private void OnCollectionChanged(NotifyCollectionChangedAction action, 727if (action != NotifyCollectionChangedAction.Replace && 728action != NotifyCollectionChangedAction.Move) 741case NotifyCollectionChangedAction.Reset: 744case NotifyCollectionChangedAction.Add: 747case NotifyCollectionChangedAction.Remove: 750case NotifyCollectionChangedAction.Replace:
System\Windows\Ink\StrokeCollection.cs (4)
642args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset); 647args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, e.Removed, e.Index); 652args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, e.Added, e.Index); 657args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, e.Added, e.Removed, e.Index);
PresentationFramework (385)
MS\Internal\Annotations\AnnotationObservableCollection.cs (2)
161OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 189OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
MS\Internal\Annotations\AnnotationResourceCollection.cs (1)
110OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, item, 0));
MS\Internal\Annotations\XmlElementCollection.cs (1)
239OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
MS\Internal\Controls\InnerItemCollectionView.cs (5)
155OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, value, originalItem, index)); 216OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item, indexV)); 288OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item, index)); 559OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 686OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, item, index));
MS\Internal\Data\CollectionViewGroupRoot.cs (5)
145OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item, globalIndex)); 164OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, item, globalIndex)); 493OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item, index)); 644OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, item, newIndex, oldIndex)); 752OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, item, leafIndex));
MS\Internal\Data\CompositeCollectionView.cs (27)
355OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 391case NotifyCollectionChangedAction.Add: 392case NotifyCollectionChangedAction.Remove: 397if (args.Action == NotifyCollectionChangedAction.Add) 426if (args.Action == NotifyCollectionChangedAction.Add) 432else if (args.Action == NotifyCollectionChangedAction.Remove) 443if (args.Action == NotifyCollectionChangedAction.Add) 451Debug.Assert(args.Action == NotifyCollectionChangedAction.Remove); 458if (args.Action == NotifyCollectionChangedAction.Add) 466Invariant.Assert(args.Action == NotifyCollectionChangedAction.Remove); 480args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset); 485case NotifyCollectionChangedAction.Replace: 527args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset); 532case NotifyCollectionChangedAction.Move: 603args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset); 609case NotifyCollectionChangedAction.Reset: 726case NotifyCollectionChangedAction.Add: 738case NotifyCollectionChangedAction.Remove: 750case NotifyCollectionChangedAction.Replace: 758case NotifyCollectionChangedAction.Move: 775case NotifyCollectionChangedAction.Reset: 1422private void TraceContainerCollectionChange(object sender, NotifyCollectionChangedAction action, object oldItem, object newItem) 1432case NotifyCollectionChangedAction.Add: 1437case NotifyCollectionChangedAction.Remove: 1442case NotifyCollectionChangedAction.Replace: 1447case NotifyCollectionChangedAction.Move: 1454case NotifyCollectionChangedAction.Reset:
MS\Internal\Data\DifferencingCollection.cs (1)
236OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
MS\Internal\Data\EnumerableCollectionView.cs (6)
401case NotifyCollectionChangedAction.Add: 418case NotifyCollectionChangedAction.Remove: 431case NotifyCollectionChangedAction.Replace: 441case NotifyCollectionChangedAction.Move: 476case NotifyCollectionChangedAction.Reset: 511OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
MS\Internal\Data\LiveShapingTree.cs (1)
69RaiseMoveEvent(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move,
MS\Internal\Navigation\JournalEntryStack.cs (1)
24CollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
System\Windows\Annotations\Annotation.cs (15)
703case NotifyCollectionChangedAction.Add: 708case NotifyCollectionChangedAction.Remove: 713case NotifyCollectionChangedAction.Replace: 724case NotifyCollectionChangedAction.Move: 728case NotifyCollectionChangedAction.Reset: 757case NotifyCollectionChangedAction.Add: 762case NotifyCollectionChangedAction.Remove: 767case NotifyCollectionChangedAction.Replace: 778case NotifyCollectionChangedAction.Move: 782case NotifyCollectionChangedAction.Reset: 806case NotifyCollectionChangedAction.Add: 811case NotifyCollectionChangedAction.Remove: 816case NotifyCollectionChangedAction.Replace: 827case NotifyCollectionChangedAction.Move: 831case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\DataGrid.cs (32)
226case NotifyCollectionChangedAction.Add: 231case NotifyCollectionChangedAction.Remove: 235case NotifyCollectionChangedAction.Replace: 241case NotifyCollectionChangedAction.Reset: 256visibleColumnsChanged |= (e.Action == NotifyCollectionChangedAction.Reset); 266if (visibleColumnsChanged && e.Action != NotifyCollectionChangedAction.Move) 652internal void UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction action, int oldDisplayIndex, DataGridColumn oldColumn, int newDisplayIndex) 947case NotifyCollectionChangedAction.Add: 955case NotifyCollectionChangedAction.Remove: 963case NotifyCollectionChangedAction.Replace: 976case NotifyCollectionChangedAction.Reset: 4112internal void OnSelectedCellsChanged(NotifyCollectionChangedAction action, VirtualizedCellInfoCollection oldItems, VirtualizedCellInfoCollection newItems) 4175(action == NotifyCollectionChangedAction.Add) && // An item was added 4182else if ((action == NotifyCollectionChangedAction.Remove) && 5334if (e.Action == NotifyCollectionChangedAction.Reset) 5344if (e.Action == NotifyCollectionChangedAction.Remove || e.Action == NotifyCollectionChangedAction.Replace) 5351else if (e.Action == NotifyCollectionChangedAction.Reset) 7243case NotifyCollectionChangedAction.Add: 7254case NotifyCollectionChangedAction.Remove: 7271case NotifyCollectionChangedAction.Move: 7274case NotifyCollectionChangedAction.Replace: 7278case NotifyCollectionChangedAction.Reset: 7388case NotifyCollectionChangedAction.Add: 7396case NotifyCollectionChangedAction.Remove: 7404case NotifyCollectionChangedAction.Move: 7407case NotifyCollectionChangedAction.Replace: 7416case NotifyCollectionChangedAction.Reset: 7646if (e.Action == NotifyCollectionChangedAction.Add) 7654else if ((e.Action == NotifyCollectionChangedAction.Remove) || (e.Action == NotifyCollectionChangedAction.Replace)) 7669else if (e.Action == NotifyCollectionChangedAction.Reset)
System\Windows\Controls\DataGridCellsPanel.cs (4)
2039case NotifyCollectionChangedAction.Remove: 2043case NotifyCollectionChangedAction.Replace: 2047case NotifyCollectionChangedAction.Move: 2051case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\DataGridColumnCollection.cs (11)
87case NotifyCollectionChangedAction.Add: 96case NotifyCollectionChangedAction.Move: 104case NotifyCollectionChangedAction.Remove: 114case NotifyCollectionChangedAction.Replace: 124case NotifyCollectionChangedAction.Reset: 130DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Reset, -1, null, -1); 386DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Move, oldDisplayIndex, null, newDisplayIndex); 398DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Move, oldColumnIndex, null, newColumnIndex); 443DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Add, -1, null, newDisplayIndex); 582DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Remove, removedDisplayIndex, (DataGridColumn)oldColumns[0], -1); 611DataGridOwner.UpdateColumnsOnVirtualizedCellInfoCollections(NotifyCollectionChangedAction.Replace, newDisplayIndex, oldColumn, newDisplayIndex);
System\Windows\Controls\DataGridColumnHeaderCollection.cs (6)
49NotifyCollectionChangedAction.Replace, 209case NotifyCollectionChangedAction.Add: 213case NotifyCollectionChangedAction.Remove: 217case NotifyCollectionChangedAction.Move: 221case NotifyCollectionChangedAction.Replace: 226newArgs = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset);
System\Windows\Controls\GridViewColumnCollection.cs (5)
264return new GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, _columns[actualIndex], newIndex, oldIndex, actualIndex); 287return new GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset, list); 308return new GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, column, index, actualIndex); 392return new GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, column, index, count /* actual index*/); 412return new GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, newColumn, oldColumn, index, oldColumnActualIndex);
System\Windows\Controls\GridViewColumnCollectionChangedEventArgs.cs (7)
21: base(NotifyCollectionChangedAction.Reset) // NotifyCollectionChangedEventArgs doesn't have 0 parameter constructor, so pass in an arbitrary parameter. 32internal GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction action, GridViewColumn[] clearedColumns) 41internal GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction action, GridViewColumn changedItem, int index, int actualIndex) 44Debug.Assert(action == NotifyCollectionChangedAction.Add || action == NotifyCollectionChangedAction.Remove, 56internal GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction action, GridViewColumn newItem, GridViewColumn oldItem, int index, int actualIndex) 70internal GridViewColumnCollectionChangedEventArgs(NotifyCollectionChangedAction action, GridViewColumn changedItem, int index, int oldIndex, int actualIndex)
System\Windows\Controls\GridViewHeaderRowPresenter.cs (5)
693case NotifyCollectionChangedAction.Move: 703case NotifyCollectionChangedAction.Add: 711case NotifyCollectionChangedAction.Remove: 716case NotifyCollectionChangedAction.Replace: 725case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\GridViewRowPresenter.cs (5)
363if (e.Action == NotifyCollectionChangedAction.Move) 371case NotifyCollectionChangedAction.Add: 377case NotifyCollectionChangedAction.Remove: 381case NotifyCollectionChangedAction.Replace: 386case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\ItemCollection.cs (12)
447OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 1708OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 1958OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 2170case NotifyCollectionChangedAction.Add: 2173goto case NotifyCollectionChangedAction.Reset; 2179case NotifyCollectionChangedAction.Remove: 2181goto case NotifyCollectionChangedAction.Reset; 2189case NotifyCollectionChangedAction.Replace: 2192goto case NotifyCollectionChangedAction.Reset; 2199case NotifyCollectionChangedAction.Move: 2202goto case NotifyCollectionChangedAction.Reset; 2224case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\ItemContainerGenerator.cs (13)
2070ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Add, position, 1, 0)); 2090ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Remove, position, 1, 1)); 2385if (sender != ItemsInternal && args.Action != NotifyCollectionChangedAction.Reset) 2390case NotifyCollectionChangedAction.Add: 2396case NotifyCollectionChangedAction.Remove: 2402case NotifyCollectionChangedAction.Replace: 2412case NotifyCollectionChangedAction.Move: 2422case NotifyCollectionChangedAction.Reset: 2515ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Add, position, 1, 0)); 2560ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Remove, position, 1, containerCount)); 2619ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Replace, position, 1, 1)); 2730ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Move, position, oldPosition, 1, containerCount)); 2771ItemsChanged(this, new ItemsChangedEventArgs(NotifyCollectionChangedAction.Reset, position, 0, 0));
System\Windows\Controls\ItemsControl.cs (6)
302if (e.Action == NotifyCollectionChangedAction.Reset) 3686case NotifyCollectionChangedAction.Add: 3698case NotifyCollectionChangedAction.Remove: 3714case NotifyCollectionChangedAction.Move: 3745case NotifyCollectionChangedAction.Replace: 3749case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\MultipleCopiesCollection.cs (11)
48case NotifyCollectionChangedAction.Add: 55case NotifyCollectionChangedAction.Move: 62case NotifyCollectionChangedAction.Remove: 69case NotifyCollectionChangedAction.Replace: 76case NotifyCollectionChangedAction.Reset: 178OnCollectionChanged(NotifyCollectionChangedAction.Add, CopiedItem, index); 193OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, CopiedItem, newIndex, oldIndex)); 201OnCollectionChanged(NotifyCollectionChangedAction.Remove, CopiedItem, index); 215OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, newItem, oldItem, index)); 421private void OnCollectionChanged(NotifyCollectionChangedAction action, object item, int index) 431OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
System\Windows\Controls\Panel.cs (5)
688case NotifyCollectionChangedAction.Add: 691case NotifyCollectionChangedAction.Remove: 694case NotifyCollectionChangedAction.Replace: 697case NotifyCollectionChangedAction.Move: 701case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\Primitives\DataGridCellsPresenter.cs (1)
346e.Action != NotifyCollectionChangedAction.Reset || columns.Count == 0,
System\Windows\Controls\Primitives\GridViewRowPresenterBase.cs (3)
147if (e.Action == NotifyCollectionChangedAction.Remove 148|| e.Action == NotifyCollectionChangedAction.Replace) 164else if (e.Action == NotifyCollectionChangedAction.Reset)
System\Windows\Controls\Primitives\ItemsChangedEventArgs.cs (4)
27internal ItemsChangedEventArgs(NotifyCollectionChangedAction action, 40internal ItemsChangedEventArgs(NotifyCollectionChangedAction action, 55public NotifyCollectionChangedAction Action { get { return _action; } } 76private NotifyCollectionChangedAction _action;
System\Windows\Controls\Primitives\Selector.cs (12)
871case NotifyCollectionChangedAction.Add: 878case NotifyCollectionChangedAction.Remove: 885case NotifyCollectionChangedAction.Reset: 900case NotifyCollectionChangedAction.Replace: 908case NotifyCollectionChangedAction.Move: 1103if (e.Action == NotifyCollectionChangedAction.Reset || 1104(e.Action == NotifyCollectionChangedAction.Add && 1140case NotifyCollectionChangedAction.Add: 1159case NotifyCollectionChangedAction.Replace: 1171case NotifyCollectionChangedAction.Remove: 1177case NotifyCollectionChangedAction.Move: 1191case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\Primitives\ToolBarPanel.cs (5)
380case NotifyCollectionChangedAction.Add: 383case NotifyCollectionChangedAction.Remove: 386case NotifyCollectionChangedAction.Replace: 389case NotifyCollectionChangedAction.Move: 393case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\SelectedCellsCollection.cs (1)
69protected override void OnCollectionChanged(NotifyCollectionChangedAction action, VirtualizedCellInfoCollection oldItems, VirtualizedCellInfoCollection newItems)
System\Windows\Controls\TabControl.cs (1)
379if (e.Action == NotifyCollectionChangedAction.Remove && SelectedIndex == -1)
System\Windows\Controls\TreeView.cs (5)
414case NotifyCollectionChangedAction.Remove: 415case NotifyCollectionChangedAction.Reset: 422case NotifyCollectionChangedAction.Replace: 434case NotifyCollectionChangedAction.Add: 435case NotifyCollectionChangedAction.Move:
System\Windows\Controls\TreeViewItem.cs (5)
944case NotifyCollectionChangedAction.Remove: 945case NotifyCollectionChangedAction.Reset: 957case NotifyCollectionChangedAction.Replace: 974case NotifyCollectionChangedAction.Add: 975case NotifyCollectionChangedAction.Move:
System\Windows\Controls\VirtualizedCellInfoCollection.cs (14)
429OnCollectionChanged(NotifyCollectionChangedAction.Add, null, newItems); 437OnCollectionChanged(NotifyCollectionChangedAction.Remove, oldItems, null); 443protected virtual void OnCollectionChanged(NotifyCollectionChangedAction action, VirtualizedCellInfoCollection oldItems, VirtualizedCellInfoCollection newItems) 949case NotifyCollectionChangedAction.Add: 953case NotifyCollectionChangedAction.Remove: 957case NotifyCollectionChangedAction.Replace: 961case NotifyCollectionChangedAction.Move: 965case NotifyCollectionChangedAction.Reset: 1116internal void OnColumnsChanged(NotifyCollectionChangedAction action, int oldDisplayIndex, DataGridColumn oldColumn, int newDisplayIndex, IList selectedRows) 1122case NotifyCollectionChangedAction.Add: 1126case NotifyCollectionChangedAction.Remove: 1130case NotifyCollectionChangedAction.Replace: 1134case NotifyCollectionChangedAction.Move: 1138case NotifyCollectionChangedAction.Reset:
System\Windows\Controls\VirtualizingPanel.cs (4)
511case NotifyCollectionChangedAction.Add: 512case NotifyCollectionChangedAction.Remove: 513case NotifyCollectionChangedAction.Replace: 514case NotifyCollectionChangedAction.Move:
System\Windows\Controls\VirtualizingStackPanel.cs (10)
3573case NotifyCollectionChangedAction.Remove: 3578case NotifyCollectionChangedAction.Replace: 3583case NotifyCollectionChangedAction.Move: 3587case NotifyCollectionChangedAction.Reset: 3637case NotifyCollectionChangedAction.Remove: 3646case NotifyCollectionChangedAction.Replace: 3652case NotifyCollectionChangedAction.Add: 3661case NotifyCollectionChangedAction.Move: 3695Debug.Assert(args.Action == NotifyCollectionChangedAction.Reset && args.ItemCount == 1); 3744ItemsChangedEventArgs newArgs = new ItemsChangedEventArgs(NotifyCollectionChangedAction.Reset,
System\Windows\Data\BindingGroup.cs (5)
1302case NotifyCollectionChangedAction.Add: 1306case NotifyCollectionChangedAction.Remove: 1310case NotifyCollectionChangedAction.Move: 1312case NotifyCollectionChangedAction.Replace: 1318case NotifyCollectionChangedAction.Reset:
System\Windows\Data\BindingListCollectionView.cs (28)
452NotifyCollectionChangedAction.Remove, 459NotifyCollectionChangedAction.Remove, 472NotifyCollectionChangedAction.Add, 482NotifyCollectionChangedAction.Move, 496NotifyCollectionChangedAction.Add, 504NotifyCollectionChangedAction.Move, 636NotifyCollectionChangedAction.Add, 785result = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, newItem, toIndex, fromIndex); 1385OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 1498case NotifyCollectionChangedAction.Add: 1514case NotifyCollectionChangedAction.Remove: 1524case NotifyCollectionChangedAction.Replace: 1537case NotifyCollectionChangedAction.Move: 1549case NotifyCollectionChangedAction.Reset: 1811case NotifyCollectionChangedAction.Add: 1814case NotifyCollectionChangedAction.Remove: 1817case NotifyCollectionChangedAction.Replace: 1820case NotifyCollectionChangedAction.Move: 1915forwardedArgs = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item, index + delta); 1956forwardedArgs = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, item, index + delta); 1973forwardedArgs = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, item, index+delta, args.OldIndex+delta); 2294if (e.Action == NotifyCollectionChangedAction.Add) 2298else if (e.Action == NotifyCollectionChangedAction.Remove) 2432case NotifyCollectionChangedAction.Add: 2437case NotifyCollectionChangedAction.Remove: 2442case NotifyCollectionChangedAction.Replace: 2447case NotifyCollectionChangedAction.Move: 2454case NotifyCollectionChangedAction.Reset:
System\Windows\Data\CollectionContainer.cs (1)
365OnContainedCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
System\Windows\Data\CollectionView.cs (14)
868OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 919if (args.Action != NotifyCollectionChangedAction.Replace && 920args.Action != NotifyCollectionChangedAction.Move) 1080case NotifyCollectionChangedAction.Add: 1088case NotifyCollectionChangedAction.Remove: 1096case NotifyCollectionChangedAction.Replace: 1104case NotifyCollectionChangedAction.Move: 1112case NotifyCollectionChangedAction.Reset: 1886if (args.Action == NotifyCollectionChangedAction.Reset) 1950case NotifyCollectionChangedAction.Add: 1955case NotifyCollectionChangedAction.Remove: 1962case NotifyCollectionChangedAction.Replace: 1967case NotifyCollectionChangedAction.Move: 1974case NotifyCollectionChangedAction.Reset:
System\Windows\Data\CompositeCollection.cs (8)
116OnCollectionChanged(NotifyCollectionChangedAction.Add, newItem, addedIndex); 137OnCollectionChanged(NotifyCollectionChangedAction.Reset); 193OnCollectionChanged(NotifyCollectionChangedAction.Add, insertItem, insertIndex); 238OnCollectionChanged(NotifyCollectionChangedAction.Remove, removedItem, removeIndex); 320OnCollectionChanged(NotifyCollectionChangedAction.Replace, originalItem, value, itemIndex); 495private void OnCollectionChanged(NotifyCollectionChangedAction action) 508private void OnCollectionChanged(NotifyCollectionChangedAction action, object item, int index) 517private void OnCollectionChanged(NotifyCollectionChangedAction action, object oldItem, object newItem, int index)
System\Windows\Data\ListCollectionView.cs (67)
155OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 565NotifyCollectionChangedAction.Remove, 572NotifyCollectionChangedAction.Remove, 585NotifyCollectionChangedAction.Add, 595NotifyCollectionChangedAction.Move, 609NotifyCollectionChangedAction.Add, 617NotifyCollectionChangedAction.Move, 811NotifyCollectionChangedAction.Add, 860int toIndex = AdjustBefore(NotifyCollectionChangedAction.Add, newItem, _newItemIndex); 867NotifyCollectionChangedAction.Remove, 890NotifyCollectionChangedAction.Move, 929NotifyCollectionChangedAction.Add, 959int index = AdjustBefore(NotifyCollectionChangedAction.Remove, _newItem, _newItemIndex); 964NotifyCollectionChangedAction.Remove, 1122NotifyCollectionChangedAction.Remove, 1227NotifyCollectionChangedAction.Remove, 1257NotifyCollectionChangedAction.Move, 1267toIndex = AdjustBefore(NotifyCollectionChangedAction.Add, editItem, SourceList.IndexOf(editItem)); 1270NotifyCollectionChangedAction.Add, 1666case NotifyCollectionChangedAction.Reset: 1667case NotifyCollectionChangedAction.Add: 1668case NotifyCollectionChangedAction.Replace: 1680if (args.Action != NotifyCollectionChangedAction.Reset) 1682if (args.Action != NotifyCollectionChangedAction.Remove && args.NewStartingIndex < 0 1683|| args.Action != NotifyCollectionChangedAction.Add && args.OldStartingIndex < 0) 1696if (args.Action == NotifyCollectionChangedAction.Reset) 1719if (args.Action == NotifyCollectionChangedAction.Add && _newItemIndex == -2) 1728if (args.Action != NotifyCollectionChangedAction.Remove) 1730adjustedNewIndex = AdjustBefore(NotifyCollectionChangedAction.Add, args.NewItems[0], args.NewStartingIndex); 1735if (args.Action != NotifyCollectionChangedAction.Add) 1737adjustedOldIndex = AdjustBefore(NotifyCollectionChangedAction.Remove, args.OldItems[0], args.OldStartingIndex); 1750case NotifyCollectionChangedAction.Add: 1757case NotifyCollectionChangedAction.Remove: 1776case NotifyCollectionChangedAction.Move: 1809NotifyCollectionChangedAction effectiveAction = args.Action; 1812effectiveAction = NotifyCollectionChangedAction.Replace; 1821if (args.Action != NotifyCollectionChangedAction.Add) 1823effectiveAction = NotifyCollectionChangedAction.Remove; 1832effectiveAction = NotifyCollectionChangedAction.Add; 1834else if (effectiveAction == NotifyCollectionChangedAction.Move) 1848effectiveAction = NotifyCollectionChangedAction.Remove; 1852effectiveAction = NotifyCollectionChangedAction.Move; 1879case NotifyCollectionChangedAction.Add: 1913case NotifyCollectionChangedAction.Remove: 1950case NotifyCollectionChangedAction.Replace: 1982case NotifyCollectionChangedAction.Move: 2040args2 = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, args.NewItems, adjustedNewIndex); 2041args = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, args.OldItems, adjustedOldIndex); 2367case NotifyCollectionChangedAction.Add: 2377case NotifyCollectionChangedAction.Remove: 2387case NotifyCollectionChangedAction.Replace: 2400case NotifyCollectionChangedAction.Move: 2499case NotifyCollectionChangedAction.Add: 2504case NotifyCollectionChangedAction.Remove: 2509case NotifyCollectionChangedAction.Replace: 2514case NotifyCollectionChangedAction.Move: 2521case NotifyCollectionChangedAction.Reset: 2636private int AdjustBefore (NotifyCollectionChangedAction action, object item, int index) 2639if (action == NotifyCollectionChangedAction.Reset) 2671if (action == NotifyCollectionChangedAction.Add) 2702if (action == NotifyCollectionChangedAction.Add) 2726else if (action == NotifyCollectionChangedAction.Remove) 2987if (e.Action == NotifyCollectionChangedAction.Add) 2991else if (e.Action == NotifyCollectionChangedAction.Remove) 3112new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Move, 3151new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove, 3191new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add,
System\Windows\Documents\DocumentReferenceCollection.cs (2)
67OnCollectionChanged(NotifyCollectionChangedAction.Add, item, count); 157private void OnCollectionChanged(NotifyCollectionChangedAction action, object item, int index)
System\Windows\Documents\DocumentSequence.cs (1)
713if (args.Action == NotifyCollectionChangedAction.Add)
System\Windows\Documents\DocumentSequenceTextContainer.cs (1)
591if (args.Action == NotifyCollectionChangedAction.Add)
System\Windows\Navigation\JournalEntryListConverter.cs (1)
180CollectionChanged(this, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
System\Windows\ResourceDictionary.cs (5)
1890if (e.Action != NotifyCollectionChangedAction.Reset) 1902if (e.Action == NotifyCollectionChangedAction.Remove 1903|| e.Action == NotifyCollectionChangedAction.Replace) 1920if (e.Action == NotifyCollectionChangedAction.Add 1921|| e.Action == NotifyCollectionChangedAction.Replace)
System (1)
src\libraries\shims\System\ref\System.cs (1)
152[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
System.ObjectModel (38)
System\Collections\ObjectModel\ObservableCollection.cs (8)
112OnCollectionChanged(NotifyCollectionChangedAction.Remove, removedItem, index); 126OnCollectionChanged(NotifyCollectionChangedAction.Add, item, index); 140OnCollectionChanged(NotifyCollectionChangedAction.Replace, originalItem, item, index); 157OnCollectionChanged(NotifyCollectionChangedAction.Move, removedItem, newIndex, oldIndex); 250private void OnCollectionChanged(NotifyCollectionChangedAction action, object? item, int index) 258private void OnCollectionChanged(NotifyCollectionChangedAction action, object? item, int index, int oldIndex) 266private void OnCollectionChanged(NotifyCollectionChangedAction action, object? oldItem, object? newItem, int index) 319internal static readonly NotifyCollectionChangedEventArgs ResetCollectionChanged = new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset);
System\Collections\Specialized\NotifyCollectionChangedEventArgs.cs (30)
16private readonly NotifyCollectionChangedAction _action; 26public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action) 28if (action != NotifyCollectionChangedAction.Reset) 30throw new ArgumentException(SR.Format(SR.WrongActionForCtor, NotifyCollectionChangedAction.Reset), nameof(action)); 41public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, object? changedItem) : 52public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, object? changedItem, int index) 56case NotifyCollectionChangedAction.Reset: 67case NotifyCollectionChangedAction.Add: 72case NotifyCollectionChangedAction.Remove: 89public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, IList? changedItems) : 100public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, IList? changedItems, int startingIndex) 104case NotifyCollectionChangedAction.Reset: 115case NotifyCollectionChangedAction.Add: 116case NotifyCollectionChangedAction.Remove: 120if (action == NotifyCollectionChangedAction.Add) 145public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, object? newItem, object? oldItem) : 157public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, object? newItem, object? oldItem, int index) 159if (action != NotifyCollectionChangedAction.Replace) 161throw new ArgumentException(SR.Format(SR.WrongActionForCtor, NotifyCollectionChangedAction.Replace), nameof(action)); 176public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, IList newItems, IList oldItems) : 188public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, IList newItems, IList oldItems, int startingIndex) 190if (action != NotifyCollectionChangedAction.Replace) 192throw new ArgumentException(SR.Format(SR.WrongActionForCtor, NotifyCollectionChangedAction.Replace), nameof(action)); 210public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, object? changedItem, int index, int oldIndex) 212if (action != NotifyCollectionChangedAction.Move) 214throw new ArgumentException(SR.Format(SR.WrongActionForCtor, NotifyCollectionChangedAction.Move), nameof(action)); 231public NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction action, IList? changedItems, int index, int oldIndex) 233if (action != NotifyCollectionChangedAction.Move) 235throw new ArgumentException(SR.Format(SR.WrongActionForCtor, NotifyCollectionChangedAction.Move), nameof(action)); 248public NotifyCollectionChangedAction Action => _action;
System.Windows (1)
System.Windows.cs (1)
7[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
System.Windows.Controls.Ribbon (22)
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonQuickAccessToolBarPanel.cs (5)
32case NotifyCollectionChangedAction.Add: 44case NotifyCollectionChangedAction.Remove: 47case NotifyCollectionChangedAction.Reset: 57case NotifyCollectionChangedAction.Move: 62case NotifyCollectionChangedAction.Replace:
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (5)
1082if (e.Action == NotifyCollectionChangedAction.Remove || 1083e.Action == NotifyCollectionChangedAction.Replace || 1084e.Action == NotifyCollectionChangedAction.Reset) 1090e.Action == NotifyCollectionChangedAction.Move || 1091e.Action == NotifyCollectionChangedAction.Remove)
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (5)
2405case NotifyCollectionChangedAction.Remove: 2406case NotifyCollectionChangedAction.Reset: 2407case NotifyCollectionChangedAction.Replace: 2420case NotifyCollectionChangedAction.Add: 2421case NotifyCollectionChangedAction.Move:
Microsoft\Windows\Controls\Ribbon\RibbonGalleryCategory.cs (5)
539case NotifyCollectionChangedAction.Remove: 540case NotifyCollectionChangedAction.Replace: 568case NotifyCollectionChangedAction.Reset: 586case NotifyCollectionChangedAction.Add: 589case NotifyCollectionChangedAction.Move:
Microsoft\Windows\Controls\Ribbon\RibbonTab.cs (2)
320case NotifyCollectionChangedAction.Reset: 326case NotifyCollectionChangedAction.Remove:
WindowsBase (1)
WindowsBase.cs (1)
7[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
WindowsBase.Tests (55)
System\Collections\Specialized\CollectionChangedEventManagerTests.cs (34)
13yield return new object?[] { new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset) }; 112source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 116source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 123source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 127source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 134source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 138source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 145source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 149source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 184yield return new object?[] { new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset) }; 294source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 298source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 305source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 309source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 316source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 320source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 327source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 331source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 363source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 368source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 399source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 401source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 406source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 408source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 428source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 434source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 462source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 467source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 487source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 489source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 494source1.OnCollectionChanged(source1, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 496source2.OnCollectionChanged(source2, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 522source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset)); 528source.OnCollectionChanged(source, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
System\ComponentModel\CurrentChangedEventManagerTests.cs (1)
197yield return new object?[] { new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset) };
System\ComponentModel\SortDescriptionCollectionTests.cs (20)
90Assert.Equal(NotifyCollectionChangedAction.Remove, events[0].Action); 95Assert.Equal(NotifyCollectionChangedAction.Add, events[1].Action); 176Assert.Equal(NotifyCollectionChangedAction.Add, events[0].Action); 190Assert.Equal(NotifyCollectionChangedAction.Add, events[1].Action); 255Assert.Equal(NotifyCollectionChangedAction.Add, events[0].Action); 269Assert.Equal(NotifyCollectionChangedAction.Add, events[1].Action); 344Assert.Equal(NotifyCollectionChangedAction.Add, events[0].Action); 358Assert.Equal(NotifyCollectionChangedAction.Add, events[1].Action); 424Assert.Equal(NotifyCollectionChangedAction.Reset, events[0].Action); 437Assert.Equal(NotifyCollectionChangedAction.Reset, events[2].Action); 447Assert.Equal(NotifyCollectionChangedAction.Reset, events[3].Action); 496Assert.Equal(NotifyCollectionChangedAction.Reset, events[0].Action); 509Assert.Equal(NotifyCollectionChangedAction.Reset, events[2].Action); 519Assert.Equal(NotifyCollectionChangedAction.Reset, events[3].Action); 582Assert.Equal(NotifyCollectionChangedAction.Remove, events[0].Action); 594Assert.Equal(NotifyCollectionChangedAction.Remove, events[1].Action); 668Assert.Equal(NotifyCollectionChangedAction.Remove, events[0].Action); 680Assert.Equal(NotifyCollectionChangedAction.Remove, events[1].Action); 746Assert.Equal(NotifyCollectionChangedAction.Remove, events[0].Action); 751Assert.Equal(NotifyCollectionChangedAction.Add, events[1].Action);