summaryrefslogtreecommitdiff
path: root/junk1.go
diff options
context:
space:
mode:
Diffstat (limited to 'junk1.go')
-rw-r--r--junk1.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/junk1.go b/junk1.go
index de8c104..1ed2d7e 100644
--- a/junk1.go
+++ b/junk1.go
@@ -5,6 +5,7 @@
package main
import (
+ "fmt"
"syscall"
"github.com/awesome-gocui/gocui"
@@ -99,6 +100,15 @@ func addDebugKeys(g *gocui.Gui) {
return nil
})
+ // find under mouse
+ g.SetKeybinding("", 'f', gocui.ModNone,
+ func(g *gocui.Gui, v *gocui.View) error {
+ w, h := g.MousePosition()
+ for _, tk := range findByXY(w, h) {
+ log.Log(GOCUI, fmt.Sprintf("findByXY() msgDown() %s wId=%d cuiName=%s at (%d,%d)", tk.WidgetType, tk.node.WidgetId, tk.cuiName, w, h))
+ }
+ return nil
+ })
// hide all widgets
g.SetKeybinding("", 'h', gocui.ModNone,
func(g *gocui.Gui, v *gocui.View) error {