diff options
| author | Jeff Carr <[email protected]> | 2022-11-14 14:30:28 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2022-11-14 14:30:28 -0600 |
| commit | 355e5ec968427c2b07b78fec12224f31a65df740 (patch) | |
| tree | 99754f9f6888c166a435d14e3a71cc9304f14970 /toolkit/andlabs/main.go | |
| parent | 207cf7ea16f1da8fa9f893504d77a2856298cc22 (diff) | |
setup building without plugins on windowsv0.5.1
notes from github remote
keep removing os.Exit()
rename from andlabs2 back to andlabs
rename files for windows andlabs/ui
gocui always sets STDOUT a file in /tmp/
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'toolkit/andlabs/main.go')
| -rw-r--r-- | toolkit/andlabs/main.go | 34 |
1 files changed, 30 insertions, 4 deletions
diff --git a/toolkit/andlabs/main.go b/toolkit/andlabs/main.go index da639fa..85e6913 100644 --- a/toolkit/andlabs/main.go +++ b/toolkit/andlabs/main.go @@ -1,7 +1,10 @@ -package toolkit +package main import ( "log" +// "time" + + "git.wit.org/wit/gui/toolkit" "github.com/andlabs/ui" // the _ means we only need this for the init() @@ -12,7 +15,17 @@ func Main(f func()) { if (DebugToolkit) { log.Println("Starting gui.Main() (using gtk via andlabs/ui)") } - ui.Main(f) + ui.Main( func() { + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + log.Println("Starting gui.Main() (using gtk via andlabs/ui)") + // time.Sleep(1 * time.Second) + // NewWindow2("helloworld2", 200, 100) + f() + }) } // Other goroutines must use this to access the GUI @@ -25,7 +38,20 @@ func Main(f func()) { // func Queue(f func()) { if (DebugToolkit) { - log.Println("Sending function to gui.Main() (using gtk via andlabs/ui)") + log.Println("Sending function to ui.QueueMain() (using gtk via andlabs/ui)") } - ui.QueueMain(f) + //ui.QueueMain(f) + f() +} + +func Init() { + log.Println("should Init() here") + + mapWidgets = make(map[*andlabsT]*toolkit.Widget) + mapToolkits = make(map[*toolkit.Widget]*andlabsT) +} + +func Quit() { + log.Println("should Quit() here") + // myExit(nil) } |
