diff options
Diffstat (limited to 'doGui.go')
| -rw-r--r-- | doGui.go | 23 |
1 files changed, 23 insertions, 0 deletions
@@ -371,6 +371,29 @@ func drawWindow(win *gadgets.BasicWindow) { } // this is the magic that generates a window directly from the protocol buffer +func makeStandardReposGrid(pb *gitpb.Repos) *gitpb.ReposTable { + t := pb.NewTable("testDirty") + sf := t.AddStringFunc("repo", func(r *gitpb.Repo) string { + return r.GetGoPath() + }) + // t.Custom = func() { + // log.Info("close grid?") + // } + sf.Custom = func(r *gitpb.Repo) { + log.Info("do button click on", r.GetGoPath()) + } + t.AddTimeFunc("age", func(repo *gitpb.Repo) time.Time { + return repo.NewestTime() + }) + t.AddMasterVersion() + t.AddDevelVersion() + t.AddUserVersion() + t.AddCurrentBranchName() + t.AddState() + return t +} + +// this is the magic that generates a window directly from the protocol buffer func makeStandardReposWindow(pb *gitpb.Repos) { t := pb.NewTable("testDirty") sf := t.AddStringFunc("repo", func(r *gitpb.Repo) string { |
