cleanup noise
This commit is contained in:
parent
62b8c685f0
commit
0baeaa5525
|
@ -39,13 +39,27 @@ func makePatchsetsWin() *stdPatchsetTableWin {
|
|||
}
|
||||
grid := dwin.win.Group.RawGrid()
|
||||
|
||||
grid.NewButton("update patchsets", func() {
|
||||
grid.NewButton("reload current patches", func() {
|
||||
psets, err := me.forge.GetPatchesets()
|
||||
if err != nil {
|
||||
log.Info("Get Patchsets failed", err)
|
||||
return
|
||||
}
|
||||
savePatchsets(psets)
|
||||
dwin.doPatchsetsTable(psets)
|
||||
})
|
||||
|
||||
grid.NewButton("analyse patchsets", func() {
|
||||
psets, err := openPatchsets()
|
||||
if err != nil {
|
||||
log.Info("Open Patchsets failed", err)
|
||||
return
|
||||
}
|
||||
dwin.doPatchsetsTable(psets)
|
||||
all := psets.All()
|
||||
for all.Scan() {
|
||||
pset := all.Next()
|
||||
log.Info("What is up with?", pset.Name)
|
||||
}
|
||||
})
|
||||
|
||||
// make a box at the bottom of the window for the protobuf table
|
||||
|
@ -86,14 +100,30 @@ func AddPatchsetsPB(tbox *gui.Node, pb *forgepb.Patchsets) *forgepb.PatchsetsTab
|
|||
t.NewUuid()
|
||||
t.SetParent(tbox)
|
||||
|
||||
testf := func(p *forgepb.Patchset) string {
|
||||
/*
|
||||
ctime := p.Ctime.AsTime()
|
||||
s := ctime.Format("2006/01/02 15:04")
|
||||
log.Info("test button", s, p.Name)
|
||||
*/
|
||||
return "test"
|
||||
}
|
||||
t.AddButtonFunc("test", testf)
|
||||
|
||||
butf := func(p *forgepb.Patchset) string {
|
||||
ctime := p.Ctime.AsTime()
|
||||
s := ctime.Format("2006/01/02 15:04")
|
||||
log.Info("Found", s, p.Name)
|
||||
/*
|
||||
ctime := p.Ctime.AsTime()
|
||||
s := ctime.Format("2006/01/02 15:04")
|
||||
log.Info("view button", s, p.Name)
|
||||
*/
|
||||
return "view"
|
||||
}
|
||||
t.AddButtonFunc("view", butf)
|
||||
|
||||
t.AddStringFunc("#", func(p *forgepb.Patchset) string {
|
||||
return fmt.Sprintf("%d", p.Patches.Len())
|
||||
})
|
||||
|
||||
t.AddName()
|
||||
t.AddComment()
|
||||
|
||||
|
|
Loading…
Reference in New Issue