From 062523f4684e81715dec844bb1983b7bde7df5fc Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Mon, 28 Sep 2026 16:08:36 -0300 Subject: Whether an exec came from a body travels with it, so every selection goes to the REPL The execute key and the middle click marked a global flag that the first execute cleared, so of several selections executed at once only the first reached a bound REPL and the rest ran as commands. Where an exec came from now goes with it, as acme's execute() asks of its Text (exec.c:122,169): builtins.Ctx carries from_body, runBuiltinFrom and executeFrom take it, the gestures set it, and chordEachSel sets it for each selection. Co-Authored-By: Claude Opus 5.5 --- src/mouse.zig | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/mouse.zig') diff --git a/src/mouse.zig b/src/mouse.zig index f222b5da..1cfe6dbb 100644 --- a/src/mouse.zig +++ b/src/mouse.zig @@ -720,9 +720,7 @@ fn dispatchPointerBuiltin( const operand = text orelse return; if (gesture) |g| if (reportGesture(p, id, cmd, operand, g.on_tag, g.operand, arg != null)) return; // A middle click on a body is the exec a bound REPL may take. - p.exec_from_body = cmd == config.exec_cmd and gesture != null and !gesture.?.on_tag; - defer p.exec_from_body = false; - exec.runBuiltin(p, cmd, id, "", exec.withArg(p, operand, arg)); + exec.runBuiltinFrom(p, cmd, id, "", exec.withArg(p, operand, arg), gesture != null and !gesture.?.on_tag); } fn mirrorTtySelection(p: *Pardes, pane: *Pane) void { -- cgit v1.3