MCPcopy
hub / github.com/g3n/engine / SetSelected

Method SetSelected

gui/dropdown.go:133–139  ·  view source on GitHub ↗

SetSelected sets the selected item

(item *ImageLabel)

Source from the content-addressed store, hash-verified

131
132// SetSelected sets the selected item
133func (dd *DropDown) SetSelected(item *ImageLabel) {
134
135 dd.list.SetSelected(dd.selItem, false)
136 dd.list.SetSelected(item, true)
137 dd.copySelected()
138 dd.update()
139}
140
141// SelectPos selects the item at the specified position
142func (dd *DropDown) SelectPos(pos int) {

Callers 1

SelectPosMethod · 0.45

Calls 2

copySelectedMethod · 0.95
updateMethod · 0.95

Tested by

no test coverage detected