1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-30 03:23:08 +03:00

lots of changes

This commit is contained in:
Jesse Duffield
2023-03-23 18:47:29 +11:00
parent 711674f6cd
commit db12853bbe
63 changed files with 1024 additions and 943 deletions

View File

@ -9,17 +9,17 @@ import (
type StashController struct {
baseController
*controllerCommon
c *ControllerCommon
}
var _ types.IController = &StashController{}
func NewStashController(
common *controllerCommon,
common *ControllerCommon,
) *StashController {
return &StashController{
baseController: baseController{},
controllerCommon: common,
baseController: baseController{},
c: common,
}
}
@ -57,7 +57,7 @@ func (self *StashController) GetKeybindings(opts types.KeybindingsOpts) []*types
func (self *StashController) GetOnRenderToMain() func() error {
return func() error {
return self.helpers.Diff.WithDiffModeCheck(func() error {
return self.c.Helpers().Diff.WithDiffModeCheck(func() error {
var task types.UpdateTask
stashEntry := self.context().GetSelected()
if stashEntry == nil {
@ -165,7 +165,7 @@ func (self *StashController) postStashRefresh() error {
}
func (self *StashController) handleNewBranchOffStashEntry(stashEntry *models.StashEntry) error {
return self.helpers.Refs.NewBranch(stashEntry.RefName(), stashEntry.Description(), "")
return self.c.Helpers().Refs.NewBranch(stashEntry.RefName(), stashEntry.Description(), "")
}
func (self *StashController) handleRenameStashEntry(stashEntry *models.StashEntry) error {