summaryrefslogtreecommitdiff
path: root/gui-example/main.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2021-10-31 14:21:36 -0500
committerJeff Carr <[email protected]>2021-10-31 14:21:36 -0500
commit213c7d153b06d3e1211d1cdeae1e4f7833cb89f7 (patch)
tree53b489c9df4ea1784be0d626df1497b04183c9be /gui-example/main.go
parent36e2c6d2e3c266f32325985e98c3776755fdd511 (diff)
REFACTOR: refactor everything to gui.Node structv0.2
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'gui-example/main.go')
-rw-r--r--gui-example/main.go43
1 files changed, 0 insertions, 43 deletions
diff --git a/gui-example/main.go b/gui-example/main.go
deleted file mode 100644
index 1ff286d..0000000
--- a/gui-example/main.go
+++ /dev/null
@@ -1,43 +0,0 @@
-package main
-
-import (
- "log"
- "os"
- "time"
-
- "git.wit.org/wit/gui"
-)
-
-func customExit(gw *gui.GuiWindow) {
- log.Println("Should Exit Here")
- os.Exit(0)
-}
-
-func main() {
- log.Println("starting my Control Panel")
-
- gui.Config.Width = 800
- gui.Config.Height = 300
- gui.Config.Exit = customExit
-
- go gui.Main(initGUI)
-
- watchGUI()
-}
-
-func initGUI() {
- gui.NewWindow("jcarr start", 640, 480)
-}
-
-func watchGUI() {
- var i = 1
- for {
- log.Println("Waiting for customExit()", i)
- i += 1
- time.Sleep(time.Second)
- if i == 3 {
- log.Println("Sending ExampleWindow to gui.Queue()")
- gui.Queue(gui.DebugWindow)
- }
- }
-}