diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2020-08-19 22:27:31 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2020-08-23 14:29:18 +1000 |
commit | 2855b5b4d5eb757c4b6eb359b862ebb6fa9dffb4 (patch) | |
tree | ce92927024043ab4037e9ee5055a712fca54f247 /pkg/gui/status_panel.go | |
parent | 419cb9feb84d98633e5a5b15776b4956c5068a58 (diff) |
standardise diffmode
Diffstat (limited to 'pkg/gui/status_panel.go')
-rw-r--r-- | pkg/gui/status_panel.go | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/pkg/gui/status_panel.go b/pkg/gui/status_panel.go index 0a33b84ff..6159907e9 100644 --- a/pkg/gui/status_panel.go +++ b/pkg/gui/status_panel.go @@ -61,6 +61,11 @@ func (gui *Gui) handleCheckForUpdate(g *gocui.Gui, v *gocui.View) error { } func (gui *Gui) handleStatusClick(g *gocui.Gui, v *gocui.View) error { + // TODO: move into some abstraction (status is currently not a listViewContext where a lot of this code lives) + if gui.popupPanelFocused() { + return nil + } + currentBranch := gui.currentBranch() if err := gui.switchContext(gui.Contexts.Status.Context); err != nil { @@ -89,14 +94,11 @@ func (gui *Gui) handleStatusClick(g *gocui.Gui, v *gocui.View) error { } func (gui *Gui) handleStatusSelect() error { + // TODO: move into some abstraction (status is currently not a listViewContext where a lot of this code lives) if gui.popupPanelFocused() { return nil } - if gui.inDiffMode() { - return gui.renderDiff() - } - magenta := color.New(color.FgMagenta) dashboardString := strings.Join( |