From c08ca00c36d06d7b1bbd5ce73d4d4dc3ce157e1c Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Mon, 24 Aug 2026 21:19:05 +0200 Subject: fix(compose): a resumed draft does not re-seed on a From: change A resumed draft kept m_signatureChosen false, so a From: change re-seeded the signature and rewrote what the user had saved, inserting the new account's where the saved block no longer matched a known file. The draft is the user's deliberate prior state and must not follow a From: change, so the draft branch marks it chosen. --- src/composewindow.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/composewindow.cpp b/src/composewindow.cpp index 94a3f46..d781e52 100644 --- a/src/composewindow.cpp +++ b/src/composewindow.cpp @@ -792,6 +792,11 @@ void ComposeWindow::seedSignature() // verbatim. Seeding again would append a second one. if (m_context.kind == ComposeContext::Kind::Draft) { none->setChecked(true); + // The draft IS the user's choice: its signature is deliberate prior + // state, so a From: change must not follow the new account and + // rewrite what was saved. Marking it chosen keeps the same invariant + // the switch actions set, without ever having run the switch. + m_signatureChosen = true; return; } -- cgit v1.2.3