diff options
Diffstat (limited to 'repolist.go')
| -rw-r--r-- | repolist.go | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/repolist.go b/repolist.go index ab1aa5f..ef82c26 100644 --- a/repolist.go +++ b/repolist.go @@ -134,34 +134,34 @@ func addRepo(grid *gui.Node, path string, master string, devel string, user stri // This creates a window func repolistWindow() { - reposwin = gadgets.NewBasicWindow(me.myGui, "All git repositories in ~/go/src/") - reposwin.Make() + me.reposwin = gadgets.NewBasicWindow(me.myGui, "All git repositories in ~/go/src/") + me.reposwin.Make() - reposbox = reposwin.Box().NewBox("bw vbox", false) - reposwin.Draw() - reposwin.Custom = func() { + me.reposbox = me.reposwin.Box().NewBox("bw vbox", false) + // me.reposwin.Draw() + me.reposwin.Custom = func() { log.Warn("GOT HERE: main() gadgets.NewBasicWindow() close") log.Warn("Should I do something special here?") } - repoAllButtons(reposbox) + repoAllButtons(me.reposbox) - reposgroup = reposbox.NewGroup("go repositories (read from ~/.config/myrepolist)") - reposgrid = reposgroup.NewGrid("test", 8, 1) + me.reposgroup = me.reposbox.NewGroup("go repositories (read from ~/.config/myrepolist)") + me.reposgrid = me.reposgroup.NewGrid("test", 8, 1) - reposgrid.NewLabel("") // path goes here + me.reposgrid.NewLabel("") // path goes here - reposgrid.NewLabel("last tag").SetProgName("last tag") + me.reposgrid.NewLabel("last tag").SetProgName("last tag") - reposgrid.NewLabel("master version") - reposgrid.NewLabel("devel version") - reposgrid.NewLabel("user version") + me.reposgrid.NewLabel("master version") + me.reposgrid.NewLabel("devel version") + me.reposgrid.NewLabel("user version") - reposgrid.NewLabel("Status") + me.reposgrid.NewLabel("Status") - reposgrid.NewLabel("Current Version").SetProgName("Current Version") + me.reposgrid.NewLabel("Current Version").SetProgName("Current Version") - reposgrid.NewLabel("Show()") + me.reposgrid.NewLabel("Show()") usr, _ := user.Current() @@ -178,7 +178,7 @@ func repolistWindow() { if ubranch == "" { ubranch = usr.Username } - addRepo(reposgrid, path, mbranch, dbranch, ubranch) + addRepo(me.reposgrid, path, mbranch, dbranch, ubranch) } // TODO: figure out why this borks everything @@ -191,7 +191,7 @@ func repolistWindow() { } */ - reposwin.Toggle() + // reposwin.Toggle() } func repoAllButtons(box *gui.Node) { @@ -212,30 +212,30 @@ func repoAllButtons(box *gui.Node) { box2 := hbox.Box().Vertical() box2.NewButton("merge all user to devel", func() { - reposwin.Disable() + me.reposwin.Disable() if !mergeAllUserToDevel() { return } - reposwin.Enable() + me.reposwin.Enable() }) box2.NewButton("merge all devel to main", func() { - reposwin.Disable() + me.reposwin.Disable() if !mergeAllDevelToMain() { return } - reposwin.Enable() + me.reposwin.Enable() }) box2.NewButton("merge it all", func() { - reposwin.Disable() + me.reposwin.Disable() if !mergeAllUserToDevel() { return } if !mergeAllDevelToMain() { return } - reposwin.Enable() + me.reposwin.Enable() }) } |
