diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2022-08-07 11:34:53 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2022-08-07 12:05:51 +1000 |
commit | d73a236d7cefb942d8fc993eb80f2c90e0899b87 (patch) | |
tree | 2b9c3b7fa76a370d230497f17c8deeb20ae61346 /pkg/gui/gui_common.go | |
parent | fcf20f3b93cc77f0c35f122a29894c575ebb07a2 (diff) |
allow rendering to main panels from anywhere
Diffstat (limited to 'pkg/gui/gui_common.go')
-rw-r--r-- | pkg/gui/gui_common.go | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/pkg/gui/gui_common.go b/pkg/gui/gui_common.go index 2b7226034..835aa4f54 100644 --- a/pkg/gui/gui_common.go +++ b/pkg/gui/gui_common.go @@ -89,3 +89,16 @@ func (self *guiCommon) OpenSearch() { func (self *guiCommon) OnUIThread(f func() error) { self.gui.onUIThread(f) } + +func (self *guiCommon) RenderToMainViews(opts types.RefreshMainOpts) error { + return self.gui.refreshMainViews(opts) +} + +func (self *guiCommon) MainViewPairs() types.MainViewPairs { + return types.MainViewPairs{ + Normal: self.gui.normalMainContextPair(), + Staging: self.gui.stagingMainContextPair(), + PatchBuilding: self.gui.patchBuildingMainContextPair(), + MergeConflicts: self.gui.mergingMainContextPair(), + } +} |