Add actions menu admin features

This commit is contained in:
Storm Dragon
2026-05-19 01:06:01 -04:00
parent eef7454c0f
commit cc483685ef
10 changed files with 1320 additions and 5 deletions
+8 -1
View File
@@ -72,7 +72,7 @@ func (t *Tree) Rebuild() {
}
}
t.lines = lines
t.SetActiveLine(0, true)
t.SetActiveLine(0, false)
t.uiDraw()
}
@@ -162,6 +162,13 @@ func (t *Tree) SetActiveLine(num int, relative bool) {
}
}
func (t *Tree) ActiveItem() TreeItem {
if len(t.lines) == 0 {
return nil
}
return t.lines[bounded(t.activeLine, 0, len(t.lines)-1)].Item
}
func (t *Tree) uiKeyEvent(key Key) {
var runHandler = true
switch key {