67 references to _selectedItems
PresentationFramework (67)
System\Windows\Automation\Peers\SelectorAutomationPeer.cs (4)
87
int count = owner.
_selectedItems
.Count;
96
SelectorItemAutomationPeer peer = FindOrCreateItemAutomationPeer(owner.
_selectedItems
[i].Item) as SelectorItemAutomationPeer;
144
int numSelected = owner.
_selectedItems
.Count;
149
SelectorItemAutomationPeer peer = FindOrCreateItemAutomationPeer(owner.
_selectedItems
[0].Item) as SelectorItemAutomationPeer;
System\Windows\Automation\Peers\SelectorItemAutomationPeer.cs (1)
95
return parentSelector.
_selectedItems
.Contains(parentSelector.NewItemInfo(Item));
System\Windows\Controls\DataGrid.cs (4)
4882
int numItemsSelected =
_selectedItems
.Count;
4891
ItemInfo itemInfo =
_selectedItems
[index];
4932
ItemInfo itemInfo =
_selectedItems
[index];
4977
if (minimalModify &&
_selectedItems
.Contains(info))
System\Windows\Controls\ListBox.cs (5)
821
if (
_selectedItems
.Count > 0)
824
AnchorItemInternal =
_selectedItems
[
_selectedItems
.Count - 1];
865
for (int index = 0; index <
_selectedItems
.Count; index++)
867
ItemInfo info =
_selectedItems
[index];
System\Windows\Controls\Primitives\Selector.cs (51)
888
for (int i = 0; i <
_selectedItems
.Count; i++)
890
SelectionChange.Unselect(
_selectedItems
[i]);
950
if (!value && (
_selectedItems
.Count > 1))
1066
foreach (ItemInfo info in
_selectedItems
)
1228
if (!
_selectedItems
.Contains(info))
1253
AdjustItemInfos(e,
_selectedItems
);
1272
if (
_selectedItems
.Contains(info))
1498
Debug.Assert(!((SelectedIndex >= 0) && (
_selectedItems
.Count == 0)), "SelectedIndex >= 0 implies _selectedItems nonempty");
1505
for (int i = 0; i <
_selectedItems
.Count; i++)
1508
ItemSetIsSelected(
_selectedItems
[i], true);
1520
AdjustItemInfosAfterGeneratorChange(
_selectedItems
, claimUniqueContainer:true);
1560
if (
_selectedItems
.Count == 0)
1567
int index =
_selectedItems
[0].Index;
1603
toAdd.UsesItemHashCodes =
_selectedItems
.UsesItemHashCodes;
1604
toRemove.UsesItemHashCodes =
_selectedItems
.UsesItemHashCodes;
1618
foreach (ItemInfo e in
_selectedItems
)
1711
|| (selectedIndex == -1 &&
_selectedItems
.Count > 0)
1713
&& (
_selectedItems
.Count == 0 || selectedIndex !=
_selectedItems
[0].Index)))
1738
if (
_selectedItems
.Count > 0)
1950
_selectedItems
.UsesItemHashCodes = Items.CollectionView.HasReliableHashCodes();
1961
List<int> knownIndices = new List<int>(
_selectedItems
.Count);
1966
foreach (ItemInfo info in
_selectedItems
)
1996
ItemInfo info =
_selectedItems
.FindMatch(key);
2043
foreach (ItemInfo info in
_selectedItems
)
2126
return (
_selectedItems
.Count == 0) ? null :
_selectedItems
[0].Item;
2132
get { return (
_selectedItems
.Count == 0) ? null :
_selectedItems
[0]; }
2143
if (
_selectedItems
.Count == 0)
2146
int index =
_selectedItems
[0].Index;
2149
index = Items.IndexOf(
_selectedItems
[0].Item);
2150
_selectedItems
[0].Index = index;
2324
_toUnselect = new InternalSelectedItemsStorage(_owner.
_selectedItems
);
2329
if (_owner.
_selectedItems
.Count > 1 && _owner.
_selectedItems
.Count != _toUnselect.Count + 1)
2332
ItemInfo selectedItem = _owner.
_selectedItems
[0];
2335
foreach (ItemInfo info in _owner.
_selectedItems
)
2365
using (_owner.
_selectedItems
.DeferRemove())
2374
if (_owner.
_selectedItems
.Remove(info))
2390
ItemInfo match = _owner.
_selectedItems
.FindMatch(ItemInfo.Key(info));
2394
_owner.
_selectedItems
.Remove(match);
2416
if (!_owner.
_selectedItems
.Contains(info))
2418
_owner.
_selectedItems
.Add(info);
2450
if (_toSelect.Contains(key) && !_owner.
_selectedItems
.Contains(info))
2453
_owner.
_selectedItems
.Add(info);
2523
if (_owner.
_selectedItems
.Contains(info)) return false;
2567
if (!_owner.
_selectedItems
.Contains(key)) return false;
2632
for (int i = _owner.
_selectedItems
.Count - 1; i >= 0; i--)
2634
if (info != _owner.
_selectedItems
[i])
2636
Unselect(_owner.
_selectedItems
[i]);
System\Windows\Controls\SelectedItemCollection.cs (1)
41
foreach (ItemsControl.ItemInfo current in _selector.
_selectedItems
)
System\Windows\Controls\TabControl.cs (1)
502
if (HasItems &&
_selectedItems
.Count == 0)