24 writes to SelectedNode
System.Windows.Forms (6)
System\Windows\Forms\Controls\TreeView\TreeNode.cs (2)
1442tv.SelectedNode = this; 1803TreeView.SelectedNode = node; // communicate this to the handle
System\Windows\Forms\Controls\TreeView\TreeNode.TreeNodeAccessibleObject.cs (1)
106_owningTreeView.SelectedNode = _owningTreeNode;
System\Windows\Forms\Controls\TreeView\TreeNodeCollection.cs (1)
345tv.SelectedNode = node; // communicate this to the handle
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
1965SelectedNode = savedSelectedNode;
System\Windows\Forms\Design\ComponentEditorForm.cs (1)
320_selector.SelectedNode = _selector.Nodes[_initialActivePage];
System.Windows.Forms.Design (8)
System\ComponentModel\Design\ObjectSelectorEditor.Selector.cs (1)
155SelectedNode = treeNodes[i];
System\Windows\Forms\Design\DesignBindingPicker.cs (1)
1820_treeViewCtrl!.SelectedNode = node;
System\Windows\Forms\Design\TreeNodeCollectionEditor.cs (6)
172_treeView1.SelectedNode = parent; 176_treeView1.SelectedNode = newNode; 440_treeView1.SelectedNode = nodes[0]; 579_treeView1.SelectedNode = currentNode; 651_treeView1.SelectedNode = tempNode; 685_treeView1.SelectedNode = tempNode;
System.Windows.Forms.Tests (10)
System\Windows\Forms\AccessibleObjects\TreeView.TreeViewAccessibleObjectTests.cs (1)
218control.SelectedNode = control.Nodes[1];
System\Windows\Forms\TreeViewTests.cs (9)
5784control.SelectedNode = node; 6030control.SelectedNode = node; 6111control.SelectedNode = node; 6226control.SelectedNode = node; 6835treeView.SelectedNode = treeView.Nodes[0]; 6861treeView.SelectedNode = treeView.Nodes[0]; 6898treeView.SelectedNode = treeNode.Nodes[0]; 6927treeView.SelectedNode = treeNode.Nodes[0]; 6964treeView.SelectedNode = treeNode.Nodes[0];
37 references to SelectedNode
System.Windows.Forms (11)
System\Windows\Forms\Controls\TreeView\TreeNode.cs (1)
1427if (tv.SelectedNode == _children[i])
System\Windows\Forms\Controls\TreeView\TreeView.cs (9)
2025_selectedNode = SelectedNode; 2073NotifyAboutLostFocus(SelectedNode); 2259TreeNode? node = SelectedNode; 2503NotifyAboutLostFocus(SelectedNode); 3091NotifyAboutGotFocus(SelectedNode); 3096SelectedNode?.AccessibilityObject?.RaiseAutomationEvent(UIA_EVENT_ID.UIA_AutomationFocusChangedEventId); 3103NotifyAboutLostFocus(SelectedNode); 3427TreeNode? treeNode = SelectedNode; 3455SelectedNode?.AccessibilityObject?.RaiseAutomationEvent(UIA_EVENT_ID.UIA_AutomationFocusChangedEventId);
System\Windows\Forms\Design\ComponentEditorForm.cs (1)
382int newPage = _selector.SelectedNode!.Index;
System.Windows.Forms.Design (6)
System\ComponentModel\Design\ObjectSelectorEditor.Selector.cs (3)
63_editor.SetValue(((SelectorNode)SelectedNode!).value); 64if (_editor.EqualsToValue(((SelectorNode)SelectedNode).value)) 130if (e.Node == SelectedNode)
System\Windows\Forms\Design\DesignBindingPicker.cs (2)
2090if (e.KeyData == Keys.Return && SelectedNode is not null) 2092SetSelectedItem(SelectedNode);
System\Windows\Forms\Design\TreeNodeCollectionEditor.cs (1)
451_label2.Text = string.Format(SR.CollectionEditorProperties, _treeView1.SelectedNode.Text);
System.Windows.Forms.Tests (20)
System\Windows\Forms\AccessibleObjects\TreeNode.TreeNodeAccessibleObjectTests.cs (3)
481Assert.Null(control.SelectedNode); 484Assert.Equal("Node2", control.SelectedNode?.Text); 487Assert.Equal("Node4", control.SelectedNode?.Text);
System\Windows\Forms\TreeViewTests.cs (17)
107Assert.Null(control.SelectedNode); 6240Assert.Same(node, control.SelectedNode); 6248Assert.Same(node, control.SelectedNode); 6839Assert.Equal(treeView.Nodes[0], treeView.SelectedNode); 6845Assert.Equal(treeView.Nodes[0], treeView.SelectedNode); 6851Assert.Equal(treeView.Nodes[0], treeView.SelectedNode); 6869Assert.Equal(node, treeView.SelectedNode); 6879Assert.Null(treeView.SelectedNode); 6883Assert.Equal(treeView.Nodes[0], treeView.SelectedNode); 6902Assert.Equal(treeNode.Nodes[0], treeView.SelectedNode); 6908Assert.Equal(treeNode.Nodes[0], treeView.SelectedNode); 6914Assert.Equal(treeNode.Nodes[0], treeView.SelectedNode); 6935Assert.Equal(node, treeView.SelectedNode); 6945Assert.Equal(treeView.Nodes[0], treeView.SelectedNode); 6949Assert.Equal(treeNode.Nodes[0], treeView.SelectedNode); 6967Assert.Equal(treeNode.Nodes[0], treeView.SelectedNode); 6974Assert.Null(treeView.SelectedNode);