summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-01-30 19:19:05 -0600
committerJeff Carr <[email protected]>2025-01-30 19:19:05 -0600
commit25fe17d59cd4081ac1204e9686859af773bd69c1 (patch)
tree6955c29e0c33c8cb0fdb390eccb77f7b75aaa813
parentbc15bd663e6ddc08c8a117324b1184d97aab9023 (diff)
apply mbox button
-rw-r--r--windowPatches.go9
1 files changed, 7 insertions, 2 deletions
diff --git a/windowPatches.go b/windowPatches.go
index 4816316..423aae5 100644
--- a/windowPatches.go
+++ b/windowPatches.go
@@ -161,7 +161,7 @@ func (r *patchesWindow) addPatchsetNew(pset *forgepb.Patchset) {
}
var win *patchWindow
- b := r.psetgrid.NewButton("View", func() {
+ r.psetgrid.NewButton("View", func() {
// has the window already been created?
if win != nil {
win.Toggle()
@@ -171,8 +171,13 @@ func (r *patchesWindow) addPatchsetNew(pset *forgepb.Patchset) {
win = makePatchWindow(pset)
win.Show()
})
+
if pset.State == "BROKEN" {
- b.Disable()
+ // a.Disable()
+ } else {
+ r.psetgrid.NewButton("Apply (git am)", func() {
+ applyPatchset(pset)
+ })
}
r.psetgrid.NextRow()
}