115 references to ItemContainerGenerator
PresentationFramework (96)
src\Framework\System\Windows\Automation\Peers\ComboBoxAutomationPeer.cs (1)
127
if (owner.
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
src\Framework\System\Windows\Automation\Peers\GridViewAutomationPeer.cs (2)
211
ListViewItem lvi = _listview.
ItemContainerGenerator
.ContainerFromIndex(row) as ListViewItem;
221
lvi = _listview.
ItemContainerGenerator
.ContainerFromIndex(row) as ListViewItem;
src\Framework\System\Windows\Automation\Peers\GridViewItemAutomationPeer.cs (1)
51
ListViewItem lvi = listview.
ItemContainerGenerator
.ContainerFromItem(item) as ListViewItem;
src\Framework\System\Windows\Automation\Peers\GroupItemAutomationPeer.cs (2)
204
object item = itemsControl.
ItemContainerGenerator
.ItemFromContainer(child);
290
CollectionViewGroupInternal cvg = itemsControl.
ItemContainerGenerator
.ItemFromContainer(Owner) as CollectionViewGroupInternal;
src\Framework\System\Windows\Automation\Peers\ItemAutomationPeer.cs (2)
104
wrapper = owner.
ItemContainerGenerator
.ContainerFromItem(item) as UIElement;
699
if (parent.
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
src\Framework\System\Windows\Automation\Peers\ItemsControlAutomationPeer.cs (2)
162
dataItem = (d != null) ? owner.
ItemContainerGenerator
.ItemFromContainer(d) : null;
782
((IItemContainerGenerator)_itemsControl.
ItemContainerGenerator
).PrepareItemContainer(_container);
src\Framework\System\Windows\Automation\Peers\MenuItemAutomationPeer.cs (1)
163
UIElement uiElement = owner.
ItemContainerGenerator
.ContainerFromIndex(i) as UIElement;
src\Framework\System\Windows\Automation\Peers\StatusBarAutomationPeer.cs (1)
55
StatusBarItem item = itemscontrol.
ItemContainerGenerator
.ContainerFromItem(obj) as StatusBarItem;
src\Framework\System\Windows\Automation\Peers\TreeViewAutomationPeer.cs (1)
83
TreeViewItem treeViewItem = owner.
ItemContainerGenerator
.ContainerFromIndex(i) as TreeViewItem;
src\Framework\System\Windows\Automation\Peers\TreeViewDataItemAutomationPeer.cs (1)
322
if (parent.
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
src\Framework\System\Windows\Controls\ComboBox.cs (2)
1264
object item =
ItemContainerGenerator
.ItemFromContainer(comboBoxItem);
1583
DependencyObject container =
ItemContainerGenerator
.ContainerFromIndex(i);
src\Framework\System\Windows\Controls\DataGrid.cs (16)
456
if (ColumnHeadersPresenter != null && ColumnHeadersPresenter.
ItemContainerGenerator
!= null)
458
return (DataGridColumnHeader)ColumnHeadersPresenter.
ItemContainerGenerator
.ContainerFromIndex(columnIndex);
618
foreach (DependencyObject container in
ItemContainerGenerator
.RecyclableContainers)
1307
var row = (DataGridRow)
ItemContainerGenerator
.ContainerFromItem(item);
1327
var row = (DataGridRow)
ItemContainerGenerator
.ContainerFromItem(item);
1353
var row = (DataGridRow)
ItemContainerGenerator
.ContainerFromItem(item);
1554
if (
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
1591
if (
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
1817
DataGridRow row = (DataGridRow)
ItemContainerGenerator
.ContainerFromIndex(info.Index);
2158
newItemIndex =
ItemContainerGenerator
.IndexFromContainer(cell.RowOwner);
3104
(currentIndex < 0 || currentIndex ==
ItemContainerGenerator
.IndexFromContainer(row))
3816
DataGridRow newItemPlaceholderRow = (DataGridRow)
ItemContainerGenerator
.ContainerFromItem(CollectionView.NewItemPlaceholder);
5636
CollectionViewGroupInternal cvg =
ItemContainerGenerator
.ItemFromContainer(currentGroupItem) as CollectionViewGroupInternal;
6438
row =
ItemContainerGenerator
.ContainerFromIndex(i) as DataGridRow;
6487
row =
ItemContainerGenerator
.ContainerFromIndex(i) as DataGridRow;
7057
DataGridRow row = (DataGridRow)
ItemContainerGenerator
.ContainerFromItem(item);
src\Framework\System\Windows\Controls\DataGridCell.cs (1)
81
PrepareCell(item, ownerRow, cellsPresenter.
ItemContainerGenerator
.IndexFromContainer(this));
src\Framework\System\Windows\Controls\DataGridCellsPanel.cs (2)
894
ItemContainerGenerator generator = parentPresenter.
ItemContainerGenerator
;
1793
IItemContainerGenerator generator = parentPresenter.
ItemContainerGenerator
as IItemContainerGenerator;
src\Framework\System\Windows\Controls\DataGridColumn.cs (1)
626
DataGridRow row = _dataGridOwner.
ItemContainerGenerator
.ContainerFromItem(dataItem) as DataGridRow;
src\Framework\System\Windows\Controls\DataGridRow.cs (2)
1320
return dataGridOwner.
ItemContainerGenerator
.IndexFromContainer(this);
1363
return cellsPresenter.
ItemContainerGenerator
.ContainerFromIndex(index) as DataGridCell;
src\Framework\System\Windows\Controls\GroupItem.cs (1)
69
Helper.SetItemValuesOnContainer(itemsControl, _expander, itemsControl.
ItemContainerGenerator
.ItemFromContainer(this));
src\Framework\System\Windows\Controls\ItemsControl.cs (19)
905
ItemContainerGenerator
.OnPanelChanged();
1078
ItemContainerGenerator
.ChangeAlternationCount();
2612
FrameworkElement container =
ItemContainerGenerator
.ContainerFromIndex(startIndex) as FrameworkElement;
2680
container =
ItemContainerGenerator
.ContainerFromIndex(index) as FrameworkElement;
2690
container =
ItemContainerGenerator
.ContainerFromIndex(index) as FrameworkElement;
2776
object firstItem = GetFirstItemOnCurrentPage(
ItemContainerGenerator
.ContainerFromItem(startingItem) as FrameworkElement,
2931
FrameworkElement container =
ItemContainerGenerator
.ContainerFromItem(item) as FrameworkElement;
3140
object item = itemsControl.
ItemContainerGenerator
.ItemFromContainer(focusedElement);
3383
item = itemsControl.
ItemContainerGenerator
.ItemFromContainer(element);
3474
object item =
ItemContainerGenerator
.ItemFromContainer(container);
3513
return new ItemInfo(item, container, index).Refresh(
ItemContainerGenerator
);
3519
return NewItemInfo(
ItemContainerGenerator
.ItemFromContainer(container), container,
ItemContainerGenerator
.IndexFromContainer(container));
3525
return (index >= 0) ? NewItemInfo(Items[index],
ItemContainerGenerator
.ContainerFromIndex(index), index)
3543
container =
ItemContainerGenerator
.ContainerFromIndex(info.Index);
3548
container =
ItemContainerGenerator
.ContainerFromItem(info.Item);
3615
container =
ItemContainerGenerator
.ContainerFromIndex(index);
3621
ItemContainerGenerator
.FindItem(
3754
info.Refresh(
ItemContainerGenerator
);
src\Framework\System\Windows\Controls\ItemsPresenter.cs (1)
218
generator = owner.
ItemContainerGenerator
;
src\Framework\System\Windows\Controls\ListBox.cs (3)
125
if (
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
905
return
ItemContainerGenerator
.IndexFromContainer(listItem);
910
return
ItemContainerGenerator
.ContainerFromIndex(index) as ListBoxItem;
src\Framework\System\Windows\Controls\ListView.cs (1)
265
ItemContainerGenerator
.Refresh();
src\Framework\System\Windows\Controls\Menu.cs (1)
380
MenuItem menuItem =
ItemContainerGenerator
.ContainerFromIndex(i) as MenuItem;
src\Framework\System\Windows\Controls\MenuItem.cs (2)
372
object originalItem = parent.
ItemContainerGenerator
.ItemFromContainer(menuItem);
630
MenuItem subItem = menuItem.
ItemContainerGenerator
.ContainerFromIndex(i) as MenuItem;
src\Framework\System\Windows\Controls\Panel.cs (2)
267
IItemContainerGenerator generator = itemsControl.
ItemContainerGenerator
as IItemContainerGenerator;
589
IItemContainerGenerator itemsOwnerGenerator = itemsOwner.
ItemContainerGenerator
;
src\Framework\System\Windows\Controls\Primitives\DataGridCellsPresenter.cs (2)
167
cell = (DataGridCell)
ItemContainerGenerator
.ContainerFromIndex(i);
185
cell = (DataGridCell)
ItemContainerGenerator
.ContainerFromIndex(i);
src\Framework\System\Windows\Controls\Primitives\DataGridColumnHeadersPresenter.cs (1)
270
int index =
ItemContainerGenerator
.IndexFromContainer(container);
src\Framework\System\Windows\Controls\Primitives\DataGridRowHeader.cs (2)
695
int index = dataGrid.
ItemContainerGenerator
.IndexFromContainer(row);
698
return (DataGridRow)dataGrid.
ItemContainerGenerator
.ContainerFromIndex(index - 1);
src\Framework\System\Windows\Controls\Primitives\DataGridRowsPresenter.cs (1)
60
IItemContainerGenerator generator = dataGrid.
ItemContainerGenerator
as IItemContainerGenerator;
src\Framework\System\Windows\Controls\Primitives\MenuBase.cs (1)
708
MenuItem mi = menu.
ItemContainerGenerator
.ContainerFromIndex(i) as MenuItem;
src\Framework\System\Windows\Controls\Primitives\Selector.cs (3)
56
ItemContainerGenerator
.StatusChanged += new EventHandler(OnGeneratorStatusChanged);
1509
if (
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
1899
object data = itemsControl.
ItemContainerGenerator
.ItemFromContainer(o);
src\Framework\System\Windows\Controls\TabControl.cs (9)
93
TabItem ti = tc.
ItemContainerGenerator
.ContainerFromIndex(i) as TabItem;
328
ItemContainerGenerator
.StatusChanged += new EventHandler(OnGeneratorStatusChanged);
430
startIndex =
ItemContainerGenerator
.IndexFromContainer(
ItemContainerGenerator
.ContainerFromItem(SelectedItem));
472
TabItem tabItem =
ItemContainerGenerator
.ContainerFromIndex(index) as TabItem;
511
if (
ItemContainerGenerator
.Status == GeneratorStatus.ContainersGenerated)
532
tabItem =
ItemContainerGenerator
.ContainerFromIndex(SelectedIndex) as TabItem;
538
!ItemsControl.EqualsEx(selectedItem,
ItemContainerGenerator
.ItemFromContainer(tabItem)))
540
tabItem =
ItemContainerGenerator
.ContainerFromItem(selectedItem) as TabItem;
src\Framework\System\Windows\Controls\TreeView.cs (2)
356
ChangeSelection(collapsed.ParentItemsControl.
ItemContainerGenerator
.ItemFromContainer(collapsed), collapsed, true);
469
container =
ItemContainerGenerator
.ContainerFromIndex(0) as TreeViewItem;
src\Framework\System\Windows\Controls\TreeViewItem.cs (3)
936
ItemContainerGenerator
.RemoveAllInternal(true /*saveRecycleQueue*/);
1047
subitem = (TreeViewItem)item.
ItemContainerGenerator
.ContainerFromIndex(i);
1051
subitem = (TreeViewItem)item.
ItemContainerGenerator
.ContainerFromIndex(i);
src\Framework\System\Windows\Controls\VirtualizingStackPanel.cs (4)
4101
parentItem = itemsControl.
ItemContainerGenerator
.ItemFromContainer(groupItem);
4108
parentItem = parentItemsControl.
ItemContainerGenerator
.ItemFromContainer(itemsControl);
8972
item = itemsControl.
ItemContainerGenerator
.ItemFromContainer(child);
9299
CleanUpVirtualizedItemEventArgs e = new CleanUpVirtualizedItemEventArgs(itemsControl.
ItemContainerGenerator
.ItemFromContainer(child), child);
System.Activities.Presentation (19)
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Automation\CategoryContainerAutomationPeer.cs (1)
148
PropertyContainer propertyContainer = properties.
ItemContainerGenerator
.ContainerFromIndex(i) as PropertyContainer;
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Automation\CategoryListAutomationPeer.cs (1)
57
_control.
ItemContainerGenerator
.ContainerFromItem(item) as CiderCategoryContainer,
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Automation\SubPropertyEditorAutomationPeer.cs (1)
111
PropertyContainer propertyContainer = properties.
ItemContainerGenerator
.ContainerFromIndex(i) as PropertyContainer;
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\CategoryList.cs (3)
852
CiderCategoryContainer categoryContainer = this.
ItemContainerGenerator
.ContainerFromItem(parentCategory) as CiderCategoryContainer;
897
CiderCategoryContainer categoryContainer = this.
ItemContainerGenerator
.ContainerFromItem(category) as CiderCategoryContainer;
922
CiderCategoryContainer categoryContainer = this.
ItemContainerGenerator
.ContainerFromItem(category) as CiderCategoryContainer;
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\CiderCategoryContainer.cs (4)
237
PropertyContainer propertyContainer = this.BasicPropertyContainersContainer.
ItemContainerGenerator
.ContainerFromItem(property) as PropertyContainer;
246
PropertyContainer propertyContainer = this.AdvancedPropertyContainersContainer.
ItemContainerGenerator
.ContainerFromItem(property) as PropertyContainer;
278
UIElement categoryEditor = this.BasicCategoryEditorsContainer.
ItemContainerGenerator
.ContainerFromItem(editor) as UIElement;
287
UIElement categoryEditor = this.AdvancedCategoryEditorsContainer.
ItemContainerGenerator
.ContainerFromItem(editor) as UIElement;
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Editors\FlagEditor.xaml.cs (1)
104
this.
ItemContainerGenerator
.ContainerFromIndex(0) as ComboBoxItem;
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Editors\SubPropertyEditor.cs (1)
429
return subPropertyListControl.
ItemContainerGenerator
.ContainerFromItem(property) as PropertyContainer;
System.Activities.Presentation\System\Activities\Presentation\View\DataGridHelper.cs (5)
716
dataGrid.SelectedItems.Add(dataGrid.
ItemContainerGenerator
.ItemFromContainer(row));
1000
DataGridCell cell = (DataGridCell)presenter.
ItemContainerGenerator
.ContainerFromIndex(column);
1006
cell = (DataGridCell)presenter.
ItemContainerGenerator
.ContainerFromIndex(column);
1043
DataGridRow row = (DataGridRow)dataGrid.
ItemContainerGenerator
.ContainerFromIndex(index);
1050
row = (DataGridRow)dataGrid.
ItemContainerGenerator
.ContainerFromIndex(index);
System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.xaml.cs (2)
941
UIElement first = (UIElement)breadcrumbItems.
ItemContainerGenerator
.ContainerFromIndex(0);
943
UIElement last = (UIElement)breadcrumbItems.
ItemContainerGenerator
.ContainerFromIndex(breadcrumbItems.Items.Count - 1);