49 lines
1.0 KiB
Go
49 lines
1.0 KiB
Go
|
// This window, when it's hidden, still exists to the application
|
||
|
// so it can be treated as if it really exists
|
||
|
package main
|
||
|
|
||
|
import (
|
||
|
"os"
|
||
|
|
||
|
"go.wit.com/gui"
|
||
|
"go.wit.com/lib/gadgets"
|
||
|
"go.wit.com/log"
|
||
|
)
|
||
|
|
||
|
var apple *gui.Node
|
||
|
|
||
|
// This initializes the first window, a group and a button
|
||
|
func makebasicWindow() *gadgets.BasicWindow {
|
||
|
log.Warn("init basicWindow state")
|
||
|
basicWindow = gadgets.NewBasicWindow(myGui, "Create .deb files for GO applications")
|
||
|
basicWindow.Make()
|
||
|
basicWindow.Custom = func() {
|
||
|
log.Info("got to close")
|
||
|
os.Exit(0)
|
||
|
}
|
||
|
|
||
|
box1 := basicWindow.Box()
|
||
|
newControl(box1)
|
||
|
|
||
|
// vbox := box1.NewBox("vbox", false)
|
||
|
// vbox := box1.Box().Vertical()
|
||
|
vbox := box1.Box().Horizontal()
|
||
|
group1 := vbox.NewGroup("controls").Horizontal() // Vertical()
|
||
|
group1.NewButton("go build", func() {
|
||
|
})
|
||
|
group1.NewButton("Make .deb", func() {
|
||
|
})
|
||
|
group1.NewButton("open repo", func() {
|
||
|
})
|
||
|
/*
|
||
|
group1.NewButton("show apple", func() {
|
||
|
apple.Show()
|
||
|
})
|
||
|
apple = group1.NewButton("apple", func() {
|
||
|
log.Info("is not a pear")
|
||
|
})
|
||
|
*/
|
||
|
|
||
|
return basicWindow
|
||
|
}
|