summaryrefslogtreecommitdiff
path: root/toolkit/andlabs/window.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2022-10-20 06:55:42 -0500
committerJeff Carr <[email protected]>2022-10-20 06:55:42 -0500
commitb8ef0bb05dc14bc4291f3d156b199fa125cdb9d7 (patch)
tree71280d7f01805dfbd430f71df16858079686b8fc /toolkit/andlabs/window.go
parentf3af1f5b7ff78b3f73d7510622fc9633dec36d35 (diff)
Squashed commit of the following:
all non binary tree structs are gone (almost all) Use names from https://en.wikipedia.org/wiki/Graphical_widget toolkit andlabs/ui is isolated from being accessable all direct references to andlabs are removed working dropdown widgets add debugging more buttons and windows
Diffstat (limited to 'toolkit/andlabs/window.go')
-rw-r--r--toolkit/andlabs/window.go13
1 files changed, 10 insertions, 3 deletions
diff --git a/toolkit/andlabs/window.go b/toolkit/andlabs/window.go
index f0357ed..f09a810 100644
--- a/toolkit/andlabs/window.go
+++ b/toolkit/andlabs/window.go
@@ -2,7 +2,6 @@ package toolkit
import (
"log"
- "os"
"github.com/andlabs/ui"
_ "github.com/andlabs/ui/winmanifest"
@@ -33,8 +32,6 @@ func NewWindow(title string, x int, y int) *Toolkit {
t.Custom()
}
log.Println("ui.Window().OnExit() Toolkit.OnExit is nil")
- t.Dump()
- os.Exit(0)
return true
})
w.SetMargined(true)
@@ -43,3 +40,13 @@ func NewWindow(title string, x int, y int) *Toolkit {
t.UiWindowBad = w // deprecate this as soon as possible
return &t
}
+
+func (t *Toolkit) SetWindowTitle(title string) {
+ log.Println("toolkit NewWindow", t.Name, "title", title)
+ win := t.uiWindow
+ if (win != nil) {
+ win.SetTitle(title)
+ } else {
+ log.Println("Setting the window title", title)
+ }
+}