summaryrefslogtreecommitdiffstats
path: root/pkg/gui/staging_panel.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2020-08-18 08:26:40 +1000
committerJesse Duffield <jessedduffield@gmail.com>2020-08-23 14:29:18 +1000
commit0f7b2c45d773989229cb84a0147232962c6ae0e0 (patch)
treebec3948a7cc786d5d7fb6cf5cb2e6b14a832f6a8 /pkg/gui/staging_panel.go
parenta12d18146ccd2847ef04377703baff58e209373d (diff)
centralise split main panel code
Diffstat (limited to 'pkg/gui/staging_panel.go')
-rw-r--r--pkg/gui/staging_panel.go9
1 files changed, 1 insertions, 8 deletions
diff --git a/pkg/gui/staging_panel.go b/pkg/gui/staging_panel.go
index 47a63f40f..4c8cb3571 100644
--- a/pkg/gui/staging_panel.go
+++ b/pkg/gui/staging_panel.go
@@ -8,17 +8,10 @@ import (
)
func (gui *Gui) refreshStagingPanel(forceSecondaryFocused bool, selectedLineIdx int) error {
- gui.State.SplitMainPanel = true
+ gui.splitMainPanel(true)
state := gui.State.Panels.LineByLine
- // // We need to force focus here because the confirmation panel for safely staging lines does not return focus automatically.
- // // This is because if we tell it to return focus it will unconditionally return it to the main panel which may not be what we want
- // // e.g. in the event that there's nothing left to stage.
- // if err := gui.switchContext(nil, gui.getMainView()); err != nil {
- // return err
- // }
-
file := gui.getSelectedFile()
if file == nil {
return gui.handleStagingEscape()