Private m_Private m_Protected m_Protected m_Protected m_Private m_Private m_Protected m_Private m_Returns true if events are blocked; otherwise returns false.
If blocked is true, then events emitted by this event watcher will be blocked, meaning that emitting an event will not trigger any callback functions that are bound to it.
Returns whether this tree node is checkable.
Sets whether this tree node is checkable. If checkable is true, the node can be checked by the user; otherwise the user cannot check the node.
Returns the check state of this tree node.
Sets the check state of this tree node to checked.
Returns the number of all child nodes including any hidden nodes.
Returns the native DOM of this widget, user can directly manipulate the native DOM.
Returns whether this widget or its parent chain is enabled or not. By default, the value of this property is true.
Sets whether this widget is enabled or not. Disabling a widget implicitly disables all its children, it is not possible to explicitly enable a child widget while its parent widget remains disabled.
Returns true if the tree node is expanded, otherwise returns false.
Expands the tree node if expanded is true, otherwise collapses the node.
Returns the height of this widget.
Sets the height of this widget to the given height.
The unit of height is px.
Returns the id of this widget.
Set the id of this widget to the given id. The id is utilized to set the style of the widget. See also css
Returns the image of this tree node.
Sets the image of this tree node to the given image.
Returns the item of this tree node.
Returns the left coordinate of this widget within its parent widget.
Sets the left coordinate of this widget within its parent widget.
The unit of left is px.
Returns the orientation of this flex layout.
Sets the orientation of this flex layout to the given orientation.
Returns the index of this tree node in its parent. If its parent is undefined, returns -1.
Returns true if this tree node is selected; otherwise returns false.
Sets the selected state of this tree node to the given select.
Returns the spacing between widgets inside this flex layout.
Set the spacing to the given pacing.
Returns the style of this widget.
Returns the text of this tree node.
Sets the text of this tree node to text.
Returns the tooltip of this tree node.
Sets the tooltip of this tree node to the given tooltip.
Returns the top coordinate of this widget within its parent widget.
Sets the top coordinate of this widget to the given top.
The unit of top is px.
Returns the tree widget that contains this tree node. If this tree node is not in any tree widget, returns undefined.
Returns whether this widget or its parent chain is visible or not. By default, the value of this property is true.
Sets whether this widget is visible or not. If an ancestor widget is not visible, the widget won't become visible until all its ancestors are visible.
Returns the width of this widget.
Sets the width of this widget to the given width.
The unit of width is px.
Static senderReturns the object that sent the event.
Adds the given node as a child node to this tree node.
Adds the attribute of this widget. The attribute is utilized to set the style. See also css
Adds the class name of this widget. The class name is utilized to set the style. See also css. All widgets with the same class name use the same style.
Protected align2Protected attachAdds a callback function that's going to be called when the event is emitted.
Rest ...data: EventMap[K]Rest ...data: any[]Private createDelegates this event watcher to handle the given watcher's event named name.
Private deselectDestroys the widget, all the widget's children are destroyed first. The widget is destroyed when it's parent is destroyed. When the widget is destroyed, make sure to release all resources, such as timers, etc. Releases the resources in the protected function free(), and the system will call this function automatically when the parent widget or itself is destroyed. See also free.
Protected detachEmits an arbitrary set of arguments to the callback function which is bound to the event named name.
Rest ...data: EventMap[K]Rest ...data: any[]Performs the specified action for each child node.
Protected freeFrees the resources.See also destroy.
Inserts the given node as a child node into this tree node at the position index.
Inserts the child widget at index in the list of children.
Private linkRemoves the given node from this tree node.
Sets whether the widget uses flex layout.
Horizontal or vertical.
Optional alignItem: "center" | "inherit" | "stretch" | "flex-start" | "flex-end" | "initial" | "baseline"Optional spacing: numberthe spacing between widgets inside the layout.
Protected str2Performs the specified action for all child nodes and itself.
Removes the specified watcher for the event named name.
Private unlinkPrivate updateGenerated using TypeDoc
The TreeNode class provides an item for use with the TreeWidget.