diff options
author | Kevin Sjöberg | 2021-06-08 18:50:23 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2021-06-09 00:54:22 +0000 |
commit | 1bb9977fafc145448e4ea77f4cb3a132d1542bfa (patch) | |
tree | 6c5e7c536052e951ee4c235cdca5053703d9af40 | |
parent | 29962a5bd9e0c558ecd7dfa6c2eeec485e5ac890 (diff) |
Match keybindings of menu
-rw-r--r-- | helix-term/src/ui/picker.rs | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/helix-term/src/ui/picker.rs b/helix-term/src/ui/picker.rs index 494753c5..0674f4cc 100644 --- a/helix-term/src/ui/picker.rs +++ b/helix-term/src/ui/picker.rs @@ -151,7 +151,11 @@ impl<T: 'static> Component for Picker<T> { code: KeyCode::Up, .. } | KeyEvent { - code: KeyCode::Char('k'), + code: KeyCode::BackTab, + .. + } + | KeyEvent { + code: KeyCode::Char('p'), modifiers: KeyModifiers::CONTROL, } => self.move_up(), KeyEvent { @@ -159,11 +163,18 @@ impl<T: 'static> Component for Picker<T> { .. } | KeyEvent { - code: KeyCode::Char('j'), + code: KeyCode::Tab, .. + } + | KeyEvent { + code: KeyCode::Char('n'), modifiers: KeyModifiers::CONTROL, } => self.move_down(), KeyEvent { code: KeyCode::Esc, .. + } + | KeyEvent { + code: KeyCode::Char('c'), + modifiers: KeyModifiers::CONTROL, } => { return close_fn; } |