fix: pass manual IGC status after showing language mismatch popup

This commit is contained in:
ggurdin 2026-01-20 13:12:25 -05:00
parent e07bcc358f
commit 86b69a67fa
No known key found for this signature in database
GPG key ID: A01CB41737CBB478

View file

@ -2237,7 +2237,7 @@ class ChatController extends State<ChatPageWithRoom>
bool autosend = false,
}) async {
if (shouldShowLanguageMismatchPopupByActivity) {
return showLanguageMismatchPopup();
return showLanguageMismatchPopup(manual: manual);
}
await choreographer.requestWritingAssistance(manual: manual);
@ -2250,7 +2250,7 @@ class ChatController extends State<ChatPageWithRoom>
}
}
void showLanguageMismatchPopup() {
void showLanguageMismatchPopup({bool manual = false}) {
if (!shouldShowLanguageMismatchPopupByActivity) {
return;
}
@ -2263,7 +2263,7 @@ class ChatController extends State<ChatPageWithRoom>
message: L10n.of(context).languageMismatchDesc,
targetLanguage: targetLanguage,
onConfirm: () => WidgetsBinding.instance.addPostFrameCallback(
(_) => onRequestWritingAssistance(manual: false, autosend: true),
(_) => onRequestWritingAssistance(manual: manual, autosend: true),
),
);
}