diff options
author | Stefan Haller <stefan@haller-berlin.de> | 2023-09-15 17:46:21 +0200 |
---|---|---|
committer | Stefan Haller <stefan@haller-berlin.de> | 2023-09-18 10:20:23 +0200 |
commit | 0b13c3ca87313a94d5c7972db39b7e64fbea5d67 (patch) | |
tree | 059376c3745f60abd7548dca2c65687946c38742 /pkg/gui/controllers/helpers/cherry_pick_helper.go | |
parent | 8b6766de79509617b02f4ab373f6d8ae3c0b4958 (diff) |
Disabled paste when there are no copied commits
Diffstat (limited to 'pkg/gui/controllers/helpers/cherry_pick_helper.go')
-rw-r--r-- | pkg/gui/controllers/helpers/cherry_pick_helper.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pkg/gui/controllers/helpers/cherry_pick_helper.go b/pkg/gui/controllers/helpers/cherry_pick_helper.go index 2e8a11f7d..e27e469b6 100644 --- a/pkg/gui/controllers/helpers/cherry_pick_helper.go +++ b/pkg/gui/controllers/helpers/cherry_pick_helper.go @@ -85,6 +85,10 @@ func (self *CherryPickHelper) Paste() error { }) } +func (self *CherryPickHelper) CanPaste() bool { + return self.getData().Active() +} + func (self *CherryPickHelper) Reset() error { self.getData().ContextKey = "" self.getData().CherryPickedCommits = nil |