summaryrefslogtreecommitdiff
path: root/toolkit/gocui/plugin.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2023-04-26 21:36:56 -0500
committerJeff Carr <[email protected]>2023-04-26 21:36:56 -0500
commit076b0e4077f3854f7c5e487e83cfd590d14e7aeb (patch)
tree6fb05b18c1cb896b39dc359fa32ec6874fc8ac29 /toolkit/gocui/plugin.go
parente3cf42f1da9ec0ed07a7f346a0ce9c9ff10295c1 (diff)
gocui: standard close
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'toolkit/gocui/plugin.go')
-rw-r--r--toolkit/gocui/plugin.go9
1 files changed, 1 insertions, 8 deletions
diff --git a/toolkit/gocui/plugin.go b/toolkit/gocui/plugin.go
index f204e09..27d96b9 100644
--- a/toolkit/gocui/plugin.go
+++ b/toolkit/gocui/plugin.go
@@ -1,16 +1,11 @@
package main
import (
- "os"
// if you include more than just this import
// then your plugin might be doing something un-ideal (just a guess from 2023/02/27)
"git.wit.org/wit/gui/toolkit"
)
-func Quit() {
- me.baseGui.Close()
-}
-
func action(a *toolkit.Action) {
log(logInfo, "action() START", a.WidgetId, a.ActionType, a.WidgetType, a.Name)
w := findWidget(a.WidgetId, me.rootNode)
@@ -41,9 +36,7 @@ func action(a *toolkit.Action) {
log(logNow, "attempt to move() =", a.ActionType, a.WidgetType, a.Name)
case toolkit.CloseToolkit:
log(logNow, "attempting to close the plugin and release stdout and stderr")
- me.baseGui.Close()
- // defer outf.Close()
- setOutput(os.Stdout)
+ standardExit()
default:
log(logError, "action() Unknown =", a.ActionType, a.WidgetType, a.Name)
}