From a08bbaf04ff536e8fae3ab5396dc54c290945301 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Wed, 3 Jan 2024 13:37:03 -0600 Subject: all debug stuff moved to 'go.wit.com/gui/debugger' I finally was able to clean out all the debugging code and make a clean, new GO debugger. It's quite nice I think. Well, it's useful to me at any rate. 2024 New Years wish: someone contributes code to improve it Signed-off-by: Jeff Carr --- main.go | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) (limited to 'main.go') diff --git a/main.go b/main.go index c92cddf..b059268 100644 --- a/main.go +++ b/main.go @@ -2,7 +2,7 @@ package gui import ( "os" - "time" + "go.wit.com/gui/gui/toolkit" ) @@ -49,7 +49,7 @@ func watchCallback() { } if (a.ActionType == toolkit.EnableDebug) { log(logInfo, "doUserEvent() Enable Debugging Window") - DebugWindow() + // DebugWindow() break } @@ -124,9 +124,6 @@ func New() *Node { // try to load andlabs, if that doesn't work, fall back to the console func (n *Node) Default() *Node { - // start the GUI debugger if --gui-debug is true - checkDebug() - if (argGui.GuiPlugin != "") { log(logError, "New.Default() try toolkit =", argGui.GuiPlugin) return n.LoadToolkit(argGui.GuiPlugin) @@ -146,26 +143,6 @@ func (n *Node) Default() *Node { return n } -func checkDebug() { - if ! ArgDebug() { - return - } - f := func() { - log(debugGui, "wit/gui START DEBUG") - log(debugGui, "wit/gui START DEBUG") - log(debugGui, "wit/gui START DEBUG") - time.Sleep(2 * time.Second) - log(debugGui, "wit/gui START DEBUG") - log(debugGui, "wit/gui START DEBUG") - log(debugGui, "wit/gui START DEBUG") - DebugWindow() - log(debugGui, "wit/gui END DEBUG") - log(debugGui, "wit/gui END DEBUG") - log(debugGui, "wit/gui END DEBUG") - } - go f() -} - // The window is destroyed but the application does not quit func (n *Node) StandardClose() { log(debugGui, "wit/gui Standard Window Close. name =", n.Name) -- cgit v1.2.3