diff options
| author | Jeff Carr <[email protected]> | 2025-02-06 14:35:01 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-02-06 14:35:01 -0600 |
| commit | bc15e6c87955d9ba837fe125ca2c53737afaf014 (patch) | |
| tree | 95cbcaa35ac4ec9b8599a810a12a541bb827493a /treeAdd.go | |
| parent | 1918dcbbdec3da55790314cb76fd1b1741b6586f (diff) | |
simple cleanups
Diffstat (limited to 'treeAdd.go')
| -rw-r--r-- | treeAdd.go | 52 |
1 files changed, 26 insertions, 26 deletions
@@ -31,71 +31,71 @@ func setFake(n *tree.Node) { // set the widget start width & height // func (n *node) addWidget(n *tree.Node) { func addWidget(n *tree.Node) { - var nw *guiWidget - nw = n.TK.(*guiWidget) + var tk *guiWidget + tk = n.TK.(*guiWidget) log.Log(INFO, "setStartWH() w.id =", n.WidgetId, "n.name", n.String()) switch n.WidgetType { case widget.Root: log.Log(INFO, "setStartWH() rootNode w.id =", n.WidgetId, "w.name", n.String()) - nw.color = &colorRoot + tk.color = &colorRoot setFake(n) return case widget.Flag: - nw.color = &colorFlag + tk.color = &colorFlag setFake(n) return case widget.Window: - nw.frame = false - // nw.color = &colorWindow - nw.setColor(&colorWindow) - me.newWindowTrigger <- true + tk.frame = false + // tk.color = &colorWindow + tk.setColor(&colorWindow) + me.newWindowTrigger <- tk redoWindows(0, 0) hideHelp() showHelp() return case widget.Stdout: - nw.labelN = "moreSTDOUT" + tk.labelN = "moreSTDOUT" n.State.ProgName = "moreSTDOUT" n.State.Label = "moreSTDOUT" return case widget.Tab: - nw.color = &colorTab + tk.color = &colorTab return case widget.Button: - nw.color = &colorButton + tk.color = &colorButton return case widget.Checkbox: - nw.color = &colorCheckbox - nw.labelN = "X " + n.State.Label + tk.color = &colorCheckbox + tk.labelN = "X " + n.State.Label return case widget.Dropdown: - nw.color = &colorDropdown + tk.color = &colorDropdown return case widget.Textbox: n.State.Label = "TEXTBOX" - nw.labelN = " " + n.State.Label - nw.color = &colorDropdown + tk.labelN = " " + n.State.Label + tk.color = &colorDropdown return case widget.Combobox: - nw.color = &colorCombobox + tk.color = &colorCombobox return case widget.Box: - nw.color = &colorBox - nw.isFake = true + tk.color = &colorBox + tk.isFake = true setFake(n) return case widget.Grid: - nw.color = &colorGrid - nw.isFake = true + tk.color = &colorGrid + tk.isFake = true setFake(n) return case widget.Group: - nw.color = &colorGroup - nw.frame = false + tk.color = &colorGroup + tk.frame = false return case widget.Label: - nw.color = &colorLabel - nw.frame = false + tk.color = &colorLabel + tk.frame = false return default: /* @@ -104,5 +104,5 @@ func addWidget(n *tree.Node) { } */ } - nw.dumpWidget("in addWidget()") + tk.dumpWidget("addWidget()unknown") } |
