35 references to Parent
System.Windows.Forms (4)
System\Windows\Forms\Controls\TreeView\TreeNode.cs (3)
390
node = node.
Parent
;
660
public int Level =>
Parent
is null ? 0 :
Parent
.Level + 1;
System\Windows\Forms\Controls\TreeView\TreeNode.TreeNodeAccessibleObject.cs (1)
140
public override AccessibleObject? Parent => _owningTreeNode.
Parent
?.AccessibilityObject;
System.Windows.Forms.Design (9)
System\Windows\Forms\Design\DesignBindingPicker.cs (1)
2631
ProjectDataMemberNode? parentListMember = (
Parent
as ProjectDataMemberNode);
System\Windows\Forms\Design\TreeNodeCollectionEditor.cs (8)
558
if (parent == child.
Parent
)
563
child = child.
Parent
;
624
TreeNode parent = _curNode.
Parent
;
640
if (parent.
Parent
is null)
646
parent.
Parent
.Nodes.Insert(parent.Index + 1, tempNode);
658
TreeNode parent = _curNode.
Parent
;
670
if (parent.
Parent
is null)
676
parent.
Parent
.Nodes.Insert(parent.Index, tempNode);
System.Windows.Forms.Tests (22)
System\Windows\Forms\AccessibleObjects\TreeNode.TreeNodeAccessibleObjectTests.cs (2)
150
Assert.Equal(node.
Parent
.AccessibilityObject, actual);
328
Assert.Equal(node.
Parent
.AccessibilityObject, node.AccessibilityObject.Parent);
System\Windows\Forms\TreeNodeCollectionTests.cs (1)
44
Assert.Null(treeNode.
Parent
);
System\Windows\Forms\TreeNodeTests.cs (19)
39
Assert.Null(node.
Parent
);
79
Assert.Null(node.
Parent
);
127
Assert.Null(node.
Parent
);
170
Assert.Null(node.
Parent
);
218
Assert.Null(node.
Parent
);
2411
Assert.Null(node.
Parent
);
2429
Assert.Null(node.
Parent
);
2448
Assert.Equal(parent, node1.
Parent
);
2449
Assert.Equal(parent, node2.
Parent
);
2450
Assert.Equal(parent, node3.
Parent
);
2451
Assert.Equal(node3, node4.
Parent
);
2469
Assert.Equal(parent, node1.
Parent
);
2470
Assert.Equal(parent, node2.
Parent
);
2471
Assert.Equal(parent, node3.
Parent
);
2472
Assert.Equal(node3, node4.
Parent
);
2498
Assert.Equal(parent, node1.
Parent
);
2499
Assert.Equal(parent, node2.
Parent
);
2500
Assert.Equal(parent, node3.
Parent
);
2501
Assert.Equal(node3, node4.
Parent
);