From 0aa82f5ba56f9e393e681971115881cc185f20c8 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Sat, 8 Feb 2025 08:07:03 -0600 Subject: trying to delay on mouse drag --- eventMouseClick.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'eventMouseClick.go') diff --git a/eventMouseClick.go b/eventMouseClick.go index d2562c0..675aeac 100644 --- a/eventMouseClick.go +++ b/eventMouseClick.go @@ -31,6 +31,8 @@ func (tk *guiWidget) DeleteNode() { func (tk *guiWidget) doWindowClick() { w, h := me.baseGui.MousePosition() + tk.dumpWidget(fmt.Sprintf("doWindowClick(%d,%d)", w, h)) + // compare the mouse location to the 'X' indicator to close the window if tk.gocuiSize.inRect(w, h) { offset := w - tk.gocuiSize.w1 @@ -57,7 +59,6 @@ func (tk *guiWidget) doWindowClick() { } } else { tk.window.collapsed = false - // tk.dumpWidget(fmt.Sprintf("No (%d,%d)", w, h)) } // if there is a current window, hide it if me.currentWindow != nil { @@ -75,6 +76,7 @@ func (tk *guiWidget) doWindowClick() { // the debugging is way way better now with it being visible in the Stdout window // so now it's possible to redo all this and make it better func (tk *guiWidget) doWidgetClick(w int, h int) { + tk.dumpWidget(fmt.Sprintf("doWidgetClick(%d,%d)", w, h)) switch tk.node.WidgetType { case widget.Window: tk.doWindowClick() -- cgit v1.2.3