summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-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