summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhanindra kumar Paladi <phanindrakumar.paladi@gmail.com>2023-01-29 10:03:59 +0530
committerPhanindra kumar Paladi <phanindrakumar.paladi@gmail.com>2023-01-29 10:03:59 +0530
commitdf58c75ca48e9a2f14844086f7add2116d642425 (patch)
tree58dc5a34e06715fe3e460fe4c14f49ec05a2820e
parentf7f24dbfc198679dbcd2781db644354bf5b40856 (diff)
Fixed breaking integrtion tests(old)
-rw-r--r--pkg/gui/custom_patch_options_panel.go15
1 files changed, 9 insertions, 6 deletions
diff --git a/pkg/gui/custom_patch_options_panel.go b/pkg/gui/custom_patch_options_panel.go
index dcaa553bf..6d640157b 100644
--- a/pkg/gui/custom_patch_options_panel.go
+++ b/pkg/gui/custom_patch_options_panel.go
@@ -28,11 +28,6 @@ func (gui *Gui) handleCreatePatchOptionsMenu() error {
OnPress: func() error { return gui.handleApplyPatch(true) },
Key: 'r',
},
- {
- Label: "copy patch to clipboard",
- OnPress: func() error { return gui.copyPatchToClipboard() },
- Key: 'y',
- },
}
if gui.git.Patch.PatchManager.CanRebase && gui.git.Status.WorkingTreeState() == enums.REBASE_MODE_NONE {
@@ -74,6 +69,14 @@ func (gui *Gui) handleCreatePatchOptionsMenu() error {
}
}
+ menuItems = append(menuItems, []*types.MenuItem{
+ {
+ Label: "copy patch to clipboard",
+ OnPress: func() error { return gui.copyPatchToClipboard() },
+ Key: 'y',
+ },
+ }...)
+
return gui.c.Menu(types.CreateMenuOptions{Title: gui.c.Tr.PatchOptionsTitle, Items: menuItems})
}
@@ -206,7 +209,7 @@ func (gui *Gui) copyPatchToClipboard() error {
return gui.c.Error(err)
}
- gui.c.Toast(gui.c.Tr.Actions.CopyPatchToClipboard)
+ gui.c.Toast(gui.c.Tr.PatchCopiedToClipboard)
return nil
}