summaryrefslogtreecommitdiffstats
path: root/pkg/gui/commit_files_panel.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2022-02-05 16:56:36 +1100
committerJesse Duffield <jessedduffield@gmail.com>2022-03-17 19:13:40 +1100
commit145c69d9ae32ec8fbdd6d1e6116efec466a0a709 (patch)
treeb5f3e33943c739a6aee6d04b9a90fb6f1f363502 /pkg/gui/commit_files_panel.go
parent482bdc4f1ea5448c5e98697ae66221e544ea40dd (diff)
working again
Diffstat (limited to 'pkg/gui/commit_files_panel.go')
-rw-r--r--pkg/gui/commit_files_panel.go10
1 files changed, 8 insertions, 2 deletions
diff --git a/pkg/gui/commit_files_panel.go b/pkg/gui/commit_files_panel.go
index 05f23374c..d4cef7b14 100644
--- a/pkg/gui/commit_files_panel.go
+++ b/pkg/gui/commit_files_panel.go
@@ -46,10 +46,16 @@ func (gui *Gui) commitFilesRenderToMain() error {
cmdObj := gui.git.WorkingTree.ShowFileDiffCmdObj(from, to, reverse, node.GetPath(), false)
task := NewRunPtyTask(cmdObj.GetCmd())
+ mainContext := gui.State.Contexts.Normal
+ if node.File != nil {
+ mainContext = gui.State.Contexts.PatchBuilding
+ }
+
return gui.refreshMainViews(refreshMainOpts{
main: &viewUpdateOpts{
- title: "Patch",
- task: task,
+ title: "Patch",
+ task: task,
+ context: mainContext,
},
secondary: gui.secondaryPatchPanelUpdateOpts(),
})