From b8db653981ff92a13d52ca8549f68685e1183deb Mon Sep 17 00:00:00 2001 From: rouggy Date: Mon, 20 Jul 2026 15:51:32 +0200 Subject: [PATCH] fix: ESC now stops the active CW engine (Icom/Flex), not just WinKeyer The ESC abort keyed WinkeyerStop unconditionally, so it never aborted the Icom CI-V or Flex CWX keyer. Route the stop through cwSource like the panel Stop button does. --- frontend/src/App.tsx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index 7319f51..8bceaf1 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -2888,7 +2888,14 @@ export default function App() { const keyerLive = wkActiveRef.current; // ESC aborts the current CW transmission AND the auto-call loop, so it // won't resend after the gap — you must click a CQ macro to restart it. - if (keyerLive) { stopAutoCall(); WinkeyerStop().catch(() => {}); } + // Route the abort to whichever engine is active (was WinKeyer-only, so + // ESC didn't stop the Icom or Flex keyer). + if (keyerLive) { + stopAutoCall(); + if (cwSourceRef.current === 'icom') IcomStopCW().catch(() => {}); + else if (cwSourceRef.current === 'flex') FlexStopCW().catch(() => {}); + else WinkeyerStop().catch(() => {}); + } if (!keyerLive || wkEscClearsRef.current) { resetEntry(); callsignRef.current?.focus();