diff options
Diffstat (limited to 'gui.go')
| -rw-r--r-- | gui.go | 27 |
1 files changed, 19 insertions, 8 deletions
@@ -1,11 +1,14 @@ package gui -import "log" -// import "time" -import "regexp" +import ( + "github.com/andlabs/ui" // import "time" + "log" + "regexp" -import "github.com/andlabs/ui" -import _ "github.com/andlabs/ui/winmanifest" // the _ means we only need this for the init() + _ "github.com/andlabs/ui/winmanifest" +) + +// the _ means we only need this for the init() const Xaxis = 0 // box that is horizontal const Yaxis = 1 // box that is vertical @@ -13,13 +16,21 @@ const Yaxis = 1 // box that is vertical func init() { log.Println("gui.init() has been run") - Data.buttonMap = make(map[*ui.Button]*GuiButton) - Data.WindowMap = make(map[string]*GuiWindow) + Data.buttonMap = make(map[*ui.Button]*GuiButton) + Data.WindowMap = make(map[string]*GuiWindow) + Data.NodeMap = make(map[string]*Node) + + Data.NodeSlice = make([]*Node, 0) + + Config.counter = 0 + Config.prefix = "wit" + Config.DebugNode = false + Config.DebugTabs = false } func GuiInit() { ui.OnShouldQuit(func() bool { - ui.Quit() + ui.Quit() return true }) } |
