202 instantiations of ListViewSubItem
System.Windows.Forms (8)
System\Windows\Forms\Controls\ListView\ListViewItem.cs (4)
99
_subItems.Add(new
ListViewSubItem
(this, items[i]));
190
_subItems.Add(new
ListViewSubItem
(this, items[i]));
779
_subItems = [new
ListViewSubItem
(this, string.Empty)];
890
clonedSubItems[index] = new
ListViewSubItem
(
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItemCollection.cs (4)
120
ListViewSubItem item =
new
(_owner, text);
127
ListViewSubItem item =
new
(_owner, text, foreColor, backColor, font);
159
_owner._subItems.Add(new
ListViewSubItem
(_owner, item));
176
_owner._subItems.Add(new
ListViewSubItem
(_owner, item, foreColor, backColor, font));
System.Windows.Forms.Tests (193)
SerializableTypesTests.cs (1)
210
ListViewSubItem listViewSubItem =
new
(
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewItemAccessibleObjectTests.cs (4)
492
listView.Items[0].SubItems.Add(new
ListViewSubItem
() { Text = $"SubItem 0" });
493
listView.Items[1].SubItems.Add(new
ListViewSubItem
() { Text = $"SubItem 0" });
1150
listItem1.SubItems.Add(new
ListViewSubItem
() { Text = $"SubItem {i}" });
1151
listItem2.SubItems.Add(new
ListViewSubItem
() { Text = $"SubItem {i}" });
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewItemDetailsAccessibleObjectTests.cs (9)
40
item.SubItems.AddRange(new ListViewSubItem[] {
new
(),
new
(),
new
(),
new
(),
new
() });
72
item.SubItems.AddRange(new ListViewSubItem[] {
new
(),
new
(),
new
(),
new
() });
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObjectTests.cs (14)
859
ListViewItem.ListViewSubItem subItem =
new
(listViewItem, "Test subItem");
916
ListViewItem.ListViewSubItem listViewSubItem =
new
(listViewItem, "Test subItem");
929
ListViewItem.ListViewSubItem listViewSubItem =
new
(listViewItem, "Test subItem");
944
ListViewItem.ListViewSubItem listViewSubItem =
new
(listViewItem, "Test subItem");
973
ListViewItem.ListViewSubItem listViewSubItem =
new
(listViewItem, "Test subItem");
1051
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1063
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1079
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1095
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1111
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1127
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1143
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1159
ListViewItem.ListViewSubItem listViewSubItem =
new
();
1165
listView.Items[0].SubItems[subItemIndex] = new ListViewItem.
ListViewSubItem
();
System\Windows\Forms\AccessibleObjects\ListViewLabelEditAccessibleObjectTests.cs (1)
164
ListViewSubItem subItem =
new
(item, "Test");
System\Windows\Forms\BinaryFormat\WinFormsBinaryFormattedObjectTests.cs (1)
229
new ListViewItem.
ListViewSubItem
()
System\Windows\Forms\DrawListViewItemEventArgsTests.cs (2)
92
subItemsItem.SubItems.Add(new ListViewItem.
ListViewSubItem
());
100
fullRowSelectListViewItem.SubItems.Add(new ListViewItem.
ListViewSubItem
());
System\Windows\Forms\DrawListViewSubItemEventArgsTests.cs (19)
12
yield return new object[] { Rectangle.Empty, null, new ListViewItem.
ListViewSubItem
(), -2, -2, null, ListViewItemStates.Checked - 1 };
13
yield return new object[] { Rectangle.Empty, new ListViewItem(), new ListViewItem.
ListViewSubItem
(), -2, -2, null, ListViewItemStates.Checked - 1 };
15
yield return new object[] { new Rectangle(1, 2, 3, 4), new ListViewItem(), new ListViewItem.
ListViewSubItem
(), -1, -1, new ColumnHeader(), ListViewItemStates.Checked };
16
yield return new object[] { new Rectangle(-1, 2, -3, -4), new ListViewItem(), new ListViewItem.
ListViewSubItem
(), 0, 0, new ColumnHeader(), ListViewItemStates.Focused };
17
yield return new object[] { new Rectangle(1, 2, 3, 4), new ListViewItem(), new ListViewItem.
ListViewSubItem
(), 1, 2, new ColumnHeader(), ListViewItemStates.Checked };
41
Assert.Throws<ArgumentNullException>("graphics", () => new DrawListViewSubItemEventArgs(null, new Rectangle(1, 2, 3, 4), new ListViewItem(), new ListViewItem.
ListViewSubItem
(), -1, 0, new ColumnHeader(), ListViewItemStates.Default));
49
Assert.Throws<ArgumentNullException>("item", () => new DrawListViewSubItemEventArgs(graphics, new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), -1, 0, new ColumnHeader(), ListViewItemStates.Default));
98
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Default };
99
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Checked };
100
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Focused };
101
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Default };
102
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Checked };
103
yield return new object[] { new Rectangle(-1, -2, -3, -4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Focused };
104
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Default };
105
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Checked };
106
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, null, ListViewItemStates.Focused };
107
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Default };
108
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Checked };
109
yield return new object[] { new Rectangle(1, 2, 3, 4), null, new ListViewItem.
ListViewSubItem
(), 0, new ColumnHeader(), ListViewItemStates.Focused };
System\Windows\Forms\ListView.ListViewItemCollectionTests.cs (3)
28
var grandchild1 = new ListViewItem.
ListViewSubItem
32
var grandchild2 = new ListViewItem.
ListViewSubItem
36
var grandchild3 = new ListViewItem.
ListViewSubItem
System\Windows\Forms\ListViewHitTestInfoTests.cs (1)
12
yield return new object[] { new ListViewItem(), new ListViewItem.
ListViewSubItem
(), ListViewHitTestLocations.None - 1 };
System\Windows\Forms\ListViewItem.IKeyboardToolTipTests.cs (2)
179
listViewItem.SubItems.Add(new
ListViewSubItem
(listViewItem, new string('t', 10)));
194
ListViewSubItem listViewSubItem =
new
(listViewItem, new string('t', 20));
System\Windows\Forms\ListViewItemConverterTests.cs (5)
51
var subItem1 = new ListViewItem.
ListViewSubItem
(null, "text1");
52
var subItem2 = new ListViewItem.
ListViewSubItem
(null, "text2");
53
var subItem3 = new ListViewItem.
ListViewSubItem
(null, "text3")
57
var subItem4 = new ListViewItem.
ListViewSubItem
(null, "text4")
61
var subItem5 = new ListViewItem.
ListViewSubItem
(null, "text5")
System\Windows\Forms\ListViewItemTests.cs (9)
197
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, string.Empty, null, string.Empty, "text" };
198
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, "imageKey", new ListViewGroup(), "imageKey", "text" };
234
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, 1, null, "text" };
235
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, -1, new ListViewGroup(), "text" };
423
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, string.Empty, string.Empty, "text" };
424
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, "imageKey", "imageKey", "text" };
460
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, 1, "text" };
461
yield return new object[] { new ListViewItem.ListViewSubItem[] {
new
(null, "text") }, -1, "text" };
1050
AssertEqualListViewSubItem(expected?.Select(t => new ListViewItem.
ListViewSubItem
(null, t)).ToArray(), actual);
System\Windows\Forms\ListViewSubItemCollectionTests.cs (86)
44
var subItem = new ListViewItem.
ListViewSubItem
();
57
new ListViewItem.
ListViewSubItem
()
68
new ListViewItem.
ListViewSubItem
()
71
var subItem = new ListViewItem.
ListViewSubItem
();
84
new ListViewItem.
ListViewSubItem
()
86
Assert.Throws<ArgumentOutOfRangeException>("index", () => collection[index] = new ListViewItem.
ListViewSubItem
());
95
new ListViewItem.
ListViewSubItem
()
106
var subItem = new ListViewItem.
ListViewSubItem
();
119
new ListViewItem.
ListViewSubItem
()
130
new ListViewItem.
ListViewSubItem
()
133
var subItem = new ListViewItem.
ListViewSubItem
();
146
new ListViewItem.
ListViewSubItem
()
173
var subItem1 = new ListViewItem.
ListViewSubItem
();
174
var subItem2 = new ListViewItem.
ListViewSubItem
189
var subItem = new ListViewItem.
ListViewSubItem
();
202
var subItem = new ListViewItem.
ListViewSubItem
();
207
Assert.Throws<InvalidOperationException>(() => collection.Add(new ListViewItem.
ListViewSubItem
()));
215
var subItem = new ListViewItem.
ListViewSubItem
();
232
var subItem = new ListViewItem.
ListViewSubItem
();
292
var subItem = new ListViewItem.
ListViewSubItem
();
313
var subItem1 = new ListViewItem.
ListViewSubItem
(null, "text1");
314
var subItem2 = new ListViewItem.
ListViewSubItem
(null, "text2");
328
var subItem1 = new ListViewItem.
ListViewSubItem
(null, "text1");
329
var subItem2 = new ListViewItem.
ListViewSubItem
(null, "text2");
330
var subItem3 = new ListViewItem.
ListViewSubItem
(null, "text3");
331
var subItem4 = new ListViewItem.
ListViewSubItem
(null, "text4");
347
var subItem1 = new ListViewItem.
ListViewSubItem
(null, "text1");
348
var subItem2 = new ListViewItem.
ListViewSubItem
(null, "text2");
349
var subItem3 = new ListViewItem.
ListViewSubItem
(null, "text3");
350
var subItem4 = new ListViewItem.
ListViewSubItem
(null, "text4");
351
var subItem5 = new ListViewItem.
ListViewSubItem
(null, "text5");
352
var subItem6 = new ListViewItem.
ListViewSubItem
(null, "text6");
353
var subItem7 = new ListViewItem.
ListViewSubItem
(null, "text7");
354
var subItem8 = new ListViewItem.
ListViewSubItem
(null, "text8");
355
var subItem9 = new ListViewItem.
ListViewSubItem
(null, "text8");
427
var subItem = new ListViewItem.
ListViewSubItem
();
455
var subItem = new ListViewItem.
ListViewSubItem
();
459
Assert.False(collection.Contains(new ListViewItem.
ListViewSubItem
()));
469
Assert.False(collection.Contains(new ListViewItem.
ListViewSubItem
()));
485
var subItem1 = new ListViewItem.
ListViewSubItem
();
486
var subItem2 = new ListViewItem.
ListViewSubItem
511
var subItem = new ListViewItem.
ListViewSubItem
();
515
Assert.False(collection.Contains(new ListViewItem.
ListViewSubItem
()));
526
Assert.False(collection.Contains(new ListViewItem.
ListViewSubItem
()));
536
var subItem = new ListViewItem.
ListViewSubItem
();
540
Assert.Equal(-1, collection.IndexOf(new ListViewItem.
ListViewSubItem
()));
550
Assert.Equal(-1, collection.IndexOf(new ListViewItem.
ListViewSubItem
()));
566
var subItem1 = new ListViewItem.
ListViewSubItem
();
567
var subItem2 = new ListViewItem.
ListViewSubItem
596
var subItem = new ListViewItem.
ListViewSubItem
();
600
Assert.Equal(-1, collection.IndexOf(new ListViewItem.
ListViewSubItem
()));
611
Assert.Equal(-1, collection.IndexOf(new ListViewItem.
ListViewSubItem
()));
621
var subItem = new ListViewItem.
ListViewSubItem
();
622
collection.Add(new ListViewItem.
ListViewSubItem
());
636
var subItem = new ListViewItem.
ListViewSubItem
();
641
Assert.Throws<InvalidOperationException>(() => collection.Add(new ListViewItem.
ListViewSubItem
()));
650
new ListViewItem.
ListViewSubItem
()
670
var subItem = new ListViewItem.
ListViewSubItem
();
671
collection.Add(new ListViewItem.
ListViewSubItem
());
695
Assert.Throws<ArgumentOutOfRangeException>("index", () => collection.Insert(index, new ListViewItem.
ListViewSubItem
()));
703
var subItem = new ListViewItem.
ListViewSubItem
();
725
var subItem = new ListViewItem.
ListViewSubItem
();
745
var subItem = new ListViewItem.
ListViewSubItem
();
757
var subItem1 = new ListViewItem.
ListViewSubItem
();
758
var subItem2 = new ListViewItem.
ListViewSubItem
();
759
var subItem3 = new ListViewItem.
ListViewSubItem
();
760
var subItem4 = new ListViewItem.
ListViewSubItem
();
807
new ListViewItem.
ListViewSubItem
()
834
var subItem = new ListViewItem.
ListViewSubItem
857
var subItem = new ListViewItem.
ListViewSubItem
();
879
ListViewItem.ListViewSubItem subItem =
new
();
912
ListViewItem.ListViewSubItem subItem1 =
new
();
913
ListViewItem.ListViewSubItem subItem2 =
new
();
950
ListViewItem.ListViewSubItem subItem1 =
new
();
951
ListViewItem.ListViewSubItem subItem2 =
new
();
973
ListViewItem.ListViewSubItem subItem =
new
();
986
ListViewItem.ListViewSubItem subItem1 =
new
();
987
ListViewItem.ListViewSubItem subItem2 =
new
();
989
ListViewItem.ListViewSubItem oldSubItem2 =
new
();
1018
ListViewItem.ListViewSubItem subItem =
new
();
1036
ListViewItem.ListViewSubItem subItem =
new
();
1052
ListViewItem.ListViewSubItem subItem1 =
new
();
1053
ListViewItem.ListViewSubItem subItem2 =
new
();
1075
ListViewItem.ListViewSubItem subItem =
new
();
1094
ListViewItem.ListViewSubItem subItem =
new
();
1114
ListViewItem.ListViewSubItem subItem =
new
(listViewItem, "Test 2") { Name = "Test 2" };
System\Windows\Forms\ListViewSubItemConverterTests.cs (4)
53
new ListViewItem.
ListViewSubItem
(item, "text"),
60
new ListViewItem.
ListViewSubItem
(null, "text", Color.Red, Color.Blue, SystemFonts.MenuFont),
105
Assert.Throws<NotSupportedException>(() => converter.ConvertTo(new ListViewItem.
ListViewSubItem
(), destinationType));
119
var item = new ListViewItem.
ListViewSubItem
();
System\Windows\Forms\ListViewSubItemTests.cs (32)
16
var subItem = new ListViewItem.
ListViewSubItem
();
42
var subItem = new ListViewItem.
ListViewSubItem
(owner, text);
68
var subItem = new ListViewItem.
ListViewSubItem
(owner, text, foreColor, backColor, font);
88
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
103
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
123
var subItem = new ListViewItem.
ListViewSubItem
();
142
var subItem = new ListViewItem.
ListViewSubItem
172
var subItem = new ListViewItem.
ListViewSubItem
();
191
var subItem = new ListViewItem.
ListViewSubItem
();
210
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
224
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
239
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
260
var subItem = new ListViewItem.
ListViewSubItem
();
273
var subItem = new ListViewItem.
ListViewSubItem
297
var subItem = new ListViewItem.
ListViewSubItem
();
316
var subItem = new ListViewItem.
ListViewSubItem
();
337
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
352
var subItem = new ListViewItem.
ListViewSubItem
(item, "text");
372
var subItem = new ListViewItem.
ListViewSubItem
();
393
var subItem = new ListViewItem.
ListViewSubItem
423
var subItem = new ListViewItem.
ListViewSubItem
();
442
var subItem = new ListViewItem.
ListViewSubItem
();
458
var subItem = new ListViewItem.
ListViewSubItem
(item, "text")
473
var subItem = new ListViewItem.
ListViewSubItem
488
var subItem = new ListViewItem.
ListViewSubItem
504
var subItem = new ListViewItem.
ListViewSubItem
(item, "text")
519
var subItem = new ListViewItem.
ListViewSubItem
540
var subItem = new ListViewItem.
ListViewSubItem
(owner, "text");
556
var subItem = new ListViewItem.
ListViewSubItem
(owner, "text", Color.Red, Color.Blue, SystemFonts.MenuFont);
571
yield return new object[] { new ListViewItem.
ListViewSubItem
() };
572
yield return new object[] { new ListViewItem.
ListViewSubItem
(null, "header", Color.Red, Color.Blue, SystemFonts.MenuFont) { Name = "name", Tag = "tag" } };
602
var subItem = new ListViewItem.
ListViewSubItem
(null, text);
System.Windows.Forms.UI.IntegrationTests (1)
ListViewTests.cs (1)
559
listViewItem.SubItems.Add(new ListViewItem.
ListViewSubItem
() { Text = $"Test SubItem{i}" });
300 references to ListViewSubItem
System.Windows.Forms (64)
System\Windows\Forms\Controls\ListView\DrawListViewItemEventArgs.cs (1)
103
ListViewItem.
ListViewSubItem
subItem = Item.SubItems[0];
System\Windows\Forms\Controls\ListView\DrawListViewSubItemEventArgs.cs (2)
20
ListViewItem.
ListViewSubItem
? subItem,
64
public ListViewItem.
ListViewSubItem
? SubItem { get; }
System\Windows\Forms\Controls\ListView\ListView.cs (2)
183
internal
ListViewSubItem
? _listViewSubItem;
3327
ListViewSubItem
listViewSubItem = listViewItem.SubItems[j];
System\Windows\Forms\Controls\ListView\ListViewHitTestInfo.cs (2)
14
public ListViewHitTestInfo(ListViewItem? hitItem, ListViewItem.
ListViewSubItem
? hitSubItem, ListViewHitTestLocations hitLocation)
34
public ListViewItem.
ListViewSubItem
? SubItem { get; }
System\Windows\Forms\Controls\ListView\ListViewItem.cs (15)
41
private List<
ListViewSubItem
> _subItems = [];
114
public ListViewItem(
ListViewSubItem
[] subItems, int imageIndex)
168
public ListViewItem(
ListViewSubItem
[] subItems, int imageIndex, ListViewGroup? group)
187
_subItems = new List<
ListViewSubItem
>(items.Length);
205
public ListViewItem(
ListViewSubItem
[] subItems, string? imageKey)
241
public ListViewItem(
ListViewSubItem
[] subItems, string? imageKey, ListViewGroup? group)
886
ListViewSubItem
[] clonedSubItems = new
ListViewSubItem
[SubItems.Count];
889
ListViewSubItem
subItem = SubItems[index];
913
foreach (
ListViewSubItem
subItem in clonedSubItems)
976
public
ListViewSubItem
? GetSubItemAt(int x, int y)
1254
ListViewSubItem
newItem = (
ListViewSubItem
)info.GetValue($"SubItem{i}", typeof(
ListViewSubItem
))!;
1278
info.AddValue($"SubItem{i}", _subItems[i], typeof(
ListViewSubItem
));
System\Windows\Forms\Controls\ListView\ListViewItem.IKeyboardToolTip.cs (1)
127
ListViewSubItem
subItem = SubItems[1];
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemBaseAccessibleObject.cs (1)
250
foreach (
ListViewSubItem
subItem in _owningItem.SubItems)
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemDetailsAccessibleObject.cs (5)
28
/// Converts the provided index of the <see cref="AccessibleObject"/>'s child to an index of a <see cref="
ListViewSubItem
"/>.
31
/// <returns>The index of an owning <see cref="
ListViewSubItem
"/>'s object.</returns>
95
if (child is not
ListViewSubItem
.ListViewSubItemAccessibleObject subItemAccessibleObject)
155
ListViewSubItem
.ListViewSubItemAccessibleObject fakeAccessibleObject = new(owningSubItem: null, _owningItem);
164
private int GetFakeSubItemIndex(
ListViewSubItem
.ListViewSubItemAccessibleObject fakeAccessibleObject)
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemTileAccessibleObject.cs (1)
89
|| child is not
ListViewSubItem
.ListViewSubItemAccessibleObject subItemAccessibleObject
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObject.cs (3)
21
internal
ListViewSubItem
? OwningSubItem { get; private set; }
23
public ListViewSubItemAccessibleObject(
ListViewSubItem
? owningSubItem, ListViewItem owningItem)
157
=> $"{nameof(
ListViewSubItem
)}-{ParentInternal.GetChildIndex(this)}";
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItemCollection.cs (21)
43
public
ListViewSubItem
this[int index]
57
ListViewSubItem
oldSubItem = _owner._subItems[index];
74
if (value is not
ListViewSubItem
item)
86
public virtual
ListViewSubItem
? this[string key]
107
public
ListViewSubItem
Add(
ListViewSubItem
item)
118
public
ListViewSubItem
Add(string? text)
120
ListViewSubItem
item = new(_owner, text);
125
public
ListViewSubItem
Add(string? text, Color foreColor, Color backColor, Font font)
127
ListViewSubItem
item = new(_owner, text, foreColor, backColor, font);
132
public void AddRange(params
ListViewSubItem
[] items)
137
foreach (
ListViewSubItem
item in items)
186
if (item is not
ListViewSubItem
itemValue)
211
public bool Contains(
ListViewSubItem
? subItem) => IndexOf(subItem) != -1;
215
if (item is not
ListViewSubItem
itemValue)
242
public int IndexOf(
ListViewSubItem
? subItem)
257
if (subItem is not
ListViewSubItem
subItemValue)
301
public void Insert(int index,
ListViewSubItem
item)
319
if (item is not
ListViewSubItem
subItem)
327
public void Remove(
ListViewSubItem
? item)
338
if (item is
ListViewSubItem
itemValue)
System\Windows\Forms\Controls\ListView\ListViewItemConverter.cs (6)
55
ctor = typeof(ListViewItem).GetConstructor([typeof(ListViewItem.
ListViewSubItem
[]), typeof(string)]);
57
ListViewItem.
ListViewSubItem
[] subItemArray = new ListViewItem.
ListViewSubItem
[item.SubItems.Count];
63
ctor = typeof(ListViewItem).GetConstructor([typeof(ListViewItem.
ListViewSubItem
[]), typeof(int)]);
65
ListViewItem.
ListViewSubItem
[] subItemArray = new ListViewItem.
ListViewSubItem
[item.SubItems.Count];
System\Windows\Forms\Controls\ListView\ListViewLabelEditAccessibleObject.cs (1)
6
using static System.Windows.Forms.ListViewItem.
ListViewSubItem
;
System\Windows\Forms\Controls\ListView\ListViewSubItemConverter.cs (3)
28
if (destinationType == typeof(InstanceDescriptor) && value is ListViewItem.
ListViewSubItem
item)
35
ctor = typeof(ListViewItem.
ListViewSubItem
).GetConstructor(
55
ctor = typeof(ListViewItem.
ListViewSubItem
).GetConstructor([typeof(ListViewItem), typeof(string)]);
System.Windows.Forms.Design (2)
System\Windows\Forms\Design\ListViewSubItemCollectionEditor.cs (2)
18
private ListViewItem.
ListViewSubItem
_firstSubItem;
32
if (instance is ListViewItem.
ListViewSubItem
item)
System.Windows.Forms.Tests (234)
SerializableAttributeTests.cs (1)
27
{ typeof(ListViewItem.
ListViewSubItem
).FullName },
SerializableTypesTests.cs (5)
186
var
item = Assert.Single(result.SubItems) as
ListViewSubItem
;
210
ListViewSubItem
listViewSubItem = new(
230
ListViewSubItem
result = BinarySerialization.EnsureDeserialize<
ListViewSubItem
>(blob);
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewItemDetailsAccessibleObjectTests.cs (2)
40
item.SubItems.AddRange(new
ListViewSubItem
[] { new(), new(), new(), new(), new() });
72
item.SubItems.AddRange(new
ListViewSubItem
[] { new(), new(), new(), new() });
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObjectTests.cs (16)
7
using static System.Windows.Forms.ListViewItem.
ListViewSubItem
;
652
ListViewItem.
ListViewSubItem
subItem = listViewItem1.SubItems[0];
859
ListViewItem.
ListViewSubItem
subItem = new(listViewItem, "Test subItem");
916
ListViewItem.
ListViewSubItem
listViewSubItem = new(listViewItem, "Test subItem");
929
ListViewItem.
ListViewSubItem
listViewSubItem = new(listViewItem, "Test subItem");
944
ListViewItem.
ListViewSubItem
listViewSubItem = new(listViewItem, "Test subItem");
973
ListViewItem.
ListViewSubItem
listViewSubItem = new(listViewItem, "Test subItem");
1051
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1063
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1079
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1095
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1111
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1127
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1143
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1159
ListViewItem.
ListViewSubItem
listViewSubItem = new();
1175
foreach (ListViewItem.
ListViewSubItem
subItem in item.SubItems)
System\Windows\Forms\AccessibleObjects\ListViewLabelEditAccessibleObjectTests.cs (1)
164
ListViewSubItem
subItem = new(item, "Test");
System\Windows\Forms\DrawListViewSubItemEventArgsTests.cs (3)
22
public void DrawListViewSubItemEventArgs_Ctor_Graphics_ListViewItem_Rectangle_Int_ListViewItemStates(Rectangle bounds, ListViewItem item, ListViewItem.
ListViewSubItem
subItem, int itemIndex, int columnIndex, ColumnHeader header, ListViewItemStates itemState)
114
public void DrawListViewSubItemEventArgs_DrawBackground_HasGraphics_Success(Rectangle bounds, ListViewItem item, ListViewItem.
ListViewSubItem
subItem, int itemIndex, ColumnHeader header, ListViewItemStates itemState)
124
public void DrawListViewSubItemEventArgs_DrawFocusRectangle_HasGraphics_Success(Rectangle bounds, ListViewItem item, ListViewItem.
ListViewSubItem
subItem, int itemIndex, ColumnHeader header, ListViewItemStates itemState)
System\Windows\Forms\ListView.ListViewItemCollectionTests.cs (3)
28
var
grandchild1 = new ListViewItem.ListViewSubItem
32
var
grandchild2 = new ListViewItem.ListViewSubItem
36
var
grandchild3 = new ListViewItem.ListViewSubItem
System\Windows\Forms\ListViewHitTestInfoTests.cs (1)
17
public void ListViewHitTestInfo_Ctor_ListViewItem_ListViewSubItem_ListViewHitTestLocations(ListViewItem hitItem, ListViewItem.
ListViewSubItem
hitSubItem, ListViewHitTestLocations hitTestLocations)
System\Windows\Forms\ListViewItem.IKeyboardToolTipTests.cs (1)
194
ListViewSubItem
listViewSubItem = new(listViewItem, new string('t', 20));
System\Windows\Forms\ListViewItemConverterTests.cs (13)
51
var
subItem1 = new ListViewItem.ListViewSubItem(null, "text1");
52
var
subItem2 = new ListViewItem.ListViewSubItem(null, "text2");
53
var
subItem3 = new ListViewItem.ListViewSubItem(null, "text3")
57
var
subItem4 = new ListViewItem.ListViewSubItem(null, "text4")
61
var
subItem5 = new ListViewItem.ListViewSubItem(null, "text5")
168
new Type[] { typeof(ListViewItem.
ListViewSubItem
[]), typeof(string) },
169
new object[] { new ListViewItem.
ListViewSubItem
[] { subItem1, subItem2, subItem3, subItem4, subItem5 }, "imageKey" }
174
new Type[] { typeof(ListViewItem.
ListViewSubItem
[]), typeof(int) },
175
new object[] { new ListViewItem.
ListViewSubItem
[] { subItem1, subItem2, subItem3, subItem4, subItem5 }, 1 }
180
new Type[] { typeof(ListViewItem.
ListViewSubItem
[]), typeof(string) },
181
new object[] { new ListViewItem.
ListViewSubItem
[] { subItem1, subItem2, subItem3, subItem4, subItem5 }, "imageKey" }
186
new Type[] { typeof(ListViewItem.
ListViewSubItem
[]), typeof(int) },
187
new object[] { new ListViewItem.
ListViewSubItem
[] { subItem1, subItem2, subItem3, subItem4, subItem5 }, 1 }
System\Windows\Forms\ListViewItemTests.cs (56)
33
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
72
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
110
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
148
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
186
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
196
yield return new object[] { Array.Empty<ListViewItem.
ListViewSubItem
>(), null, null, string.Empty, string.Empty };
197
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, string.Empty, null, string.Empty, "text" };
198
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, "imageKey", new ListViewGroup(), "imageKey", "text" };
203
public void ListViewItem_Ctor_ListViewSubItemArray_String_ListViewGroup(ListViewItem.
ListViewSubItem
[] subItems, string imageKey, ListViewGroup group, string expectedImageKey, string expectedText)
223
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
233
yield return new object[] { Array.Empty<ListViewItem.
ListViewSubItem
>(), 0, null, string.Empty };
234
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, 1, null, "text" };
235
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, -1, new ListViewGroup(), "text" };
240
public void ListViewItem_Ctor_ListViewSubItemArray_Int_ListViewGroup(ListViewItem.
ListViewSubItem
[] subItems, int imageIndex, ListViewGroup group, string expectedText)
260
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
298
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
336
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
373
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
411
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
422
yield return new object[] { Array.Empty<ListViewItem.
ListViewSubItem
>(), null, string.Empty, string.Empty };
423
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, string.Empty, string.Empty, "text" };
424
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, "imageKey", "imageKey", "text" };
429
public void ListViewItem_Ctor_ListViewSubItemArray_String(ListViewItem.
ListViewSubItem
[] subItems, string imageKey, string expectedImageKey, string expectedText)
449
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
459
yield return new object[] { Array.Empty<ListViewItem.
ListViewSubItem
>(), 0, string.Empty };
460
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, 1, "text" };
461
yield return new object[] { new ListViewItem.
ListViewSubItem
[] { new(null, "text") }, -1, "text" };
466
public void ListViewItem_Ctor_ListViewSubItemArray_Int(ListViewItem.
ListViewSubItem
[] subItems, int imageIndex, string expectedText)
486
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
524
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
562
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
600
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
637
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
675
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
713
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
750
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
789
AssertEqualListViewSubItem(subItems, item.SubItems.Cast<ListViewItem.
ListViewSubItem
>().ToArray());
819
ListViewItem.
ListViewSubItem
subItem = Assert.Single(item.SubItems.Cast<ListViewItem.
ListViewSubItem
>());
831
Assert.Throws<ArgumentNullException>("subItems", () => new ListViewItem((ListViewItem.
ListViewSubItem
[])null, "imageKey"));
832
Assert.Throws<ArgumentNullException>("subItems", () => new ListViewItem((ListViewItem.
ListViewSubItem
[])null, 1));
833
Assert.Throws<ArgumentNullException>("subItems", () => new ListViewItem((ListViewItem.
ListViewSubItem
[])null, "imageKey", new ListViewGroup()));
834
Assert.Throws<ArgumentNullException>("subItems", () => new ListViewItem((ListViewItem.
ListViewSubItem
[])null, 0, new ListViewGroup()));
840
var subItems = new ListViewItem.
ListViewSubItem
[] { null };
1048
private static void AssertEqualListViewSubItem(string[] expected, ListViewItem.
ListViewSubItem
[] actual)
1053
private static void AssertEqualListViewSubItem(ListViewItem.
ListViewSubItem
[] expected, ListViewItem.
ListViewSubItem
[] actual)
1057
ListViewItem.
ListViewSubItem
subItem = Assert.Single(actual.Cast<ListViewItem.
ListViewSubItem
>());
System\Windows\Forms\ListViewSubItemCollectionTests.cs (80)
44
var
subItem = new ListViewItem.ListViewSubItem();
71
var
subItem = new ListViewItem.ListViewSubItem();
106
var
subItem = new ListViewItem.ListViewSubItem();
133
var
subItem = new ListViewItem.ListViewSubItem();
173
var
subItem1 = new ListViewItem.ListViewSubItem();
174
var
subItem2 = new ListViewItem.ListViewSubItem
189
var
subItem = new ListViewItem.ListViewSubItem();
202
var
subItem = new ListViewItem.ListViewSubItem();
215
var
subItem = new ListViewItem.ListViewSubItem();
232
var
subItem = new ListViewItem.ListViewSubItem();
250
ListViewItem.
ListViewSubItem
subItem = Assert.Single(collection.Cast<ListViewItem.
ListViewSubItem
>());
271
ListViewItem.
ListViewSubItem
subItem = Assert.Single(collection.Cast<ListViewItem.
ListViewSubItem
>());
284
Assert.Throws<ArgumentNullException>("item", () => collection.Add((ListViewItem.
ListViewSubItem
)null));
292
var
subItem = new ListViewItem.ListViewSubItem();
313
var
subItem1 = new ListViewItem.ListViewSubItem(null, "text1");
314
var
subItem2 = new ListViewItem.ListViewSubItem(null, "text2");
315
var items = new ListViewItem.
ListViewSubItem
[] { subItem1, null, subItem2 };
328
var
subItem1 = new ListViewItem.ListViewSubItem(null, "text1");
329
var
subItem2 = new ListViewItem.ListViewSubItem(null, "text2");
330
var
subItem3 = new ListViewItem.ListViewSubItem(null, "text3");
331
var
subItem4 = new ListViewItem.ListViewSubItem(null, "text4");
332
var items = new ListViewItem.
ListViewSubItem
[] { subItem1, null, subItem2, subItem3, subItem4 };
347
var
subItem1 = new ListViewItem.ListViewSubItem(null, "text1");
348
var
subItem2 = new ListViewItem.ListViewSubItem(null, "text2");
349
var
subItem3 = new ListViewItem.ListViewSubItem(null, "text3");
350
var
subItem4 = new ListViewItem.ListViewSubItem(null, "text4");
351
var
subItem5 = new ListViewItem.ListViewSubItem(null, "text5");
352
var
subItem6 = new ListViewItem.ListViewSubItem(null, "text6");
353
var
subItem7 = new ListViewItem.ListViewSubItem(null, "text7");
354
var
subItem8 = new ListViewItem.ListViewSubItem(null, "text8");
355
var
subItem9 = new ListViewItem.ListViewSubItem(null, "text8");
356
var items = new ListViewItem.
ListViewSubItem
[] { subItem2, null, subItem3, subItem4, subItem5, subItem6, subItem7, subItem8, subItem9 };
417
Assert.Throws<ArgumentNullException>("items", () => collection.AddRange((ListViewItem.
ListViewSubItem
[])null));
427
var
subItem = new ListViewItem.ListViewSubItem();
455
var
subItem = new ListViewItem.ListViewSubItem();
485
var
subItem1 = new ListViewItem.ListViewSubItem();
486
var
subItem2 = new ListViewItem.ListViewSubItem
511
var
subItem = new ListViewItem.ListViewSubItem();
536
var
subItem = new ListViewItem.ListViewSubItem();
566
var
subItem1 = new ListViewItem.ListViewSubItem();
567
var
subItem2 = new ListViewItem.ListViewSubItem
596
var
subItem = new ListViewItem.ListViewSubItem();
621
var
subItem = new ListViewItem.ListViewSubItem();
636
var
subItem = new ListViewItem.ListViewSubItem();
670
var
subItem = new ListViewItem.ListViewSubItem();
703
var
subItem = new ListViewItem.ListViewSubItem();
725
var
subItem = new ListViewItem.ListViewSubItem();
745
var
subItem = new ListViewItem.ListViewSubItem();
757
var
subItem1 = new ListViewItem.ListViewSubItem();
758
var
subItem2 = new ListViewItem.ListViewSubItem();
759
var
subItem3 = new ListViewItem.ListViewSubItem();
760
var
subItem4 = new ListViewItem.ListViewSubItem();
834
var
subItem = new ListViewItem.ListViewSubItem
857
var
subItem = new ListViewItem.ListViewSubItem();
879
ListViewItem.
ListViewSubItem
subItem = new();
912
ListViewItem.
ListViewSubItem
subItem1 = new();
913
ListViewItem.
ListViewSubItem
subItem2 = new();
950
ListViewItem.
ListViewSubItem
subItem1 = new();
951
ListViewItem.
ListViewSubItem
subItem2 = new();
952
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
973
ListViewItem.
ListViewSubItem
subItem = new();
986
ListViewItem.
ListViewSubItem
subItem1 = new();
987
ListViewItem.
ListViewSubItem
subItem2 = new();
988
ListViewItem.
ListViewSubItem
oldSubItem1 = listViewItem.SubItems[0];
989
ListViewItem.
ListViewSubItem
oldSubItem2 = new();
1017
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
1018
ListViewItem.
ListViewSubItem
subItem = new();
1036
ListViewItem.
ListViewSubItem
subItem = new();
1037
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
1052
ListViewItem.
ListViewSubItem
subItem1 = new();
1053
ListViewItem.
ListViewSubItem
subItem2 = new();
1054
ListViewItem.
ListViewSubItem
defaultSubItem = listViewItem.SubItems[0];
1074
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
1075
ListViewItem.
ListViewSubItem
subItem = new();
1093
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
1094
ListViewItem.
ListViewSubItem
subItem = new();
1112
ListViewItem.
ListViewSubItem
oldSubItem = listViewItem.SubItems[0];
1114
ListViewItem.
ListViewSubItem
subItem = new(listViewItem, "Test 2") { Name = "Test 2" };
System\Windows\Forms\ListViewSubItemConverterTests.cs (19)
18
[InlineData(typeof(ListViewItem.
ListViewSubItem
), false)]
22
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
32
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
39
[InlineData(typeof(ListViewItem.
ListViewSubItem
), false)]
44
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
68
public void ListViewSubItemConverter_ConvertTo_InstanceDescriptor_ReturnsExpected(ListViewItem.
ListViewSubItem
value, Type[] parameterTypes, object[] arguments)
70
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
72
Assert.Equal(typeof(ListViewItem.
ListViewSubItem
).GetConstructor(parameterTypes), descriptor.MemberInfo);
81
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
88
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
95
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
100
[InlineData(typeof(ListViewItem.
ListViewSubItem
))]
104
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
111
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
118
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
119
var
item = new ListViewItem.ListViewSubItem();
126
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
133
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
140
TypeConverter converter = TypeDescriptor.GetConverter(typeof(ListViewItem.
ListViewSubItem
));
System\Windows\Forms\ListViewSubItemTests.cs (33)
16
var
subItem = new ListViewItem.ListViewSubItem();
42
var
subItem = new ListViewItem.ListViewSubItem(owner, text);
68
var
subItem = new ListViewItem.ListViewSubItem(owner, text, foreColor, backColor, font);
88
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
103
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
123
var
subItem = new ListViewItem.ListViewSubItem();
142
var
subItem = new ListViewItem.ListViewSubItem
172
var
subItem = new ListViewItem.ListViewSubItem();
191
var
subItem = new ListViewItem.ListViewSubItem();
210
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
224
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
239
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
260
var
subItem = new ListViewItem.ListViewSubItem();
273
var
subItem = new ListViewItem.ListViewSubItem
297
var
subItem = new ListViewItem.ListViewSubItem();
316
var
subItem = new ListViewItem.ListViewSubItem();
337
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
352
var
subItem = new ListViewItem.ListViewSubItem(item, "text");
372
var
subItem = new ListViewItem.ListViewSubItem();
393
var
subItem = new ListViewItem.ListViewSubItem
423
var
subItem = new ListViewItem.ListViewSubItem();
442
var
subItem = new ListViewItem.ListViewSubItem();
458
var
subItem = new ListViewItem.ListViewSubItem(item, "text")
473
var
subItem = new ListViewItem.ListViewSubItem
488
var
subItem = new ListViewItem.ListViewSubItem
504
var
subItem = new ListViewItem.ListViewSubItem(item, "text")
519
var
subItem = new ListViewItem.ListViewSubItem
540
var
subItem = new ListViewItem.ListViewSubItem(owner, "text");
556
var
subItem = new ListViewItem.ListViewSubItem(owner, "text", Color.Red, Color.Blue, SystemFonts.MenuFont);
577
public void ListViewSubItem_Serialize_Deserialize_Success(ListViewItem.
ListViewSubItem
subItem)
588
ListViewItem.
ListViewSubItem
result = Assert.IsType<ListViewItem.
ListViewSubItem
>(formatter.Deserialize(stream)); // CodeQL[SM03722] : Testing legacy feature. This is a safe use of BinaryFormatter because the data is trusted and the types are controlled and validated.
602
var
subItem = new ListViewItem.ListViewSubItem(null, text);