74 references to Index
System.Windows.Forms (50)
System\Windows\Forms\Controls\ListView\ListView.cs (12)
1752EnsureVisible(value.Index); 1765Scroll(0, value.Index); 1771if (topItem is null || value.Index == topItem.Index) 1778Scroll(topItem.Index, value.Index); 3238Rectangle iconBounds = GetItemRect(lvi.Index, ItemBoundsPortion.Icon); 3950item.UpdateStateToListView(item.Index); 3964iItem = item.Index, 4315SetItemImage(item.Index, imageIndex); 4324SetItemText(item.Index, 0 /*subItemIndex*/, item.Text); 5081item.UpdateStateToListView(item.Index);
System\Windows\Forms\Controls\ListView\ListView.SelectedIndexCollection.cs (2)
81indices[i] = _owner._savedSelectedItems[i].Index; 119return _owner._savedSelectedItems[index].Index;
System\Windows\Forms\Controls\ListView\ListViewGroupCollection.cs (1)
273item.UpdateStateToListView(item.Index);
System\Windows\Forms\Controls\ListView\ListViewGroupItemCollection.cs (1)
127item.UpdateStateToListView(item.Index);
System\Windows\Forms\Controls\ListView\ListViewItem.cs (21)
312return _listView.GetItemRect(Index); 364return _listView.GetItemState(Index, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_FOCUSED) != 0; 374_listView.SetItemState(Index, value ? LIST_VIEW_ITEM_STATE_FLAGS.LVIS_FOCUSED : 0, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_FOCUSED); 489_listView.SetItemImage(itemIndex: Index, imageIndex: ImageIndexer.ActualIndex); 515_listView.SetItemImage(Index, ImageIndexer.ActualIndex); 561_listView.SetItemIndentCount(Index, _indentCount); 632_position = _listView.GetItemPosition(Index); 646_listView.SetItemPosition(Index, _position.X, _position.Y); 687return _listView.GetItemState(Index, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_SELECTED) != 0; 696_listView.SetItemState(Index, value ? LIST_VIEW_ITEM_STATE_FLAGS.LVIS_SELECTED : 0, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_SELECTED); 699_listView.SetSelectionMark(Index); 727LIST_VIEW_ITEM_STATE_FLAGS state = _listView.GetItemState(Index, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_STATEIMAGEMASK); 742_listView.SetItemState(Index, state, LIST_VIEW_ITEM_STATE_FLAGS.LVIS_STATEIMAGEMASK); 867if (Index >= 0) 880PInvokeCore.SendMessage(lv, PInvoke.LVM_EDITLABELW, (WPARAM)Index); 949_listView.EnsureVisible(Index); 970return _listView.GetItemRect(Index, portion); 981if (iItem == Index && iSubItem != -1 && iSubItem < SubItems.Count) 1067index = Index; 1158internal void UnHost(bool checkSelection) => UnHost(Index, checkSelection); 1328int itemIndex = Index;
System\Windows\Forms\Controls\ListView\ListViewItem.IKeyboardToolTip.cs (6)
20Rectangle IKeyboardToolTip.GetNativeScreenRectangle() => GetNativeRectangle(Index); 40neighboringRectangles.Add(GetNativeRectangle(neighboringItem.Index)); 48if (Index > 0) 50neighboringRectangles.Add(_listView.Items[Index - 1].AccessibilityObject.Bounds); 53if (Index < _listView.Items.Count - 1) 55neighboringRectangles.Add(_listView.Items[Index + 1].AccessibilityObject.Bounds);
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemBaseAccessibleObject.cs (2)
49=> _owningItem.Index; 86if (_owningListView.SelectedIndices.Contains(_owningItem.Index))
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemDetailsAccessibleObject.cs (1)
179? _owningListView.GetSubItemRect(_owningItem.Index, HasImage ? accessibleChildIndex - 1 : accessibleChildIndex)
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemImageAccessibleObject.cs (1)
54internal Rectangle GetImageRectangle() => _owningItem.ListView!.GetItemRect(_owningItem.Index, ItemBoundsPortion.Icon);
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemTileAccessibleObject.cs (1)
126? _owningListView.GetSubItemRect(_owningItem.Index, subItemIndex)
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItem.cs (1)
101return _owner._listView.GetSubItemRect(_owner.Index, _owner.SubItems.IndexOf(this));
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObject.cs (1)
139internal override int Row => _owningItem.Index;
System.Windows.Forms.Tests (24)
SerializableTypesTests.cs (1)
197Assert.Equal(-1, result.Index);
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewItemBaseAccessibleObjectTests.cs (1)
50Assert.Equal(item.Index, accessibleObject.CurrentIndex);
System\Windows\Forms\ListViewItemTests.cs (22)
27Assert.Equal(-1, item.Index); 66Assert.Equal(-1, item.Index); 104Assert.Equal(-1, item.Index); 142Assert.Equal(-1, item.Index); 180Assert.Equal(-1, item.Index); 217Assert.Equal(-1, item.Index); 254Assert.Equal(-1, item.Index); 292Assert.Equal(-1, item.Index); 330Assert.Equal(-1, item.Index); 367Assert.Equal(-1, item.Index); 405Assert.Equal(-1, item.Index); 443Assert.Equal(-1, item.Index); 480Assert.Equal(-1, item.Index); 518Assert.Equal(-1, item.Index); 556Assert.Equal(-1, item.Index); 594Assert.Equal(-1, item.Index); 631Assert.Equal(-1, item.Index); 669Assert.Equal(-1, item.Index); 707Assert.Equal(-1, item.Index); 744Assert.Equal(-1, item.Index); 783Assert.Equal(-1, item.Index); 813Assert.Equal(-1, item.Index);