diff options
| author | Jeff Carr <[email protected]> | 2025-02-03 00:07:48 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-02-03 00:07:48 -0600 |
| commit | c5e6c66338cdf7ddbd53dd64b265ab4a041ef59a (patch) | |
| tree | 08c325c268687cf28703458f9f12803c6c7c2999 /eventMouseMove.go | |
| parent | a5b3a934d2a2355ce2487f5b3ce52dff2f8a9047 (diff) | |
can almost drag two different things
Diffstat (limited to 'eventMouseMove.go')
| -rw-r--r-- | eventMouseMove.go | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/eventMouseMove.go b/eventMouseMove.go index 51835cb..7c383a5 100644 --- a/eventMouseMove.go +++ b/eventMouseMove.go @@ -53,7 +53,7 @@ func mouseMove(g *gocui.Gui) { } for _, tk := range findByXY(w, h) { if tk.node.WidgetType == widget.Stdout { - // currentDrag = tk + currentDrag = tk // tk.moveNew(g) return } @@ -90,12 +90,14 @@ func (tk *guiWidget) moveNew(g *gocui.Gui) { if tk.node.WidgetType == widget.Flag { log.Info("MOVE FLAG") log.Info("MOVE FLAG") + // outputW, outputH := tk.Size() + // g.SetView(tk.cuiName, w-xOffset, h-yOffset, w-xOffset+outputW+20, h-yOffset+outputH+me.FramePadH+20, 0) + g.SetView(tk.cuiName, w-3, h-3, w+20, h+20, 0) + tk.verifyRect() s := fmt.Sprintf("move(%dx%d) %s ###", w, h, tk.cuiName) tk.dumpWidget(s) - outputW, outputH := tk.Size() - g.SetView(tk.cuiName, w-xOffset, h-yOffset, w-xOffset+outputW+20, h-yOffset+outputH+me.FramePadH+20, 0) - me.startOutputW = w - xOffset - me.startOutputH = h - yOffset + // me.startOutputW = w - xOffset + // me.startOutputH = h - yOffset // g.SetViewOnBottom(tk.cuiName) return } else { |
