8 writes to Items
System.Windows.Forms.Tests (4)
System\Windows\Forms\AccessibleObjects\ListBoxAccessibleObjectTests.cs (1)
347
using ListBox listBox = new() { Parent = form,
Items
= { "Item 1", "Item 2" } };
System\Windows\Forms\ListBoxTests.cs (3)
6291
Items
= { "Item1", "Item2", "Item3" }
6357
Items
= { "Item 1", "Item 2", "Item 3" }
6381
Items
= { "Item 1", "Item 2", "Item 3" }
System.Windows.Forms.UI.IntegrationTests (4)
ListBoxAccesibleObjectTests.cs (2)
36
using ListBox listBox = new() { Parent = form,
Items
= { "Item 1", "Item 2" } };
50
using ListBox listBox = new() { Parent = form,
Items
= { "Item 1", "Item 2" } };
ListBoxItemAccessibleObjestTests.cs (2)
38
using ListBox listBoxDoubleClick = new() {
Items
= { "Item 1" }, Parent = formDoubleClick };
44
using ListBox listBoxNullAction = new ListBox {
Items
= { "Item 2" } };
1023 references to Items
Accessibility_Core_App (1)
CommonControl1.Designer.cs (1)
576
this.listBox1.
Items
.AddRange(new object[] {
DesignSurface (1)
MainForm.cs (1)
205
lb1.
Items
.AddRange(new string[] { "a1", "b2", "c3" });
PresentationUI (13)
MS\Internal\Documents\CredentialManagerDialog.cs (3)
75
_credListBox.SelectedIndex = _credListBox.
Items
.IndexOf(defaultAccount);
113
(string) _credListBox.
Items
[_credListBox.SelectedIndex]);
128
(string)_credListBox.
Items
[_credListBox.SelectedIndex]);
MS\Internal\Documents\SignatureSummaryDialog.cs (10)
311
_listBoxSummary.
Items
.Add(signatureResources);
322
if (_showRequestDialog && _listBoxSummary.
Items
.Count > 0)
352
(SignatureResources)_listBoxSummary.
Items
[_listBoxSummary.SelectedIndex],
378
(SignatureResources)_listBoxSummary.
Items
[_listBoxSummary.SelectedIndex],
411
_listBoxSummary.
Items
[_listBoxSummary.SelectedIndex]
444
_listBoxSummary.
Items
.Clear();
477
if (_documentSignatureManager.HasCertificate((SignatureResources)_listBoxSummary.
Items
[_listBoxSummary.SelectedIndex]))
524
(SignatureResources)_listBoxSummary.
Items
[e.Index]
590
if (e.Index > -1 && e.Index < _listBoxSummary.
Items
.Count)
593
SignatureResources item = (SignatureResources)_listBoxSummary.
Items
[e.Index];
System.Windows.Forms (49)
System\Windows\Forms\Controls\ListBoxes\CheckedListBox.cs (1)
171
return (ObjectCollection)base.
Items
;
System\Windows\Forms\Controls\ListBoxes\ListBox.AccessibleObject.cs (6)
80
int childCount = this.TryGetOwnerAs(out ListBox? owner) ? owner.
Items
.Count : 0;
148
IReadOnlyList<ItemArray.Entry?> entries = owner.
Items
.InnerArray.Entries;
193
if (index < 0 || index >= owner.
Items
.Count || owner.
Items
.InnerArray.Count == 0)
198
ItemArray.Entry? item = owner.
Items
.InnerArray.Entries[index];
216
return this.TryGetOwnerAs(out ListBox? owner) ? owner.
Items
.Count : 0;
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (24)
22
[DefaultProperty(nameof(
Items
))]
635
if (
Items
.Count == _itemsCount)
640
_itemsCount =
Items
.Count;
844
return
Items
.IndexOfIdentifier(SelectedItems.GetObjectAt(0));
1086
int cnt =
Items
.Count;
1089
if (string.Compare(value, GetItemText(
Items
[index]), true, CultureInfo.CurrentCulture) == 0)
1183
Items
.AddRangeInternal(value);
1272
ArgumentOutOfRangeException.ThrowIfGreaterThanOrEqual(index,
Items
.Count);
1300
string?[] strings = new string[
Items
.Count];
1302
for (int i = 0; i <
Items
.Count; i++)
1304
strings[i] = GetItemText(
Items
[i]);
1657
int cnt =
Items
.Count;
1883
AccessibilityObject?.GetChild(
Items
.Count - 1)?.RaiseAutomationEvent(UIA_EVENT_ID.UIA_AutomationFocusChangedEventId);
1922
Items
.ClearInternal();
1952
int cnt =
Items
.Count;
2003
Items
.AddRangeInternal(newItems);
2036
Items
.SetItemInternal(index,
Items
[index]);
2101
Items
.ClearInternal();
2102
Items
.AddRangeInternal(value);
2135
Items
.SetItemInternal(index, value);
2213
s += $", Items.Count: {
Items
.Count}";
2214
if (
Items
.Count > 0)
2216
string? z = GetItemText(
Items
[0]);
System\Windows\Forms\Controls\ListBoxes\ListBox.ItemAccessibleObject.cs (3)
28
protected int CurrentIndex => _owningListBox.
Items
.InnerArray.IndexOf(_itemEntry);
132
int lastItemIndex = _owningListBox.
Items
.Count - 1;
220
int itemsCount = _owningListBox.
Items
.Count;
System\Windows\Forms\Controls\ListBoxes\ListBox.ObjectCollection.cs (1)
244
int cnt = _owner.
Items
.Count;
System\Windows\Forms\Controls\ListBoxes\ListBox.SelectedIndexCollection.cs (3)
167
return _owner.
Items
.InnerArray;
189
ObjectCollection items = _owner.
Items
;
204
ObjectCollection items = _owner.
Items
;
System\Windows\Forms\Controls\ListBoxes\ListBox.SelectedObjectCollection.cs (4)
114
return _owner.
Items
.InnerArray;
233
bool selected = _owner.
Items
.InnerArray.GetState(index, SelectedObjectMask);
259
ObjectCollection items = _owner.
Items
;
275
ObjectCollection items = _owner.
Items
;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (5)
2260
if (DropDownListBox.
Items
.Count == 0)
2290
string text = (string)DropDownListBox.
Items
[e.Index];
3680
DropDownListBox.
Items
.Clear();
3705
DropDownListBox.
Items
.Add(value);
3727
bool resizable = DropDownListBox.
Items
.Count > (DropDownListBox.Height / DropDownListBox.ItemHeight);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.DropDownHolder.cs (1)
589
if (listBox.
Items
.Count == 0)
System\Windows\Forms\MDI\MDIWindowDialog.cs (1)
49
int n = _itemList.
Items
.Add(new ListItem(all[i]));
System.Windows.Forms.Design (116)
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (36)
141
_listBox.
Items
.Add(created);
153
UpdateItemWidths(_listBox.
Items
[^1] as ListItem);
164
_listBox.SelectedIndex = _listBox.
Items
.Count - 1;
166
object[] items = new object[_listBox.
Items
.Count];
169
items[i] = ((ListItem)_listBox.
Items
[i]).Value;
176
if (_listBox.
Items
.Count > 0 && _listBox.SelectedIndex != _listBox.
Items
.Count - 1)
179
_listBox.SelectedIndex = _listBox.
Items
.Count - 1;
211
int c = Math.Max(2, _listBox.
Items
.Count);
245
_listBox.
Items
.Clear();
321
if (index == _listBox.
Items
.Count - 1)
327
(_listBox.
Items
[index + 1], _listBox.
Items
[index]) = (_listBox.
Items
[index], _listBox.
Items
[index + 1]);
329
if (ti < _listBox.
Items
.Count - 1)
537
foreach (ListItem i in _listBox.
Items
)
557
ListItem item = (ListItem)_listBox.
Items
[e.Index];
561
int c = _listBox.
Items
.Count;
677
object[] items = new object[_listBox.
Items
.Count];
680
items[i] = ((ListItem)_listBox.
Items
[i]).Value;
701
_listBox.
Items
.Clear();
747
_listBox.
Items
.Clear();
757
_listBox.
Items
.Add(new ListItem(_editor, items[i]));
761
if (_listBox.
Items
.Count > 0)
821
if (index < _listBox.
Items
.Count)
825
else if (_listBox.
Items
.Count > 0)
827
_listBox.SelectedIndex = _listBox.
Items
.Count - 1;
882
_listBox.
Items
.Remove(item);
893
_listBox.
Items
.Remove(item);
996
(_listBox.
Items
[index - 1], _listBox.
Items
[index]) = (_listBox.
Items
[index], _listBox.
Items
[index - 1]);
1033
_upButton.Enabled = editEnabled && _listBox.
Items
.Count > 1;
1034
_downButton.Enabled = editEnabled && _listBox.
Items
.Count > 1;
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.cs (3)
67
listBox.
Items
.Add(newItem);
87
if (listBox.
Items
.Count > 0)
89
foreach (string s in listBox.
Items
)
System\Drawing\Design\ColorEditor.ColorUI.cs (5)
208
_lbCommon.
Items
.Clear();
211
_lbCommon.
Items
.Add(color);
214
_lbSystem.
Items
.Clear();
217
_lbSystem.
Items
.Add(color);
258
Color value = (Color)lb.
Items
[die.Index];
System\Drawing\Design\CursorEditor.CursorUI.cs (4)
37
Items
.Add(obj);
63
Cursor cursor = (Cursor)
Items
[e.Index];
96
for (int i = 0; i <
Items
.Count; i++)
98
if (
Items
[i] == value)
System\Windows\Forms\Design\DataGridViewAddColumnDialog.cs (5)
179
bool dataGridViewIsDataBound = _dataColumns.
Items
.Count > 0;
708
_dataColumns.
Items
.Clear();
738
_dataColumns.
Items
.Add(new ListBoxItem(propertyDescriptor.PropertyType, propertyDescriptor.Name));
743
_dataColumns.SelectedIndex = selectedIndex != -1 && selectedIndex < _dataColumns.
Items
.Count
745
: _dataColumns.
Items
.Count > 0 ? 0 : -1;
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (36)
143
_selectedColumns.
Items
.RemoveAt(selectedIndex);
144
_selectedColumns.
Items
.Insert(selectedIndex, new ListBoxItem(newColumn!, this, newColumnDesigner));
288
if (e.Component is ListBoxItem && _selectedColumns.
Items
.Contains(e.Component))
663
Debug.Assert(selectedIndex > -1 && selectedIndex < _selectedColumns.
Items
.Count - 1);
669
_selectedColumns.
Items
.RemoveAt(selectedIndex);
670
_selectedColumns.
Items
.Insert(selectedIndex + 1, item);
703
_moveDown.Enabled = _selectedColumns.SelectedIndex < _selectedColumns.
Items
.Count - 1;
714
ListBoxItem item = (ListBoxItem)_selectedColumns.
Items
[selectedIndex - 1];
715
_selectedColumns.
Items
.RemoveAt(selectedIndex - 1);
716
_selectedColumns.
Items
.Insert(selectedIndex, item);
747
_moveDown.Enabled = _selectedColumns.SelectedIndex < _selectedColumns.
Items
.Count - 1;
761
for (int i = 0; i < _selectedColumns.
Items
.Count; i++)
763
ListBoxItem? lbi = _selectedColumns.
Items
[i] as ListBoxItem;
805
_selectedColumns.SelectedIndex = Math.Min(0, _selectedColumns.
Items
.Count - 1);
808
_moveDown.Enabled = _selectedColumns.SelectedIndex < _selectedColumns.
Items
.Count - 1;
809
_deleteButton.Enabled = _selectedColumns.
Items
.Count > 0 && _selectedColumns.SelectedIndex != -1;
834
_selectedColumns.SelectedIndex = Math.Min(_selectedColumns.
Items
.Count - 1, selectedIndex);
837
_moveDown.Enabled = _selectedColumns.SelectedIndex < _selectedColumns.
Items
.Count - 1;
838
_deleteButton.Enabled = _selectedColumns.
Items
.Count > 0 && _selectedColumns.SelectedIndex != -1;
844
int insertIndex = _selectedColumns.SelectedIndex == -1 ? _selectedColumns.
Items
.Count : _selectedColumns.SelectedIndex + 1;
863
for (int i = 0; i < _selectedColumns.
Items
.Count; i++)
865
ListBoxItem? lbi = _selectedColumns.
Items
[i] as ListBoxItem;
872
_selectedColumns.
Items
.Clear();
878
_selectedColumns.
Items
.Add(new ListBoxItem(_columnsPrivateCopy[i], this, columnDesigner));
881
_selectedColumns.SelectedIndex = Math.Min(selectedIndex, _selectedColumns.
Items
.Count - 1);
885
if (_selectedColumns.
Items
.Count == 0)
910
_selectedColumns.
Items
[selectedIndex] = _selectedColumns.
Items
[selectedIndex];
954
ListBoxItem? listBoxItem = _selectedColumns.
Items
[e.Index] as ListBoxItem;
999
string columnName = ((ListBoxItem)_selectedColumns.
Items
[e.Index]).ToString();
1066
_moveDown.Enabled = _selectedColumns.
Items
.Count > 0 && _selectedColumns.SelectedIndex != _selectedColumns.
Items
.Count - 1;
1067
_moveUp.Enabled = _selectedColumns.
Items
.Count > 0 && _selectedColumns.SelectedIndex > 0;
1068
_deleteButton.Enabled = _selectedColumns.
Items
.Count > 0 && _selectedColumns.SelectedIndex != -1;
1158
for (int i = 0; i < _selectedColumns.
Items
.Count; i++)
1160
int itemWidth = TextRenderer.MeasureText(_selectedColumns.
Items
[i].ToString(), _selectedColumns.Font).Width;
System\Windows\Forms\Design\DataGridViewColumnTypeEditor.Picker.cs (6)
47
for (int i = 0; i < _typesListBox.
Items
.Count; i++)
49
ListBoxItem item = (ListBoxItem)_typesListBox.
Items
[i];
81
_typesListBox.
Items
.Clear();
108
_typesListBox.
Items
.Add(new ListBoxItem(t));
127
for (int i = 0; i < _typesListBox.
Items
.Count; i++)
129
if (type == ((ListBoxItem)_typesListBox.
Items
[i]).ColumnType)
System\Windows\Forms\Design\FormatControl.cs (19)
48
for (int i = 0; i < formatTypeListBox.
Items
.Count; i++)
50
var formatType = (FormatTypeClass)formatTypeListBox.
Items
[i];
328
dateTimeFormatsListBox.
Items
.Clear();
329
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "d"));
330
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "D"));
331
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "f"));
332
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "F"));
333
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "g"));
334
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "G"));
335
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "t"));
336
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "T"));
337
dateTimeFormatsListBox.
Items
.Add(new DateTimeFormatsListBoxItem(s_dateTimeFormatValue, "M"));
389
formatTypeListBox.
Items
.Clear();
390
formatTypeListBox.
Items
.Add(new NoFormattingFormatType());
391
formatTypeListBox.
Items
.Add(new NumericFormatType(this));
392
formatTypeListBox.
Items
.Add(new CurrencyFormatType(this));
393
formatTypeListBox.
Items
.Add(new DateTimeFormatType(this));
394
formatTypeListBox.
Items
.Add(new ScientificFormatType(this));
395
formatTypeListBox.
Items
.Add(new CustomFormatType(this));
System\Windows\Forms\Design\ListBoxDesigner.cs (2)
155
&& e.Member.Name == nameof(ListBox.
Items
)
184
if (listBox.IsHandleCreated && listBox.
Items
.Count == 0)
System.Windows.Forms.Tests (829)
System\Windows\Forms\AccessibleObjects\ListBox.ListBoxItemAccessibleObjectTests.cs (7)
52
listBox.
Items
.Add(item: "testItem");
75
listBox.
Items
.Add(item: "testItem");
91
listBox.
Items
.Add(item: "testItem");
108
listBox.
Items
.Add(item: "testItem");
124
listBox.
Items
.Add(item: "testItem");
155
listBox.
Items
.Add(item: "testItem");
169
listBox.
Items
.Add("Item 1");
System\Windows\Forms\AccessibleObjects\ListBoxAccessibleObjectTests.cs (10)
114
listBox.
Items
.Clear();
124
ItemArray.Entry item = listBox.
Items
.InnerArray.Entries[0];
127
listBox.
Items
.Remove(item);
148
listBox.
Items
.Add(item: "testItem");
153
listBox.
Items
.Clear();
222
listBox.
Items
.AddRange((object[])
257
listBox.
Items
.AddRange(new[] { "Item 1", "Item 2" });
282
listBox.
Items
.Add($"Item {i + 1}");
294
listBox.
Items
.AddRange(new[] { "Item 1", "Item 2" });
315
listBox.
Items
.AddRange(new[] { "Item 1", "Item 2", "Item 3" });
System\Windows\Forms\ControlTests.cs (1)
1050
listBox1.
Items
.AddRange((object[])["Foo", "Foo", "Foo"]);
System\Windows\Forms\ListBox.ObjectCollectionTests.cs (546)
17
Assert.Empty(owner.
Items
);
28
Assert.Empty(owner.
Items
);
41
Assert.Empty(owner.
Items
);
68
Assert.Empty(owner.
Items
);
170
Assert.Empty(owner.
Items
);
177
Assert.Empty(owner.
Items
);
184
Assert.Empty(owner.
Items
);
191
Assert.Empty(owner.
Items
);
211
Assert.Empty(owner.
Items
);
218
Assert.Empty(owner.
Items
);
225
Assert.Empty(owner.
Items
);
232
Assert.Empty(owner.
Items
);
241
ListBox.ObjectCollection collection = owner.
Items
;
249
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
256
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
263
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
270
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
282
ListBox.ObjectCollection collection = owner.
Items
;
290
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
297
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
304
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
311
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
497
ListBox.ObjectCollection collection = owner.
Items
;
513
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
530
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
547
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
564
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
586
ListBox.ObjectCollection collection = owner.
Items
;
602
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
619
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
636
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
653
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
672
ListBox.ObjectCollection collection = owner.
Items
;
721
ListBox.ObjectCollection collection = owner.
Items
;
772
ListBox.ObjectCollection collection = owner.
Items
;
842
ListBox.ObjectCollection collection = owner.
Items
;
906
ListBox.ObjectCollection collection = owner.
Items
;
979
ListBox.ObjectCollection collection = owner.
Items
;
1054
ListBox.ObjectCollection collection = owner.
Items
;
1154
ListBox.ObjectCollection collection = owner.
Items
;
1308
Assert.Empty(owner.
Items
);
1316
Assert.Empty(owner.
Items
);
1324
Assert.Empty(owner.
Items
);
1332
Assert.Empty(owner.
Items
);
1341
ListBox.ObjectCollection collection = owner.
Items
;
1349
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
1357
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
1365
Assert.Equal(new object[] { 2, 1, 1 }, owner.
Items
.Cast<object>());
1373
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
1393
Assert.Empty(owner.
Items
);
1401
Assert.Empty(owner.
Items
);
1409
Assert.Empty(owner.
Items
);
1417
Assert.Empty(owner.
Items
);
1429
ListBox.ObjectCollection collection = owner.
Items
;
1437
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
1445
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
1453
Assert.Equal(new object[] { 1, 1, 2 }, owner.
Items
.Cast<object>());
1461
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
1484
Assert.Empty(owner.
Items
);
1497
Assert.Empty(owner.
Items
);
1512
Assert.Empty(owner.
Items
);
1529
Assert.Empty(owner.
Items
);
1549
ListBox.ObjectCollection collection = owner.
Items
;
1563
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
1576
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
1591
Assert.Equal(new object[] { 2, 1, 1 }, owner.
Items
.Cast<object>());
1608
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
1645
Assert.Empty(owner.
Items
);
1658
Assert.Empty(owner.
Items
);
1673
Assert.Empty(owner.
Items
);
1690
Assert.Empty(owner.
Items
);
1713
ListBox.ObjectCollection collection = owner.
Items
;
1727
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
1740
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
1755
Assert.Equal(new object[] { 1, 1, 2 }, owner.
Items
.Cast<object>());
1772
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
1792
ListBox.ObjectCollection collection = owner.
Items
;
1824
ListBox.ObjectCollection collection = owner.
Items
;
1858
ListBox.ObjectCollection collection = owner.
Items
;
1903
ListBox.ObjectCollection collection = owner.
Items
;
1938
ListBox.ObjectCollection collection = owner.
Items
;
1983
ListBox.ObjectCollection collection = owner.
Items
;
2030
ListBox.ObjectCollection collection = owner.
Items
;
2091
ListBox.ObjectCollection collection = owner.
Items
;
2161
ListBox.ObjectCollection collection = owner.
Items
;
2226
Assert.Empty(owner.
Items
);
2234
Assert.Empty(owner.
Items
);
2243
ListBox.ObjectCollection collection = owner.
Items
;
2250
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2258
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2277
Assert.Empty(owner.
Items
);
2285
Assert.Empty(owner.
Items
);
2297
ListBox.ObjectCollection collection = owner.
Items
;
2304
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
2312
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
2334
Assert.Empty(owner.
Items
);
2353
Assert.Empty(owner.
Items
);
2373
ListBox.ObjectCollection collection = owner.
Items
;
2386
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2405
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2441
Assert.Empty(owner.
Items
);
2460
Assert.Empty(owner.
Items
);
2483
ListBox.ObjectCollection collection = owner.
Items
;
2496
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
2515
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
2535
ListBox.ObjectCollection collection = owner.
Items
;
2566
ListBox.ObjectCollection collection = owner.
Items
;
2599
ListBox.ObjectCollection collection = owner.
Items
;
2635
ListBox.ObjectCollection collection = owner.
Items
;
2662
ListBox.ObjectCollection collection = owner.
Items
;
2706
ListBox.ObjectCollection collection = owner.
Items
;
2752
ListBox.ObjectCollection collection = owner.
Items
;
2801
ListBox.ObjectCollection collection = owner.
Items
;
2854
ListBox.ObjectCollection collection = owner.
Items
;
2883
Assert.Empty(owner.
Items
);
2893
Assert.Empty(owner.
Items
);
2902
ListBox.ObjectCollection collection = owner.
Items
;
2912
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2922
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
2944
Assert.Empty(owner.
Items
);
2954
Assert.Empty(owner.
Items
);
2966
ListBox.ObjectCollection collection = owner.
Items
;
2976
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
2986
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
3011
Assert.Empty(owner.
Items
);
3032
Assert.Empty(owner.
Items
);
3052
ListBox.ObjectCollection collection = owner.
Items
;
3068
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
3089
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
3128
Assert.Empty(owner.
Items
);
3149
Assert.Empty(owner.
Items
);
3172
ListBox.ObjectCollection collection = owner.
Items
;
3188
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
3209
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
3229
ListBox.ObjectCollection collection = owner.
Items
;
3265
ListBox.ObjectCollection collection = owner.
Items
;
3303
ListBox.ObjectCollection collection = owner.
Items
;
3344
ListBox.ObjectCollection collection = owner.
Items
;
3376
ListBox.ObjectCollection collection = owner.
Items
;
3425
ListBox.ObjectCollection collection = owner.
Items
;
3476
ListBox.ObjectCollection collection = owner.
Items
;
3530
ListBox.ObjectCollection collection = owner.
Items
;
3591
ListBox.ObjectCollection collection = owner.
Items
;
3705
Assert.Empty(owner.
Items
);
3707
Assert.Empty(owner.
Items
);
3713
Assert.Empty(owner.
Items
);
3715
Assert.Empty(owner.
Items
);
3723
ListBox.ObjectCollection collection = owner.
Items
;
3726
Assert.Empty(owner.
Items
);
3728
Assert.Empty(owner.
Items
);
3734
Assert.Empty(owner.
Items
);
3736
Assert.Empty(owner.
Items
);
3751
Assert.Empty(owner.
Items
);
3753
Assert.Empty(owner.
Items
);
3759
Assert.Empty(owner.
Items
);
3761
Assert.Empty(owner.
Items
);
3769
ListBox.ObjectCollection collection = owner.
Items
;
3774
Assert.Empty(owner.
Items
);
3776
Assert.Empty(owner.
Items
);
3782
Assert.Empty(owner.
Items
);
3784
Assert.Empty(owner.
Items
);
3803
Assert.Empty(owner.
Items
);
3805
Assert.Empty(owner.
Items
);
3815
Assert.Empty(owner.
Items
);
3817
Assert.Empty(owner.
Items
);
3829
ListBox.ObjectCollection collection = owner.
Items
;
3840
Assert.Empty(owner.
Items
);
3842
Assert.Empty(owner.
Items
);
3852
Assert.Empty(owner.
Items
);
3854
Assert.Empty(owner.
Items
);
3878
Assert.Empty(owner.
Items
);
3880
Assert.Empty(owner.
Items
);
3890
Assert.Empty(owner.
Items
);
3892
Assert.Empty(owner.
Items
);
3904
ListBox.ObjectCollection collection = owner.
Items
;
3916
Assert.Empty(owner.
Items
);
3918
Assert.Empty(owner.
Items
);
3928
Assert.Empty(owner.
Items
);
3930
Assert.Empty(owner.
Items
);
4131
Assert.Empty(owner.
Items
);
4139
Assert.Empty(owner.
Items
);
4147
Assert.Empty(owner.
Items
);
4155
Assert.Empty(owner.
Items
);
4164
ListBox.ObjectCollection collection = owner.
Items
;
4172
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
4180
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
4188
Assert.Equal(new object[] { 2, 2, 1 }, owner.
Items
.Cast<object>());
4196
Assert.Equal(new object[] { 2, 2, 1, 3 }, owner.
Items
.Cast<object>());
4216
Assert.Empty(owner.
Items
);
4224
Assert.Empty(owner.
Items
);
4232
Assert.Empty(owner.
Items
);
4240
Assert.Empty(owner.
Items
);
4252
ListBox.ObjectCollection collection = owner.
Items
;
4260
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
4268
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
4276
Assert.Equal(new object[] { 1, 2, 2 }, owner.
Items
.Cast<object>());
4284
Assert.Equal(new object[] { 1, 2, 2, 3 }, owner.
Items
.Cast<object>());
4307
Assert.Empty(owner.
Items
);
4320
Assert.Empty(owner.
Items
);
4335
Assert.Empty(owner.
Items
);
4352
Assert.Empty(owner.
Items
);
4372
ListBox.ObjectCollection collection = owner.
Items
;
4386
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
4399
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
4414
Assert.Equal(new object[] { 2, 2, 1 }, owner.
Items
.Cast<object>());
4431
Assert.Equal(new object[] { 2, 2, 1, 3 }, owner.
Items
.Cast<object>());
4468
Assert.Empty(owner.
Items
);
4481
Assert.Empty(owner.
Items
);
4496
Assert.Empty(owner.
Items
);
4513
Assert.Empty(owner.
Items
);
4536
ListBox.ObjectCollection collection = owner.
Items
;
4550
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
4563
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
4578
Assert.Equal(new object[] { 1, 2, 2 }, owner.
Items
.Cast<object>());
4595
Assert.Equal(new object[] { 1, 2, 2, 3 }, owner.
Items
.Cast<object>());
4615
ListBox.ObjectCollection collection = owner.
Items
;
4647
ListBox.ObjectCollection collection = owner.
Items
;
4675
ListBox.ObjectCollection collection = owner.
Items
;
4720
ListBox.ObjectCollection collection = owner.
Items
;
4753
ListBox.ObjectCollection collection = owner.
Items
;
4798
ListBox.ObjectCollection collection = owner.
Items
;
4845
ListBox.ObjectCollection collection = owner.
Items
;
4906
ListBox.ObjectCollection collection = owner.
Items
;
4974
ListBox.ObjectCollection collection = owner.
Items
;
5070
Assert.Empty(owner.
Items
);
5078
Assert.Empty(owner.
Items
);
5086
Assert.Empty(owner.
Items
);
5094
Assert.Empty(owner.
Items
);
5103
ListBox.ObjectCollection collection = owner.
Items
;
5114
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
5121
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
5128
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
5135
Assert.Empty(owner.
Items
);
5160
Assert.Empty(owner.
Items
);
5168
Assert.Empty(owner.
Items
);
5176
Assert.Empty(owner.
Items
);
5184
Assert.Empty(owner.
Items
);
5196
ListBox.ObjectCollection collection = owner.
Items
;
5207
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
5214
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
5221
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
5228
Assert.Empty(owner.
Items
);
5254
Assert.Empty(owner.
Items
);
5269
Assert.Empty(owner.
Items
);
5284
Assert.Empty(owner.
Items
);
5297
Assert.Empty(owner.
Items
);
5309
ListBox.ObjectCollection collection = owner.
Items
;
5328
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
5344
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
5360
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
5374
Assert.Empty(owner.
Items
);
5406
Assert.Empty(owner.
Items
);
5421
Assert.Empty(owner.
Items
);
5436
Assert.Empty(owner.
Items
);
5449
Assert.Empty(owner.
Items
);
5464
ListBox.ObjectCollection collection = owner.
Items
;
5483
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
5499
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
5515
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
5529
Assert.Empty(owner.
Items
);
5541
ListBox.ObjectCollection collection = owner.
Items
;
5582
ListBox.ObjectCollection collection = owner.
Items
;
5625
ListBox.ObjectCollection collection = owner.
Items
;
5678
ListBox.ObjectCollection collection = owner.
Items
;
5724
ListBox.ObjectCollection collection = owner.
Items
;
5786
ListBox.ObjectCollection collection = owner.
Items
;
5850
ListBox.ObjectCollection collection = owner.
Items
;
5919
ListBox.ObjectCollection collection = owner.
Items
;
6017
Assert.Empty(owner.
Items
);
6025
Assert.Empty(owner.
Items
);
6033
Assert.Empty(owner.
Items
);
6042
ListBox.ObjectCollection collection = owner.
Items
;
6053
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
6060
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
6067
Assert.Empty(owner.
Items
);
6092
Assert.Empty(owner.
Items
);
6100
Assert.Empty(owner.
Items
);
6108
Assert.Empty(owner.
Items
);
6120
ListBox.ObjectCollection collection = owner.
Items
;
6131
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
6138
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
6145
Assert.Empty(owner.
Items
);
6171
Assert.Empty(owner.
Items
);
6186
Assert.Empty(owner.
Items
);
6199
Assert.Empty(owner.
Items
);
6211
ListBox.ObjectCollection collection = owner.
Items
;
6230
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
6246
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
6260
Assert.Empty(owner.
Items
);
6292
Assert.Empty(owner.
Items
);
6307
Assert.Empty(owner.
Items
);
6320
Assert.Empty(owner.
Items
);
6335
ListBox.ObjectCollection collection = owner.
Items
;
6354
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
6370
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
6384
Assert.Empty(owner.
Items
);
6396
ListBox.ObjectCollection collection = owner.
Items
;
6437
ListBox.ObjectCollection collection = owner.
Items
;
6480
ListBox.ObjectCollection collection = owner.
Items
;
6533
ListBox.ObjectCollection collection = owner.
Items
;
6579
ListBox.ObjectCollection collection = owner.
Items
;
6641
ListBox.ObjectCollection collection = owner.
Items
;
6705
ListBox.ObjectCollection collection = owner.
Items
;
6774
ListBox.ObjectCollection collection = owner.
Items
;
6959
Assert.Empty(owner.
Items
);
6966
Assert.Empty(owner.
Items
);
6973
Assert.Empty(owner.
Items
);
6980
Assert.Empty(owner.
Items
);
7004
Assert.Empty(owner.
Items
);
7011
Assert.Empty(owner.
Items
);
7018
Assert.Empty(owner.
Items
);
7025
Assert.Empty(owner.
Items
);
7034
IList collection = owner.
Items
;
7044
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
7051
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
7058
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
7065
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
7077
IList collection = owner.
Items
;
7087
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
7094
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
7101
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
7108
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
7298
IList collection = owner.
Items
;
7316
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
7333
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
7350
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
7367
Assert.Equal(new int[] { 4, 2, 5 }, owner.
Items
.Cast<int>());
7389
IList collection = owner.
Items
;
7407
Assert.Equal(new int[] { 4, 2, 3 }, owner.
Items
.Cast<int>());
7424
Assert.Equal(new int[] { 4, 1, 3 }, owner.
Items
.Cast<int>());
7441
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
7458
Assert.Equal(new int[] { 4, 1, 5 }, owner.
Items
.Cast<int>());
7477
IList collection = owner.
Items
;
7526
IList collection = owner.
Items
;
7577
IList collection = owner.
Items
;
7647
IList collection = owner.
Items
;
7711
IList collection = owner.
Items
;
7784
IList collection = owner.
Items
;
7859
IList collection = owner.
Items
;
7959
IList collection = owner.
Items
;
8113
Assert.Empty(owner.
Items
);
8121
Assert.Empty(owner.
Items
);
8129
Assert.Empty(owner.
Items
);
8137
Assert.Empty(owner.
Items
);
8146
IList collection = owner.
Items
;
8154
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
8162
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
8170
Assert.Equal(new object[] { 2, 1, 1 }, owner.
Items
.Cast<object>());
8178
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
8198
Assert.Empty(owner.
Items
);
8206
Assert.Empty(owner.
Items
);
8214
Assert.Empty(owner.
Items
);
8222
Assert.Empty(owner.
Items
);
8234
IList collection = owner.
Items
;
8242
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
8250
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
8258
Assert.Equal(new object[] { 1, 1, 2 }, owner.
Items
.Cast<object>());
8266
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
8289
Assert.Empty(owner.
Items
);
8302
Assert.Empty(owner.
Items
);
8317
Assert.Empty(owner.
Items
);
8334
Assert.Empty(owner.
Items
);
8354
IList collection = owner.
Items
;
8368
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
8381
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
8396
Assert.Equal(new object[] { 2, 1, 1 }, owner.
Items
.Cast<object>());
8413
Assert.Equal(new object[] { 2, 1, 1, 3 }, owner.
Items
.Cast<object>());
8450
Assert.Empty(owner.
Items
);
8463
Assert.Empty(owner.
Items
);
8478
Assert.Empty(owner.
Items
);
8495
Assert.Empty(owner.
Items
);
8518
IList collection = owner.
Items
;
8532
Assert.Equal(new object[] { 2 }, owner.
Items
.Cast<object>());
8545
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
8560
Assert.Equal(new object[] { 1, 1, 2 }, owner.
Items
.Cast<object>());
8577
Assert.Equal(new object[] { 1, 1, 2, 3 }, owner.
Items
.Cast<object>());
8597
IList collection = owner.
Items
;
8629
IList collection = owner.
Items
;
8663
IList collection = owner.
Items
;
8708
IList collection = owner.
Items
;
8743
IList collection = owner.
Items
;
8788
IList collection = owner.
Items
;
8835
IList collection = owner.
Items
;
8896
IList collection = owner.
Items
;
8966
IList collection = owner.
Items
;
9027
Assert.Empty(owner.
Items
);
9029
Assert.Empty(owner.
Items
);
9035
Assert.Empty(owner.
Items
);
9037
Assert.Empty(owner.
Items
);
9045
IList collection = owner.
Items
;
9048
Assert.Empty(owner.
Items
);
9050
Assert.Empty(owner.
Items
);
9056
Assert.Empty(owner.
Items
);
9058
Assert.Empty(owner.
Items
);
9073
Assert.Empty(owner.
Items
);
9075
Assert.Empty(owner.
Items
);
9081
Assert.Empty(owner.
Items
);
9083
Assert.Empty(owner.
Items
);
9091
IList collection = owner.
Items
;
9096
Assert.Empty(owner.
Items
);
9098
Assert.Empty(owner.
Items
);
9104
Assert.Empty(owner.
Items
);
9106
Assert.Empty(owner.
Items
);
9125
Assert.Empty(owner.
Items
);
9127
Assert.Empty(owner.
Items
);
9137
Assert.Empty(owner.
Items
);
9139
Assert.Empty(owner.
Items
);
9151
IList collection = owner.
Items
;
9162
Assert.Empty(owner.
Items
);
9164
Assert.Empty(owner.
Items
);
9174
Assert.Empty(owner.
Items
);
9176
Assert.Empty(owner.
Items
);
9200
Assert.Empty(owner.
Items
);
9202
Assert.Empty(owner.
Items
);
9212
Assert.Empty(owner.
Items
);
9214
Assert.Empty(owner.
Items
);
9226
IList collection = owner.
Items
;
9238
Assert.Empty(owner.
Items
);
9240
Assert.Empty(owner.
Items
);
9250
Assert.Empty(owner.
Items
);
9252
Assert.Empty(owner.
Items
);
9453
Assert.Empty(owner.
Items
);
9461
Assert.Empty(owner.
Items
);
9469
Assert.Empty(owner.
Items
);
9477
Assert.Empty(owner.
Items
);
9486
IList collection = owner.
Items
;
9494
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
9502
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
9510
Assert.Equal(new object[] { 2, 2, 1 }, owner.
Items
.Cast<object>());
9518
Assert.Equal(new object[] { 2, 2, 1, 3 }, owner.
Items
.Cast<object>());
9538
Assert.Empty(owner.
Items
);
9546
Assert.Empty(owner.
Items
);
9554
Assert.Empty(owner.
Items
);
9562
Assert.Empty(owner.
Items
);
9574
IList collection = owner.
Items
;
9582
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
9590
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
9598
Assert.Equal(new object[] { 1, 2, 2 }, owner.
Items
.Cast<object>());
9606
Assert.Equal(new object[] { 1, 2, 2, 3 }, owner.
Items
.Cast<object>());
9629
Assert.Empty(owner.
Items
);
9642
Assert.Empty(owner.
Items
);
9657
Assert.Empty(owner.
Items
);
9674
Assert.Empty(owner.
Items
);
9694
IList collection = owner.
Items
;
9708
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
9721
Assert.Equal(new object[] { 2, 1 }, owner.
Items
.Cast<object>());
9736
Assert.Equal(new object[] { 2, 2, 1 }, owner.
Items
.Cast<object>());
9753
Assert.Equal(new object[] { 2, 2, 1, 3 }, owner.
Items
.Cast<object>());
9790
Assert.Empty(owner.
Items
);
9803
Assert.Empty(owner.
Items
);
9818
Assert.Empty(owner.
Items
);
9835
Assert.Empty(owner.
Items
);
9858
IList collection = owner.
Items
;
9872
Assert.Equal(new object[] { 1 }, owner.
Items
.Cast<object>());
9885
Assert.Equal(new object[] { 1, 2 }, owner.
Items
.Cast<object>());
9900
Assert.Equal(new object[] { 1, 2, 2 }, owner.
Items
.Cast<object>());
9917
Assert.Equal(new object[] { 1, 2, 2, 3 }, owner.
Items
.Cast<object>());
9937
IList collection = owner.
Items
;
9969
IList collection = owner.
Items
;
9997
IList collection = owner.
Items
;
10042
IList collection = owner.
Items
;
10075
IList collection = owner.
Items
;
10120
IList collection = owner.
Items
;
10167
IList collection = owner.
Items
;
10228
IList collection = owner.
Items
;
10296
IList collection = owner.
Items
;
10392
Assert.Empty(owner.
Items
);
10400
Assert.Empty(owner.
Items
);
10408
Assert.Empty(owner.
Items
);
10416
Assert.Empty(owner.
Items
);
10425
IList collection = owner.
Items
;
10436
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
10443
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
10450
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
10457
Assert.Empty(owner.
Items
);
10482
Assert.Empty(owner.
Items
);
10490
Assert.Empty(owner.
Items
);
10498
Assert.Empty(owner.
Items
);
10506
Assert.Empty(owner.
Items
);
10518
IList collection = owner.
Items
;
10529
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
10536
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
10543
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
10550
Assert.Empty(owner.
Items
);
10576
Assert.Empty(owner.
Items
);
10591
Assert.Empty(owner.
Items
);
10606
Assert.Empty(owner.
Items
);
10619
Assert.Empty(owner.
Items
);
10631
IList collection = owner.
Items
;
10650
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
10666
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
10682
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
10696
Assert.Empty(owner.
Items
);
10728
Assert.Empty(owner.
Items
);
10743
Assert.Empty(owner.
Items
);
10758
Assert.Empty(owner.
Items
);
10771
Assert.Empty(owner.
Items
);
10786
IList collection = owner.
Items
;
10805
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
10821
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
10837
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
10851
Assert.Empty(owner.
Items
);
10863
IList collection = owner.
Items
;
10904
IList collection = owner.
Items
;
10947
IList collection = owner.
Items
;
11000
IList collection = owner.
Items
;
11046
IList collection = owner.
Items
;
11108
IList collection = owner.
Items
;
11172
IList collection = owner.
Items
;
11241
IList collection = owner.
Items
;
11339
Assert.Empty(owner.
Items
);
11347
Assert.Empty(owner.
Items
);
11355
Assert.Empty(owner.
Items
);
11364
IList collection = owner.
Items
;
11375
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
11382
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
11389
Assert.Empty(owner.
Items
);
11414
Assert.Empty(owner.
Items
);
11422
Assert.Empty(owner.
Items
);
11430
Assert.Empty(owner.
Items
);
11442
IList collection = owner.
Items
;
11453
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
11460
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
11467
Assert.Empty(owner.
Items
);
11493
Assert.Empty(owner.
Items
);
11508
Assert.Empty(owner.
Items
);
11521
Assert.Empty(owner.
Items
);
11533
IList collection = owner.
Items
;
11552
Assert.Equal(new int[] { 2, 3 }, owner.
Items
.Cast<int>());
11568
Assert.Equal(new int[] { 2 }, owner.
Items
.Cast<int>());
11582
Assert.Empty(owner.
Items
);
11614
Assert.Empty(owner.
Items
);
11629
Assert.Empty(owner.
Items
);
11642
Assert.Empty(owner.
Items
);
11657
IList collection = owner.
Items
;
11676
Assert.Equal(new int[] { 1, 3 }, owner.
Items
.Cast<int>());
11692
Assert.Equal(new int[] { 1 }, owner.
Items
.Cast<int>());
11706
Assert.Empty(owner.
Items
);
11718
IList collection = owner.
Items
;
11759
IList collection = owner.
Items
;
11802
IList collection = owner.
Items
;
11855
IList collection = owner.
Items
;
11901
IList collection = owner.
Items
;
11963
IList collection = owner.
Items
;
12027
IList collection = owner.
Items
;
12096
IList collection = owner.
Items
;
System\Windows\Forms\ListBoxTests.cs (265)
87
Assert.Empty(control.
Items
);
88
Assert.Same(control.
Items
, control.
Items
);
763
control.
Items
.Add("Value");
1061
Assert.Empty(control.
Items
);
1069
Assert.Empty(control.
Items
);
1081
control.
Items
.Add("item1");
1082
control.
Items
.Add("item2");
1083
control.
Items
.Add("item1");
1089
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<object>());
1097
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<object>());
1129
Assert.Empty(control.
Items
);
1140
Assert.Empty(control.
Items
);
1163
control.
Items
.Add("item1");
1164
control.
Items
.Add("item2");
1165
control.
Items
.Add("item1");
1178
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<object>());
1189
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<object>());
1486
Assert.Empty(control.
Items
);
1492
Assert.Empty(control.
Items
);
1498
Assert.Empty(control.
Items
);
1510
control.
Items
.Add("item1");
1511
control.
Items
.Add("item2");
1512
control.
Items
.Add("item1");
1516
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1522
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1528
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1558
Assert.Empty(control.
Items
);
1567
Assert.Empty(control.
Items
);
1576
Assert.Empty(control.
Items
);
1599
control.
Items
.Add("item1");
1600
control.
Items
.Add("item2");
1601
control.
Items
.Add("item1");
1612
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1621
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1630
Assert.Equal(new string[] { "item1", "item2", "item1" }, control.
Items
.Cast<string>());
1860
Assert.Same(result, control.
Items
);
1861
Assert.Same(control.
Items
, control.
Items
);
2102
control.
Items
.Add("Item1");
2103
control.
Items
.Add("Item2");
2156
control.
Items
.Add("Item1");
2157
control.
Items
.Add("Item2");
2314
control.
Items
.Add("Item");
2353
control.
Items
.Add("item1");
2354
control.
Items
.Add("item2");
2355
control.
Items
.Add("item1");
2398
control.
Items
.Add("item1");
2399
control.
Items
.Add("item2");
2400
control.
Items
.Add("item1");
2496
control.
Items
.Add("item1");
2497
control.
Items
.Add("item2");
2498
control.
Items
.Add("item1");
2560
control.
Items
.Add("item1");
2561
control.
Items
.Add("item2");
2562
control.
Items
.Add("item1");
2623
control.
Items
.Add("item1");
2624
control.
Items
.Add("item2");
2625
control.
Items
.Add("item1");
2650
control.
Items
.Add("item1");
2651
control.
Items
.Add("item2");
2652
control.
Items
.Add("item1");
2685
control.
Items
.Add("item1");
2686
control.
Items
.Add("item2");
2687
control.
Items
.Add("item1");
2742
control.
Items
.Add("Item");
2777
control.
Items
.Add("Item");
2819
control.
Items
.Add("item1");
2820
control.
Items
.Add("item2");
2821
control.
Items
.Add("item1");
2872
control.
Items
.Add("item1");
2873
control.
Items
.Add("item2");
2874
control.
Items
.Add("item1");
2987
control.
Items
.Add("item1");
2988
control.
Items
.Add("item2");
2989
control.
Items
.Add("item1");
3062
control.
Items
.Add("item1");
3063
control.
Items
.Add("item2");
3064
control.
Items
.Add("item1");
3136
control.
Items
.Add("item1");
3137
control.
Items
.Add("item2");
3138
control.
Items
.Add("item1");
3167
control.
Items
.Add("item1");
3168
control.
Items
.Add("item2");
3169
control.
Items
.Add("item1");
3209
control.
Items
.Add("item1");
3210
control.
Items
.Add("item2");
3211
control.
Items
.Add("item1");
3276
control.
Items
.Add("item");
3294
control.
Items
.Add("Item0");
3295
control.
Items
.Add("Item1");
3296
control.
Items
.Add("Item2");
3297
control.
Items
.Add("Item3");
3298
control.
Items
.Add("Item4");
3424
control.
Items
.Add("item1");
3425
control.
Items
.Add("item2");
3426
control.
Items
.Add("item1");
3460
control.
Items
.Add("item1");
3461
control.
Items
.Add("item2");
3462
control.
Items
.Add("item1");
3501
control.
Items
.Add("item1");
3502
control.
Items
.Add("item2");
3503
control.
Items
.Add("item1");
3543
control.
Items
.Add("item1");
3544
control.
Items
.Add("item2");
3545
control.
Items
.Add("item1");
3684
control.
Items
.Add("item1");
3685
control.
Items
.Add("item2");
3686
control.
Items
.Add("item1");
3736
control.
Items
.Add("item1");
3737
control.
Items
.Add("item2");
3738
control.
Items
.Add("item1");
3793
control.
Items
.Add("item1");
3794
control.
Items
.Add("item2");
3795
control.
Items
.Add("item1");
3851
control.
Items
.Add("item1");
3852
control.
Items
.Add("item2");
3853
control.
Items
.Add("item1");
3917
Assert.Empty(control.
Items
);
3923
Assert.Empty(control.
Items
);
3929
Assert.Empty(control.
Items
);
3938
Assert.Empty(control.
Items
);
3942
Assert.Empty(control.
Items
);
3948
Assert.Empty(control.
Items
);
3954
Assert.Empty(control.
Items
);
3969
control.
Items
.Add("item2");
3970
control.
Items
.Add("item1");
3974
Assert.Equal(expected, control.
Items
.Cast<string>());
3980
Assert.Equal(expected, control.
Items
.Cast<string>());
3986
Assert.Equal(new string[] { "item1", "item2" }, control.
Items
.Cast<string>());
4005
Assert.Empty(control.
Items
);
4014
Assert.Empty(control.
Items
);
4023
Assert.Empty(control.
Items
);
4042
Assert.Empty(control.
Items
);
4046
Assert.Empty(control.
Items
);
4055
Assert.Empty(control.
Items
);
4064
Assert.Empty(control.
Items
);
4076
control.
Items
.Add("item2");
4077
control.
Items
.Add("item1");
4088
Assert.Equal(expected, control.
Items
.Cast<string>());
4097
Assert.Equal(expected, control.
Items
.Cast<string>());
4106
Assert.Equal(new string[] { "item1", "item2" }, control.
Items
.Cast<string>());
4164
control.
Items
.Add("item1");
4165
control.
Items
.Add("item2");
4166
control.
Items
.Add("item1");
4214
control.
Items
.Add("item1");
4215
control.
Items
.Add("item2");
4216
control.
Items
.Add("item1");
4337
control.
Items
.Add("item1");
4338
control.
Items
.Add("item2");
4339
control.
Items
.Add("item1");
4395
control.
Items
.Add("item1");
4396
control.
Items
.Add("item2");
4425
control.
Items
.Add("item1");
4426
control.
Items
.Add("item2");
4427
control.
Items
.Add("item1");
4561
Assert.Equal(new string[] { "item1", "item2" }, control.
Items
.Cast<object>());
4566
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4571
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4576
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4594
Assert.Equal(new string[] { "item1", "item2" }, control.
Items
.Cast<object>());
4602
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4610
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4618
Assert.Equal(new string[] { "item1", "item2", "item3" }, control.
Items
.Cast<object>());
4942
Assert.Empty(controlWithNoItems.
Items
);
4952
controlWithItems.
Items
.Add(new DataClass { Value = "abc" });
4953
controlWithItems.
Items
.Add(new DataClass { Value = "abc" });
4954
controlWithItems.
Items
.Add(new DataClass { Value = "ABC" });
4955
controlWithItems.
Items
.Add(new DataClass { Value = "def" });
4956
controlWithItems.
Items
.Add(new DataClass { Value = "" });
4957
controlWithItems.
Items
.Add(new DataClass { Value = null });
5033
control.
Items
.Add("item");
5046
Assert.Empty(controlWithNoItems.
Items
);
5056
controlWithItems.
Items
.Add(new DataClass { Value = "abc" });
5057
controlWithItems.
Items
.Add(new DataClass { Value = "abc" });
5058
controlWithItems.
Items
.Add(new DataClass { Value = "ABC" });
5059
controlWithItems.
Items
.Add(new DataClass { Value = "def" });
5060
controlWithItems.
Items
.Add(new DataClass { Value = "" });
5061
controlWithItems.
Items
.Add(new DataClass { Value = null });
5137
control.
Items
.Add("item");
5170
control.
Items
.Add("Item1");
5171
control.
Items
.Add("Item2");
5209
control.
Items
.Add("Item1");
5210
control.
Items
.Add("Item2");
5249
control.
Items
.Add("Item1");
5250
control.
Items
.Add("Item2");
5280
control.
Items
.Add("Item");
5319
control.
Items
.Add("Item");
5327
control.
Items
.Add("Item1");
5328
control.
Items
.Add("Item1");
5350
control.
Items
.Add("Item1");
5351
control.
Items
.Add("Item1");
5396
control.
Items
.Add("Item");
5424
control.
Items
.Add("Item");
5462
control.
Items
.Add("Item");
5482
control.
Items
.Add("Item");
5887
Assert.Empty(control.
Items
);
5892
Assert.Empty(control.
Items
);
5900
control.
Items
.Add("item1");
5901
control.
Items
.Add("item2");
5904
Assert.Equal(new object[] { "item1", "item2" }, control.
Items
.Cast<object>());
5909
Assert.Equal(new object[] { "item1", "item2" }, control.
Items
.Cast<object>());
5926
Assert.Empty(control.
Items
);
5934
Assert.Empty(control.
Items
);
5945
control.
Items
.Add("item1");
5946
control.
Items
.Add("item2");
5956
Assert.Equal(new object[] { "item1", "item2" }, control.
Items
.Cast<object>());
5964
Assert.Equal(new object[] { "item1", "item2" }, control.
Items
.Cast<object>());
6021
Assert.Equal(value, control.
Items
.Cast<object>());
6026
Assert.Equal(value, control.
Items
.Cast<object>());
6044
Assert.Equal(value, control.
Items
.Cast<object>());
6052
Assert.Equal(value, control.
Items
.Cast<object>());
6064
Assert.Empty(control.
Items
);
6071
control.
Items
.Add("item1");
6072
control.
Items
.Add("item2");
6074
Assert.Equal(new object[] { "item1", "item2" }, control.
Items
.Cast<object>());
6088
Assert.Empty(control.
Items
);
6104
control.
Items
.Add(item1);
6105
control.
Items
.Add("item2");
6121
listBox.
Items
.AddRange((object[])["1", "2", "3"]);
6122
listBox.SelectedItem = listBox.
Items
[0];
6124
Assert.Equal(3, listBox.
Items
.Count);
6125
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6130
listBox.
Items
.Remove(listBox.
Items
[2]);
6132
Assert.Equal(2, listBox.
Items
.Count);
6133
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6138
listBox.
Items
.Remove(listBox.
Items
[1]);
6140
Assert.Single(listBox.
Items
);
6141
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6162
listBox.
Items
.AddRange((object[])["1", "2", "3", "4"]);
6163
listBox.SelectedItems.Add(listBox.
Items
[0]);
6164
listBox.SelectedItems.Add(listBox.
Items
[1]);
6166
Assert.Equal(4, listBox.
Items
.Count);
6167
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6172
listBox.
Items
.Remove(listBox.
Items
[3]);
6174
Assert.Equal(3, listBox.
Items
.Count);
6175
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6180
listBox.
Items
.Remove(listBox.
Items
[2]);
6182
Assert.Equal(2, listBox.
Items
.Count);
6183
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6202
listBox.
Items
.AddRange((object[])["1", "2", "3"]);
6204
for (int count = listBox.
Items
.Count; count > 1; count -= 1)
6206
listBox.SelectedItem = listBox.
Items
[0];
6208
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6213
listBox.
Items
.Remove(listBox.
Items
[0]);
6216
Assert.Equal(count, listBox.
Items
.Count);
6238
listBox.
Items
.AddRange((object[])["1", "2", "3"]);
6240
for (int count = listBox.
Items
.Count; count > 1; count -= 1)
6242
listBox.SelectedItems.Add(listBox.
Items
[0]);
6244
Assert.Equal(listBox.
Items
[0], listBox.SelectedItem);
6249
listBox.
Items
.Remove(listBox.
Items
[0]);
6253
Assert.Equal(count, listBox.
Items
.Count);
6270
listBox.
Items
.Add(selectedItem);
6313
listBox.
Items
.Add(item);
6316
int itemCount = listBox.
Items
.Count;
6326
listBox.
Items
.Add("Item1");
6343
listBox.
Items
.Add("Item1");
6364
for (int i = 0; i < listBox.
Items
.Count; i++)
6388
for (int i = 0; i < listBox.
Items
.Count; i++)
System.Windows.Forms.UI.IntegrationTests (10)
DragDropTests.cs (8)
52
Assert.Single(form.ListDragTarget.
Items
);
413
Assert.Equal(2, form.ListDragTarget.
Items
.Count);
606
ListDragSource.
Items
.AddRange("one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten");
710
ListDragSource.
Items
[_indexOfItemUnderMouseToDrag],
716
ListDragSource.
Items
.RemoveAt(_indexOfItemUnderMouseToDrag);
722
else if (ListDragSource.
Items
.Count > 0)
835
ListDragTarget.
Items
.Insert(_indexOfItemUnderMouseToDrop, item);
837
ListDragTarget.
Items
.Add(item);
ListBoxItemAccessibleObjestTests.cs (2)
16
listBox.
Items
.Add("Test Item");
54
listBox.
Items
.Add("Test Item");
WinFormsControlsTest (4)
ListBoxes.cs (3)
21
listBox.
Items
.Add(textBox.Text);
28
listBox.
Items
.Clear();
46
e.Graphics.DrawString(listBox.
Items
[e.Index].ToString(),
ScrollableControls.Designer.cs (1)
428
listBox1.
Items
.AddRange(new object[] { "asdfasdf", "as", "df", "asd", "f", "a", "sd", "f", "asd", "f", "a", "asdfadsf", "sdf" });