MCPcopy Create free account
hub / github.com/cogentcore/core / SetSelectedNodes

Method SetSelectedNodes

core/tree.go:664–668  ·  view source on GitHub ↗

SetSelectedNodes updates the selected nodes on the root node to the given list.

(sl []Treer)

Source from the content-addressed store, hash-verified

662
663// SetSelectedNodes updates the selected nodes on the root node to the given list.
664func (tr *Tree) SetSelectedNodes(sl []Treer) {
665 if tr.root != nil {
666 tr.root.SelectedNodes = sl
667 }
668}
669
670// HasSelection returns whether there are currently selected items.
671func (tr *Tree) HasSelection() bool {

Callers 3

SelectMethod · 0.95
UnselectMethod · 0.95
UnselectAllMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected