Skip to content

Commit

Permalink
🔧 Add ^J and ^K to select next and previous entry (#69)
Browse files Browse the repository at this point in the history
  • Loading branch information
a-kenji authored Feb 27, 2024
1 parent 324e01f commit fe14fe0
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,19 @@ impl Application for Centerpiece {
iced::Event::Keyboard(iced::keyboard::Event::KeyPressed {
key_code: iced::keyboard::KeyCode::Up,
..
})
| iced::Event::Keyboard(iced::keyboard::Event::KeyPressed {
key_code: iced::keyboard::KeyCode::K,
modifiers: iced::keyboard::Modifiers::CTRL,
}) => self.select_previous_entry(),

iced::Event::Keyboard(iced::keyboard::Event::KeyPressed {
key_code: iced::keyboard::KeyCode::Down,
..
})
| iced::Event::Keyboard(iced::keyboard::Event::KeyPressed {
key_code: iced::keyboard::KeyCode::J,
modifiers: iced::keyboard::Modifiers::CTRL,
}) => self.select_next_entry(),

iced::Event::Keyboard(iced::keyboard::Event::KeyPressed {
Expand Down

0 comments on commit fe14fe0

Please sign in to comment.