move complete

Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
Jeff Carr 2024-01-03 13:25:47 -06:00
parent 144c12a2cf
commit 225f5393fd
2 changed files with 6 additions and 10 deletions

View File

@ -17,6 +17,11 @@ type ArgsDebugger struct {
Debugger bool `arg:"--debugger" help:"open the debugger window"`
}
// returns true if --gui-debug was passed from the command line
func ArgDebug() bool {
return argDebugger.Debugger
}
func init() {
arg.Register(&argDebugger)

View File

@ -17,7 +17,7 @@ func DebugWindow(p *gui.Node) {
bugWin.StandardClose()
bugTab = DebugWindow2(bugWin, "Debug Tab")
bugTab.StandardClose()
if gui.ArgDebug() {
if ArgDebug() {
log.SetTmp()
}
}
@ -34,15 +34,6 @@ func DebugWindow2(n *gui.Node, title string) *gui.Node {
//////////////////////// main debug things //////////////////////////////////
gog = newB.NewGroup("Debugging Windows:")
// generally useful debugging
cb := gog.NewCheckbox("Seperate windows")
cb.Custom = func() {
log.Log(BUG, "Custom() n.widget =", cb.Name, cb.B)
n.SetTabs(cb.B)
}
cb.Set(false)
n.SetTabs(false)
gog.NewButton("logging", func () {
DebugFlags(myGui)
})