start tracking which tabs exist
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
7c420444d0
commit
a2e5eb023a
|
@ -42,15 +42,26 @@ func makeCloudInfoBox(gw *gui.GuiWindow) {
|
|||
}
|
||||
|
||||
Xbox := gui.HardBox(gw, gui.Xaxis, "subdomain test")
|
||||
makeButton(Xbox, nil, nil, "Add Account", "ADD TAB", addSubdomainClick)
|
||||
makeButton(Xbox, nil, nil, "Add Account", "ADD TAB", func (*gui.GuiButton) {
|
||||
log.Println("makeCloudInfoBox() Add Account")
|
||||
createAccount(gw)
|
||||
})
|
||||
makeButton(Xbox, nil, nil, "Quit", "QUIT", nil)
|
||||
makeButton(Xbox, nil, nil, "Debug", "DEBUG", debugClick)
|
||||
log.Println("makeCloudInfoBox() END")
|
||||
}
|
||||
|
||||
func createAccount(gw *gui.GuiWindow) {
|
||||
|
||||
window := gui.Data.WindowMap["createAccount"]
|
||||
if (window != nil) {
|
||||
box := window.BoxMap["MAINBOX"]
|
||||
log.Println("createAccount tab already exists")
|
||||
gui.MessageWindow(box.Window, "createAccount", "New account tab already exists")
|
||||
return
|
||||
}
|
||||
// if there is not an account, then go to 'make account'
|
||||
gw = gui.InitGuiWindow("splashClick() Box22", gw)
|
||||
gw = gui.InitGuiWindow("createAccount", gw)
|
||||
|
||||
box := gui.HardBox(gw, gui.Yaxis, "Create New Account")
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ func debugClick(b *gui.GuiButton) {
|
|||
gw := b.Box.Window
|
||||
|
||||
// if there is not an account, then go to 'make account'
|
||||
gw = gui.InitGuiWindow("debug() Box22", gw)
|
||||
gw = gui.InitGuiWindow("debugClick", gw)
|
||||
|
||||
log.Println("debugClick() AddGenericBox() START")
|
||||
box := gui.HardBox(gw, gui.Yaxis, "debugging")
|
||||
|
|
3
main.go
3
main.go
|
@ -55,6 +55,9 @@ type myButtonInfo struct {
|
|||
// cross platform openvpn that may work for IPv6
|
||||
// https://github.com/mysteriumnetwork/go-openvpnwe
|
||||
|
||||
// i18n with 'po' file support
|
||||
// https://github.com/leonelquinteros/gotext
|
||||
|
||||
func onExit(err error) {
|
||||
log.Println("Sleep for 1 second")
|
||||
time.Sleep(1 * 1000 * 1000 * 1000)
|
||||
|
|
Loading…
Reference in New Issue