summaryrefslogtreecommitdiff
path: root/action.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-02-24 11:00:35 -0600
committerJeff Carr <[email protected]>2025-02-24 11:00:35 -0600
commitc502e7c5b60f9f90bd416d4d31c7d70def2c6c18 (patch)
tree8d2141e71ac2b7f3fad70905bf1f907a44a190c8 /action.go
parent4046e33a6399141636678a54be0902f573c3a300 (diff)
new toolkit tree functionsv0.22.19
Diffstat (limited to 'action.go')
-rw-r--r--action.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/action.go b/action.go
index 19cbb87..9ac316c 100644
--- a/action.go
+++ b/action.go
@@ -101,7 +101,11 @@ func (me *TreeInfo) doAction(a widget.Action) {
case widget.Disable:
me.Disable(n)
case widget.Delete:
- me.Hide(n)
+ if me.Hide == nil {
+ log.Info("toolkit doesn't know how to Hide() widgets")
+ } else {
+ me.Hide(n)
+ }
log.Info("tree: todo: remove child from parent")
n.DeleteNode()
// now remove the child from the parent