more variable name fixes

Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
Jeff Carr 2019-05-30 09:19:58 -07:00
parent cf85851ad3
commit 1179bc7cf0
2 changed files with 10 additions and 10 deletions

View File

@ -13,7 +13,7 @@ import pb "git.wit.com/wit/witProtobuf"
import "github.com/andlabs/ui" import "github.com/andlabs/ui"
import _ "github.com/andlabs/ui/winmanifest" import _ "github.com/andlabs/ui/winmanifest"
var first *gui.WindowMap var first *gui.GuiWindow
func main() { func main() {
var c *pb.Config var c *pb.Config
@ -48,11 +48,11 @@ func main() {
} }
} }
func StartNewWindow(c *pb.Config, bg bool, action string) *gui.WindowMap { func StartNewWindow(c *pb.Config, bg bool, action string) *gui.GuiWindow {
log.Println("InitNewWindow() Create a new window") log.Println("InitNewWindow() Create a new window")
var newWindowMap *gui.WindowMap var newGuiWindow *gui.GuiWindow
newWindowMap = new(gui.WindowMap) newGuiWindow = new(gui.GuiWindow)
newWindowMap.C = c newGuiWindow.C = c
/* /*
ui.OnShouldQuit(func() bool { ui.OnShouldQuit(func() bool {
@ -66,19 +66,19 @@ func StartNewWindow(c *pb.Config, bg bool, action string) *gui.WindowMap {
if (bg) { if (bg) {
log.Println("ShowWindow() IN NEW GOROUTINE") log.Println("ShowWindow() IN NEW GOROUTINE")
go ui.Main(func() { go ui.Main(func() {
InitWindow(newWindowMap) InitWindow(newGuiWindow)
}) })
time.Sleep(2000 * time.Millisecond) time.Sleep(2000 * time.Millisecond)
} else { } else {
log.Println("ShowWindow() WAITING for ui.Main()") log.Println("ShowWindow() WAITING for ui.Main()")
ui.Main(func() { ui.Main(func() {
InitWindow(newWindowMap) InitWindow(newGuiWindow)
}) })
} }
return newWindowMap return newGuiWindow
} }
func InitWindow(wm *gui.WindowMap) { func InitWindow(wm *gui.GuiWindow) {
log.Println("InitWindow() NEW WINDOW wm =", wm) log.Println("InitWindow() NEW WINDOW wm =", wm)
c := wm.C c := wm.C

View File

@ -60,7 +60,7 @@ func mainMouseClick(b *gui.GuiButton) {
log.Println("mainMouseClick() b.Action =", b.Account) log.Println("mainMouseClick() b.Action =", b.Account)
spew.Dump(b.Account) spew.Dump(b.Account)
var wm *gui.WindowMap var wm *gui.GuiWindow
wm = b.WM wm = b.WM
if (wm == nil) { if (wm == nil) {