diff options
Diffstat (limited to 'toolkit/gocui/click.go')
| -rw-r--r-- | toolkit/gocui/click.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/toolkit/gocui/click.go b/toolkit/gocui/click.go index e32825a..ce61bb7 100644 --- a/toolkit/gocui/click.go +++ b/toolkit/gocui/click.go @@ -23,9 +23,9 @@ func (w *cuiWidget) doWidgetClick() { case toolkit.Tab: w.redoBox(true) w.toggleTree() - - // w.toggleTree() - // me.rootNode.redoColor(true) + case toolkit.Grid: + w.redoBox(true) + w.toggleTree() case toolkit.Box: // w.showWidgetPlacement(logNow, "drawTree()") if (w.horizontal) { @@ -125,8 +125,8 @@ func ctrlDown(g *gocui.Gui, v *gocui.View) error { // find buttons that are below where the mouse button click f = func(widget *cuiWidget) { // if ((widget.logicalSize.w0 < w) && (w < widget.logicalSize.w1)) { - if ((widget.realSize.w0 < w) && (w < widget.realSize.w1) && - (widget.realSize.h0 < h) && (h < widget.realSize.h1)) { + if ((widget.realSize.w0 <= w) && (w <= widget.realSize.w1) && + (widget.realSize.h0 <= h) && (h <= widget.realSize.h1)) { widgets = append(widgets, widget) found = widget } @@ -137,8 +137,8 @@ func ctrlDown(g *gocui.Gui, v *gocui.View) error { } f(me.rootNode) var t string - for i, widget := range widgets { - log(logNow, "ctrlDown() FOUND widget", i, widget.name) + for _, widget := range widgets { + log(logNow, "ctrlDown() FOUND widget", widget.id, widget.name) t += widget.cuiName + " " + widget.name + "\n" // widget.showWidgetPlacement(logNow, "drawTree()") } |
