78 references to ContainerFromIndex
Microsoft.VisualStudio.LanguageServices (4)
ChangeSignature\ChangeSignatureDialog.xaml.cs (2)
207if (Members.ItemContainerGenerator.ContainerFromIndex(Members.SelectedIndex) is not DataGridRow row) 210row = Members.ItemContainerGenerator.ContainerFromIndex(Members.SelectedIndex) as DataGridRow;
PickMembers\PickMembersDialog.xaml.cs (2)
111if (Members.ItemContainerGenerator.ContainerFromIndex(Members.SelectedIndex) is not ListViewItem row) 114row = Members.ItemContainerGenerator.ContainerFromIndex(Members.SelectedIndex) as ListViewItem;
PresentationFramework (32)
System\Windows\Automation\Peers\GridViewAutomationPeer.cs (2)
199ListViewItem lvi = _listview.ItemContainerGenerator.ContainerFromIndex(row) as ListViewItem; 209lvi = _listview.ItemContainerGenerator.ContainerFromIndex(row) as ListViewItem;
System\Windows\Automation\Peers\MenuItemAutomationPeer.cs (1)
175UIElement uiElement = owner.ItemContainerGenerator.ContainerFromIndex(i) as UIElement;
System\Windows\Automation\Peers\TreeViewAutomationPeer.cs (1)
73TreeViewItem treeViewItem = owner.ItemContainerGenerator.ContainerFromIndex(i) as TreeViewItem;
System\Windows\Controls\ComboBox.cs (1)
1571DependencyObject container = ItemContainerGenerator.ContainerFromIndex(i);
System\Windows\Controls\DataGrid.cs (4)
454return (DataGridColumnHeader)ColumnHeadersPresenter.ItemContainerGenerator.ContainerFromIndex(columnIndex); 1810DataGridRow row = (DataGridRow)ItemContainerGenerator.ContainerFromIndex(info.Index); 6430row = ItemContainerGenerator.ContainerFromIndex(i) as DataGridRow; 6479row = ItemContainerGenerator.ContainerFromIndex(i) as DataGridRow;
System\Windows\Controls\DataGridCellsPanel.cs (1)
966UIElement child = generator.ContainerFromIndex(columnIndex) as UIElement;
System\Windows\Controls\DataGridRow.cs (1)
1358return cellsPresenter.ItemContainerGenerator.ContainerFromIndex(index) as DataGridCell;
System\Windows\Controls\ItemContainerGenerator.cs (1)
926container = groupItem.Generator.ContainerFromIndex(subIndex);
System\Windows\Controls\ItemsControl.cs (7)
2600FrameworkElement container = ItemContainerGenerator.ContainerFromIndex(startIndex) as FrameworkElement; 2668container = ItemContainerGenerator.ContainerFromIndex(index) as FrameworkElement; 2678container = ItemContainerGenerator.ContainerFromIndex(index) as FrameworkElement; 3585return (index >= 0) ? NewItemInfo(Items[index], ItemContainerGenerator.ContainerFromIndex(index), index) 3603container = ItemContainerGenerator.ContainerFromIndex(info.Index); 3675container = ItemContainerGenerator.ContainerFromIndex(index); 3937Container = generator.ContainerFromIndex(Index);
System\Windows\Controls\ListBox.cs (1)
947return ItemContainerGenerator.ContainerFromIndex(index) as ListBoxItem;
System\Windows\Controls\Menu.cs (1)
344MenuItem menuItem = ItemContainerGenerator.ContainerFromIndex(i) as MenuItem;
System\Windows\Controls\MenuItem.cs (1)
625MenuItem subItem = menuItem.ItemContainerGenerator.ContainerFromIndex(i) as MenuItem;
System\Windows\Controls\Primitives\DataGridCellsPresenter.cs (2)
161cell = (DataGridCell)ItemContainerGenerator.ContainerFromIndex(i); 179cell = (DataGridCell)ItemContainerGenerator.ContainerFromIndex(i);
System\Windows\Controls\Primitives\DataGridRowHeader.cs (1)
692return (DataGridRow)dataGrid.ItemContainerGenerator.ContainerFromIndex(index - 1);
System\Windows\Controls\Primitives\MenuBase.cs (1)
688MenuItem mi = menu.ItemContainerGenerator.ContainerFromIndex(i) as MenuItem;
System\Windows\Controls\TabControl.cs (3)
82TabItem ti = tc.ItemContainerGenerator.ContainerFromIndex(i) as TabItem; 461TabItem tabItem = ItemContainerGenerator.ContainerFromIndex(index) as TabItem; 521tabItem = ItemContainerGenerator.ContainerFromIndex(SelectedIndex) as TabItem;
System\Windows\Controls\TreeView.cs (1)
463container = ItemContainerGenerator.ContainerFromIndex(0) as TreeViewItem;
System\Windows\Controls\TreeViewItem.cs (2)
1043subitem = (TreeViewItem)item.ItemContainerGenerator.ContainerFromIndex(i); 1047subitem = (TreeViewItem)item.ItemContainerGenerator.ContainerFromIndex(i);
System.Windows.Controls.Ribbon (42)
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonTabHeadersPanel.cs (1)
724RibbonContextualTabGroup groupHeader = groupHeaderItemsControl.ItemContainerGenerator.ContainerFromIndex(i) as RibbonContextualTabGroup;
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (7)
1504RibbonTab ribbonTab = ribbon.ItemContainerGenerator.ContainerFromIndex(i) as RibbonTab; 1565RibbonTab tab = ItemContainerGenerator.ContainerFromIndex(i) as RibbonTab; 1675RibbonTab tab = ItemContainerGenerator.ContainerFromIndex(i) as RibbonTab; 1904selectedTab = ItemContainerGenerator.ContainerFromIndex(selectedIndex) as RibbonTab; 1950return (tabHeaderItemsControl.ItemContainerGenerator.ContainerFromIndex(selectedIndex) as RibbonTabHeader); 2008RibbonGroup group = tab.ItemContainerGenerator.ContainerFromIndex(index) as RibbonGroup; 2052RibbonControl ribbonControl = quickAccessToolBar.ItemContainerGenerator.ContainerFromIndex(index) as RibbonControl;
Microsoft\Windows\Controls\Ribbon\RibbonContextualTabGroup.cs (2)
460RibbonTab tab = Ribbon.ItemContainerGenerator.ContainerFromIndex(i) as RibbonTab; 524RibbonTab tab = ribbon.ItemContainerGenerator.ContainerFromIndex(i) as RibbonTab;
Microsoft\Windows\Controls\Ribbon\RibbonContextualTabGroupItemsControl.cs (1)
259RibbonContextualTabGroup tabGroup = this.ItemContainerGenerator.ContainerFromIndex(i) as RibbonContextualTabGroup;
Microsoft\Windows\Controls\Ribbon\RibbonControlGroup.cs (2)
87DependencyObject child = ItemContainerGenerator.ContainerFromIndex(i); 109RibbonControl ribbonControl = controlGroup.ItemContainerGenerator.ContainerFromIndex(i) as RibbonControl;
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (9)
595RibbonGalleryCategory category = (RibbonGalleryCategory)ItemContainerGenerator.ContainerFromIndex(i); 976RibbonGalleryCategory category = ItemContainerGenerator.ContainerFromIndex(i) as RibbonGalleryCategory; 1400galleryItem = category.ItemContainerGenerator.ContainerFromIndex(index) as RibbonGalleryItem; 1443galleryItem = category.ItemContainerGenerator.ContainerFromIndex(index) as RibbonGalleryItem; 2156RibbonGalleryItem galleryItem = category.ItemContainerGenerator.ContainerFromIndex(index) as RibbonGalleryItem; 2221RibbonGalleryItem galleryItem = category.ItemContainerGenerator.ContainerFromIndex(index) as RibbonGalleryItem; 2332category = (RibbonGalleryCategory)this.ItemContainerGenerator.ContainerFromIndex(i); 2369category = (RibbonGalleryCategory)gallery.ItemContainerGenerator.ContainerFromIndex(i); 2532RibbonGalleryCategory category = (RibbonGalleryCategory)gallery.ItemContainerGenerator.ContainerFromIndex(index);
Microsoft\Windows\Controls\Ribbon\RibbonGroup.cs (2)
860RibbonControl ribbonControl = ItemContainerGenerator.ContainerFromIndex(i) as RibbonControl; 1219DependencyObject d = ItemContainerGenerator.ContainerFromIndex(i);
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (9)
567FrameworkElement container = itemsControl.ItemContainerGenerator.ContainerFromIndex(startIndex) as FrameworkElement; 573container = itemsControl.ItemContainerGenerator.ContainerFromIndex(startIndex) as FrameworkElement; 770category = gallery.Items.Count > 0 ? gallery.ItemContainerGenerator.ContainerFromIndex(0) as RibbonGalleryCategory : null; 771galleryItem = category != null && category.Items.Count > 0 ? category.ItemContainerGenerator.ContainerFromIndex(0) as RibbonGalleryItem : null; 794category = gallery.ItemContainerGenerator.ContainerFromIndex(catIndex) as RibbonGalleryCategory; 818highlightedGalleryItem = category.ItemContainerGenerator.ContainerFromIndex(startItemIndex) as RibbonGalleryItem; 847highlightedGalleryItem = category.ItemContainerGenerator.ContainerFromIndex(startItemIndex) as RibbonGalleryItem; 885highlightedGalleryItem = category.ItemContainerGenerator.ContainerFromIndex(itemIndex) as RibbonGalleryItem; 2499UIElement container = parentItemsControl.ItemContainerGenerator.ContainerFromIndex(i) as UIElement;
Microsoft\Windows\Controls\Ribbon\RibbonQuickAccessToolBar.cs (2)
586RibbonControl ribbonControl = QuickAccessToolBar.ItemContainerGenerator.ContainerFromIndex(i) as RibbonControl; 612RibbonControl ribbonControl = QuickAccessToolBar.ItemContainerGenerator.ContainerFromIndex(i) as RibbonControl;
Microsoft\Windows\Controls\Ribbon\RibbonTab.cs (4)
191return headerItemsControl.ItemContainerGenerator.ContainerFromIndex(index) as RibbonTabHeader; 435nextRibbonGroup = ItemContainerGenerator.ContainerFromIndex(nextGroupIndex) as RibbonGroup; 563RibbonGroup group = ItemContainerGenerator.ContainerFromIndex((_groupAutoResizeIndex--).Value) as RibbonGroup; 788RibbonGroup group = ItemContainerGenerator.ContainerFromIndex(i) as RibbonGroup;
Microsoft\Windows\Controls\Ribbon\RibbonTabHeader.cs (1)
128return ribbon.ItemContainerGenerator.ContainerFromIndex(index) as RibbonTab;
Microsoft\Windows\Controls\Ribbon\RibbonTabHeaderItemsControl.cs (1)
159FrameworkElement element = ItemContainerGenerator.ContainerFromIndex(index) as FrameworkElement;
Microsoft\Windows\Controls\TextSearchInternal.cs (1)
142ItemsControl childItemsControl = _attachedTo.ItemContainerGenerator.ContainerFromIndex(currentIndex) as ItemsControl;