From 1f36cd7b6612177ac1bf2ff6ba8d538affce6420 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Sat, 18 Oct 2025 09:23:16 -0500 Subject: finally progress on proper integration here --- init.go | 13 +++++++------ structs.go | 16 ++++++++-------- 2 files changed, 15 insertions(+), 14 deletions(-) diff --git a/init.go b/init.go index 3a42811..47bbebd 100644 --- a/init.go +++ b/init.go @@ -323,9 +323,10 @@ func New() *Node { return me.rootNode } -func PreInit(postMustParse func(string) string) *Node { +// func PreInit(postMustParse func(string) string) *Node { +func PreInit() *Node { initNew() - me.postMustParse = postMustParse + // me.postMustParse = postMustParse return me.rootNode } @@ -333,10 +334,10 @@ func PreInit(postMustParse func(string) string) *Node { // try to load andlabs, if that doesn't work, fall back to the console func (n *Node) Default() (string, error) { var err error - ArgvGui.GuiPlugin = me.postMustParse("DEFAULT") - if me.postMustParse("VERBOSE") == "true" { - INFO.SetBool(true) - } + // ArgvGui.GuiPlugin = me.postMustParse("DEFAULT") + // if me.postMustParse("VERBOSE") == "true" { + INFO.SetBool(true) + // } if ArgvGui.GuiPlugin != "" { log.Log(WARN, "New.Default() try toolkit =", ArgvGui.GuiPlugin) diff --git a/structs.go b/structs.go index e8fc0a4..d690eda 100644 --- a/structs.go +++ b/structs.go @@ -26,14 +26,14 @@ import ( var me guiConfig type guiConfig struct { - rootNode *Node // This is the master node. The Binary Tree starts here - resFS embed.FS // option to pass in compiled plugins as embedded files - guiChan chan widget.Action // sets the chan for the plugins to call back too - tables []*guipb.Tables // a list of active protobuf tables - postMustParse func(string) string // used to get the final go-arg values after all user configuration is finished - counter int // used to make unique WidgetId's. this is a fun variable, but kinda dumb and should go - appPlugin string // deprecate. what the application would like the default GUI plugin to be - widgets *guipb.Widgets // switch to this and/or tree below + rootNode *Node // This is the master node. The Binary Tree starts here + resFS embed.FS // option to pass in compiled plugins as embedded files + guiChan chan widget.Action // sets the chan for the plugins to call back too + tables []*guipb.Tables // a list of active protobuf tables + // postMustParse func(string) string // used to get the final go-arg values after all user configuration is finished + counter int // used to make unique WidgetId's. this is a fun variable, but kinda dumb and should go + appPlugin string // deprecate. what the application would like the default GUI plugin to be + widgets *guipb.Widgets // switch to this and/or tree below // tree *guipb.Tree // the protobuf. switch to this. deprecate rootNode } -- cgit v1.2.3