mirror of
https://github.com/atuinsh/atuin.git
synced 2024-11-26 10:15:37 +01:00
Add ctrl-k and ctrl-j for up and down (#394)
This commit is contained in:
parent
25afb5b2ed
commit
e9d2ec4bf7
@ -343,7 +343,7 @@ async fn key_handler(
|
||||
|
||||
query_results(app, search_mode, db).await.unwrap();
|
||||
}
|
||||
Key::Down | Key::Ctrl('n') => {
|
||||
Key::Down | Key::Ctrl('n' | 'j') => {
|
||||
let i = match app.results_state.selected() {
|
||||
Some(i) => {
|
||||
if i == 0 {
|
||||
@ -356,7 +356,7 @@ async fn key_handler(
|
||||
};
|
||||
app.results_state.select(Some(i));
|
||||
}
|
||||
Key::Up | Key::Ctrl('p') => {
|
||||
Key::Up | Key::Ctrl('p' | 'k') => {
|
||||
let i = match app.results_state.selected() {
|
||||
Some(i) => {
|
||||
if i >= app.results.len() - 1 {
|
||||
|
Loading…
Reference in New Issue
Block a user