mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-09-10 07:36:27 -04:00
Drop the highlight fixups the context stack now makes unnecessary
Two places nudged the flags because nothing else would: switching repos, where the view focused in the repo being left is not the one focused in the repo being entered, and tabbing from the suggestions list back to the prompt, which replaces the top of the stack rather than popping it, so the suggestions context never hears that it lost the focus. Both are just a context leaving the stack now. Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ec3f681ebf
commit
d2dc38ee87
|
|
@ -85,7 +85,6 @@ func (self *SuggestionsController) GetMouseKeybindings(opts types.KeybindingsOpt
|
|||
|
||||
func (self *SuggestionsController) switchToPrompt() error {
|
||||
self.c.Views().Suggestions.Subtitle = ""
|
||||
self.c.Views().Suggestions.Highlight = false
|
||||
self.c.Context().Replace(self.c.Contexts().Prompt)
|
||||
return nil
|
||||
}
|
||||
|
|
|
|||
|
|
@ -598,13 +598,6 @@ func (gui *Gui) resetState(startArgs appTypes.StartArgs) types.Context {
|
|||
// RefreshHelper.onUIThreadUnlessRepoChanged).
|
||||
gui.repoGeneration.Add(1)
|
||||
|
||||
// Un-highlight the current view if there is one. The reason we do this is
|
||||
// that the repo we are switching to might have a different view focused,
|
||||
// and would then show an inactive highlight for the previous view.
|
||||
if oldCurrentView := gui.g.CurrentView(); oldCurrentView != nil {
|
||||
oldCurrentView.Highlight = false
|
||||
}
|
||||
|
||||
worktreePath := gui.git.RepoPaths.WorktreePath()
|
||||
|
||||
if state := gui.RepoStateMap[Repo(worktreePath)]; state != nil {
|
||||
|
|
|
|||
Loading…
Reference in a new issue