67 references to _selectedItems
PresentationFramework (67)
System\Windows\Automation\Peers\SelectorAutomationPeer.cs (4)
99
int count = owner.
_selectedItems
.Count;
108
SelectorItemAutomationPeer peer = FindOrCreateItemAutomationPeer(owner.
_selectedItems
[i].Item) as SelectorItemAutomationPeer;
156
int numSelected = owner.
_selectedItems
.Count;
161
SelectorItemAutomationPeer peer = FindOrCreateItemAutomationPeer(owner.
_selectedItems
[0].Item) as SelectorItemAutomationPeer;
System\Windows\Automation\Peers\SelectorItemAutomationPeer.cs (1)
108
return parentSelector.
_selectedItems
.Contains(parentSelector.NewItemInfo(Item));
System\Windows\Controls\DataGrid.cs (4)
4881
int numItemsSelected =
_selectedItems
.Count;
4890
ItemInfo itemInfo =
_selectedItems
[index];
4931
ItemInfo itemInfo =
_selectedItems
[index];
4976
if (minimalModify &&
_selectedItems
.Contains(info))
System\Windows\Controls\ListBox.cs (5)
825
if (
_selectedItems
.Count > 0)
828
AnchorItemInternal =
_selectedItems
[
_selectedItems
.Count - 1];
869
for (int index = 0; index <
_selectedItems
.Count; index++)
871
ItemInfo info =
_selectedItems
[index];
System\Windows\Controls\Primitives\Selector.cs (51)
899
for (int i = 0; i <
_selectedItems
.Count; i++)
901
SelectionChange.Unselect(
_selectedItems
[i]);
961
if (!value && (
_selectedItems
.Count > 1))
1077
foreach (ItemInfo info in
_selectedItems
)
1239
if (!
_selectedItems
.Contains(info))
1264
AdjustItemInfos(e,
_selectedItems
);
1283
if (
_selectedItems
.Contains(info))
1509
Debug.Assert(!((SelectedIndex >= 0) && (
_selectedItems
.Count == 0)), "SelectedIndex >= 0 implies _selectedItems nonempty");
1516
for (int i = 0; i <
_selectedItems
.Count; i++)
1519
ItemSetIsSelected(
_selectedItems
[i], true);
1531
AdjustItemInfosAfterGeneratorChange(
_selectedItems
, claimUniqueContainer:true);
1571
if (
_selectedItems
.Count == 0)
1578
int index =
_selectedItems
[0].Index;
1614
toAdd.UsesItemHashCodes =
_selectedItems
.UsesItemHashCodes;
1615
toRemove.UsesItemHashCodes =
_selectedItems
.UsesItemHashCodes;
1629
foreach (ItemInfo e in
_selectedItems
)
1722
|| (selectedIndex == -1 &&
_selectedItems
.Count > 0)
1724
&& (
_selectedItems
.Count == 0 || selectedIndex !=
_selectedItems
[0].Index)))
1749
if (
_selectedItems
.Count > 0)
1960
_selectedItems
.UsesItemHashCodes = Items.CollectionView.HasReliableHashCodes();
1971
List<int> knownIndices = new List<int>(
_selectedItems
.Count);
1976
foreach (ItemInfo info in
_selectedItems
)
2006
ItemInfo info =
_selectedItems
.FindMatch(key);
2053
foreach (ItemInfo info in
_selectedItems
)
2136
return (
_selectedItems
.Count == 0) ? null :
_selectedItems
[0].Item;
2142
get { return (
_selectedItems
.Count == 0) ? null :
_selectedItems
[0]; }
2153
if (
_selectedItems
.Count == 0)
2156
int index =
_selectedItems
[0].Index;
2159
index = Items.IndexOf(
_selectedItems
[0].Item);
2160
_selectedItems
[0].Index = index;
2334
_toUnselect = new InternalSelectedItemsStorage(_owner.
_selectedItems
);
2339
if (_owner.
_selectedItems
.Count > 1 && _owner.
_selectedItems
.Count != _toUnselect.Count + 1)
2342
ItemInfo selectedItem = _owner.
_selectedItems
[0];
2345
foreach (ItemInfo info in _owner.
_selectedItems
)
2375
using (_owner.
_selectedItems
.DeferRemove())
2384
if (_owner.
_selectedItems
.Remove(info))
2400
ItemInfo match = _owner.
_selectedItems
.FindMatch(ItemInfo.Key(info));
2404
_owner.
_selectedItems
.Remove(match);
2426
if (!_owner.
_selectedItems
.Contains(info))
2428
_owner.
_selectedItems
.Add(info);
2460
if (_toSelect.Contains(key) && !_owner.
_selectedItems
.Contains(info))
2463
_owner.
_selectedItems
.Add(info);
2533
if (_owner.
_selectedItems
.Contains(info)) return false;
2577
if (!_owner.
_selectedItems
.Contains(key)) return false;
2642
for (int i = _owner.
_selectedItems
.Count - 1; i >= 0; i--)
2644
if (info != _owner.
_selectedItems
[i])
2646
Unselect(_owner.
_selectedItems
[i]);
System\Windows\Controls\SelectedItemCollection.cs (1)
43
foreach (ItemsControl.ItemInfo current in _selector.
_selectedItems
)
System\Windows\Controls\TabControl.cs (1)
512
if (HasItems &&
_selectedItems
.Count == 0)