diff options
Diffstat (limited to 'eventMouseClick.go')
| -rw-r--r-- | eventMouseClick.go | 65 |
1 files changed, 30 insertions, 35 deletions
diff --git a/eventMouseClick.go b/eventMouseClick.go index bfff2d4..aa8be6e 100644 --- a/eventMouseClick.go +++ b/eventMouseClick.go @@ -30,16 +30,18 @@ func (tk *guiWidget) doWidgetClick(w int, h int) { tk.redrawWindow(w-2, h-2) // TODO: fix these hard coded things with offsets return case widget.Group: - if tk.active { - tk.active = false - tk.placeWidgets(tk.startW, tk.startH) - tk.showWidgets() - } else { - tk.active = true - for _, child := range tk.children { - child.hideWidgets() + /* + if tk.active { + tk.active = false + tk.placeWidgets(tk.startW, tk.startH) + tk.showWidgets() + } else { + tk.active = true + for _, child := range tk.children { + child.hideWidgets() + } } - } + */ case widget.Checkbox: if tk.node.State.Checked { log.Log(WARN, "checkbox is being set to false") @@ -52,43 +54,36 @@ func (tk *guiWidget) doWidgetClick(w int, h int) { } me.myTree.SendUserEvent(tk.node) case widget.Grid: - newR := tk.realGocuiSize() - - // w,h := n.logicalSize() - // w := newR.w1 - newR.w0 - // h := newR.h1 - newR.h0 - - tk.placeGrid(newR.w0, newR.h0) - tk.showWidgets() + /* + newR := tk.realGocuiSize() + tk.placeGrid(newR.w0, newR.h0) + tk.showWidgets() + */ case widget.Box: - if tk.node.State.Direction == widget.Horizontal { - log.Log(GOCUI, "BOX IS HORIZONTAL", tk.String()) - } else { - log.Log(GOCUI, "BOX IS VERTICAL", tk.String()) - } - tk.placeWidgets(tk.startW, tk.startH) - tk.toggleTree() + /* + if tk.node.State.Direction == widget.Horizontal { + log.Log(GOCUI, "BOX IS HORIZONTAL", tk.String()) + } else { + log.Log(GOCUI, "BOX IS VERTICAL", tk.String()) + } + tk.placeWidgets(tk.startW, tk.startH) + tk.toggleTree() + */ case widget.Button: - // doUserEvent(n) me.myTree.SendFromUser(tk.node) case widget.Combobox: - log.Log(GOCUI, "do the combobox here") tk.showDropdown() - me.dropdownW = tk case widget.Dropdown: - // log.Log(GOCUI, "do the dropdown here") tk.showDropdown() - me.dropdownW = tk case widget.Stdout: - log.Log(GOCUI, "stdout widget found!") - tk.dumpWidget("stdout click") + /* + log.Log(GOCUI, "stdout widget found!") + tk.dumpWidget("stdout click") + */ case widget.Flag: - // log.Log(GOCUI, "flag widget found!") tk.dropdownClicked(w, h) - // got_ := dropdownClicked(w, h) - // log.Log(GOCUI, "flag click got", got) default: - tk.dumpWidget("blank click()") + tk.dumpWidget("undef click()") } } |
