fix: a credential or host-key prompt takes Enter and Escape from the modals underneath

Every modal read Enter/Escape globally, so a prompt that popped up over a
dialog, the palette, Quick Connect or an SFTP dialog could be answered
and the modal underneath confirmed or dismissed by the same key press.
All modals except the prompts now read those keys through
chrome::modal_key, which yields while a prompt is on screen.
This commit is contained in:
Andy Dixon
2026-10-12 16:49:54 +01:00
parent d25746bb14
commit 15612a629e
7 changed files with 51 additions and 17 deletions
+1 -1
View File
@@ -266,7 +266,7 @@ impl Recordings {
let Some(r) = &self.confirm_delete else {
return;
};
let (mut yes, mut no) = (false, ctx.input(|i| i.key_pressed(Key::Escape)));
let (mut yes, mut no) = (false, crate::chrome::modal_key(ctx, Key::Escape));
let name = if r.title.is_empty() { r.id.clone() } else { r.title.clone() };
crate::chrome::modal(ctx, "rec-delete", 380.0, |ui| {
ui.label(RichText::new("Delete recording?").font(theme::semibold(15.0)));