From a2401d7fd3e473bb9c29e1f7ad78d1678f463929 Mon Sep 17 00:00:00 2001 From: rouggy Date: Sun, 28 Jun 2026 20:55:59 +0200 Subject: [PATCH] fix: when in autocall cw writing a call stop transmission --- frontend/src/App.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index d12043d..6f4c461 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -2065,8 +2065,14 @@ export default function App() { // applyUdpCall saw current != lastUdpCall and refused every later UDP call. if (opts?.force) lastUdpCallRef.current = v.trim().toUpperCase(); // A callsign appeared (someone answered the CQ, or a spot was clicked) → - // stop auto-calling so we don't key over the contact. - if (v.trim() !== '') stopAutoCall(); + // stop auto-calling so we don't key over the contact. If a CQ was actually + // in flight, abort the current transmission too so it stops IMMEDIATELY + // rather than finishing the buffered call. (autoCallMacroRef flips to -1 on + // the first keystroke, so we only abort once.) + if (v.trim() !== '') { + if (autoCallMacroRef.current !== -1) WinkeyerStop().catch(() => {}); + stopAutoCall(); + } // No-op guard: external apps (MSHV/WSJT-X) re-broadcast the same DX call // on every status packet. If it matches what's already in the entry, // do nothing — otherwise we'd re-run the QRZ lookup, hit the cache and