diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2020-02-10 18:56:48 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2020-02-10 19:05:55 +1100 |
commit | efb26f8b60a2b6b807a00595cbd3ae8cbe587850 (patch) | |
tree | e9f851749b69df8b58a3d3471b664aadabb69738 /pkg/gui/branches_panel.go | |
parent | d9eb6e26823bd001d4e50c1343f810cd31bab566 (diff) |
refresh current branch graph when side panels refresh
Diffstat (limited to 'pkg/gui/branches_panel.go')
-rw-r--r-- | pkg/gui/branches_panel.go | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/pkg/gui/branches_panel.go b/pkg/gui/branches_panel.go index ff77c9cb4..8fa6b83ca 100644 --- a/pkg/gui/branches_panel.go +++ b/pkg/gui/branches_panel.go @@ -97,8 +97,7 @@ func (gui *Gui) refreshBranches(g *gocui.Gui) error { // TODO: if we're in the remotes view and we've just deleted a remote we need to refresh accordingly if gui.getBranchesView().Context == "local-branches" { - gui.refreshSelectedLine(&gui.State.Panels.Branches.SelectedLine, len(gui.State.Branches)) - if err := gui.RenderSelectedBranchUpstreamDifferences(); err != nil { + if err := gui.renderLocalBranchesWithSelection(); err != nil { return err } } @@ -112,10 +111,10 @@ func (gui *Gui) renderLocalBranchesWithSelection() error { branchesView := gui.getBranchesView() gui.refreshSelectedLine(&gui.State.Panels.Branches.SelectedLine, len(gui.State.Branches)) - if err := gui.renderListPanel(branchesView, gui.State.Branches); err != nil { + if err := gui.RenderSelectedBranchUpstreamDifferences(); err != nil { return err } - if gui.g.CurrentView() == branchesView && branchesView.Context == "local-branches" { + if gui.g.CurrentView() == branchesView { if err := gui.handleBranchSelect(gui.g, branchesView); err != nil { return err } |