summaryrefslogtreecommitdiff
path: root/find.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2021-10-28 19:47:49 -0500
committerJeff Carr <[email protected]>2021-10-28 19:47:49 -0500
commit5a838262bdc72e51351d0d81efcd9b2825e5e525 (patch)
tree49a2722c1d79c8d59f736fd13012750e56dea602 /find.go
parent5cff6a1acef806e263191fcb58bd68ac4a7287ea (diff)
BOX: start node.button() funcs in the rabbit hole
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'find.go')
-rw-r--r--find.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/find.go b/find.go
index 9f849e7..e046161 100644
--- a/find.go
+++ b/find.go
@@ -18,6 +18,13 @@ func (n *Node) FindControl() *ui.Control {
}
func (n *Node) FindBox() *GuiBox {
+ if (n.box != nil) {
+ return n.box
+ }
+ if (n.parent != nil) {
+ p := n.parent
+ return p.box
+ }
return n.box
}