summaryrefslogtreecommitdiff
path: root/setText.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-01-18 00:43:48 -0600
committerJeff Carr <[email protected]>2024-01-18 00:43:48 -0600
commitaff82aa4ea8f9e7dcc549afec9218154e1d9c7bd (patch)
tree1ef64a2a6806a6f3bbcf9e0fc8715fd824e9d53a /setText.go
parentd048182ab8e2b3e35aacffce7306583f5caae3aa (diff)
new pathsv0.12.14
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'setText.go')
-rw-r--r--setText.go10
1 files changed, 7 insertions, 3 deletions
diff --git a/setText.go b/setText.go
index a4ba556..3934fa3 100644
--- a/setText.go
+++ b/setText.go
@@ -5,12 +5,14 @@ package gui
import (
"errors"
+ "go.wit.com/lib/widget"
"go.wit.com/log"
- "go.wit.com/gui/widget"
)
func (n *Node) SetText(text string) *Node {
- if ! n.Ready() { return n }
+ if !n.Ready() {
+ return n
+ }
if n.String() == text {
// nothing changed
@@ -26,7 +28,9 @@ func (n *Node) SetText(text string) *Node {
}
func (n *Node) Set(val any) {
- if ! n.Ready() { return }
+ if !n.Ready() {
+ return
+ }
switch v := val.(type) {
case bool: