summaryrefslogtreecommitdiff
path: root/label.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2023-05-09 08:38:33 -0500
committerJeff Carr <[email protected]>2023-05-09 08:38:33 -0500
commite45e4212da86283e2f9592f11c08d798dfd39860 (patch)
treed95e283a06fc972ebab61587198a8cffec25e2f9 /label.go
parente19a728d7fe0059b87e7af84c7155fd6559ced6d (diff)
compiles again
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'label.go')
-rw-r--r--label.go12
1 files changed, 4 insertions, 8 deletions
diff --git a/label.go b/label.go
index b3833e9..43f8073 100644
--- a/label.go
+++ b/label.go
@@ -4,13 +4,9 @@ import (
"git.wit.org/wit/gui/toolkit"
)
-func (n *Node) NewLabel(text string) *Node {
- newNode := n.newNode(text, toolkit.Label, nil)
-
- n.Name = text
- n.Text = text
- a := newAction(n, toolkit.Add)
- sendAction(a, newNode, n)
-
+func (parent *Node) NewLabel(text string) *Node {
+ newNode := parent.newNode(text, toolkit.Label, nil)
+ a := newAction(newNode, toolkit.Add)
+ sendAction(a, newNode, parent)
return newNode
}