Add ctrl-j as enter

This commit is contained in:
Austen Adler 2023-09-17 20:33:39 -04:00
parent b8c2f24f6e
commit cd1eb22a7d

View File

@ -381,6 +381,10 @@ fn handle_key(app: &mut App, key: KeyEvent) -> CalculatorResult<CalculatorRespon
code: KeyCode::Enter,
modifiers: KeyModifiers::NONE,
}
| KeyEvent {
code: KeyCode::Char('j'),
modifiers: KeyModifiers::CONTROL,
}
| KeyEvent {
code: KeyCode::Char(' '),
modifiers: KeyModifiers::NONE,
@ -419,7 +423,7 @@ fn handle_key(app: &mut App, key: KeyEvent) -> CalculatorResult<CalculatorRespon
app.calculator.take_input(c)?;
}
}
_ => {}
_key_event => {}
},
(AppState::Help, _) => match key {
KeyEvent {