diff --git a/eventMouseMove.go b/eventMouseMove.go index b7e35b1..0824faf 100644 --- a/eventMouseMove.go +++ b/eventMouseMove.go @@ -37,6 +37,7 @@ func mouseMove(g *gocui.Gui) { // log.Info("msgMouseDown == true") // plugin will segfault if you don't keep this inside a check for msgMouseDown // don't move this code out of here + var found bool = false for _, tk := range findByXY(w, h) { if tk.node.WidgetType == widget.Stdout { tk.moveNew(g) @@ -46,6 +47,10 @@ func mouseMove(g *gocui.Gui) { tk.moveNew(g) return } + found = true + } + if !found { + log.Info(fmt.Sprintf("findByXY() empty. nothing to move at (%d,%d)", w, h)) } }