Add escape as an alternative to back hotkey

This commit is contained in:
LagoLunatic 2024-11-28 18:55:26 -05:00 committed by Luke Street
parent 441b30070e
commit d7d7a7f14a
1 changed files with 3 additions and 1 deletions

View File

@ -20,7 +20,9 @@ pub fn back_pressed(ctx: &Context) -> bool {
return false;
}
ctx.input_mut(|i| {
i.key_pressed(Key::Backspace) || i.pointer.button_pressed(PointerButton::Extra1)
i.key_pressed(Key::Backspace)
|| i.key_pressed(Key::Escape)
|| i.pointer.button_pressed(PointerButton::Extra1)
})
}