mirror of
https://codeberg.org/icewind/logsmash.git
synced 2026-06-03 10:04:12 +02:00
make F the main search shortcut
This commit is contained in:
parent
831ae1a9e8
commit
89bf0a5de6
2 changed files with 6 additions and 4 deletions
|
|
@ -55,9 +55,9 @@ pub fn footer<'a>(app: &App<'a>, params: FooterParams<'a>) -> Table<'a> {
|
|||
|
||||
fn help(page: UiPage) -> &'static str {
|
||||
match page {
|
||||
UiPage::MatchList => "«Q» Exit - «Enter» Select - «F4» Filter - «E» Show parse errors",
|
||||
UiPage::Match => "«Q» Exit - «Enter» Select - «F4» Filter - «Esc» Back",
|
||||
UiPage::Logs => "«Q» Exit - «F4» Filter - «Esc» Back - «C» Copy log line",
|
||||
UiPage::MatchList => "«Q» Exit - «Enter» Select - «F» Filter - «E» Show parse errors",
|
||||
UiPage::Match => "«Q» Exit - «Enter» Select - «F» Filter - «Esc» Back",
|
||||
UiPage::Logs => "«Q» Exit - «F» Filter - «Esc» Back - «C» Copy log line",
|
||||
UiPage::Log => "«Q» Exit - «Esc» Back - «R» Toggle raw - «C» Copy log line",
|
||||
UiPage::Errors => "«Q» Exit - «Esc» Back - «C» Copy log line",
|
||||
}
|
||||
|
|
|
|||
|
|
@ -103,7 +103,9 @@ fn handle_events(page: UiPage, ui_state: &UiState) -> io::Result<Option<UiEvent>
|
|||
(_, KeyCode::Home) => Some(UiEvent::Up(usize::MAX, false)),
|
||||
(_, KeyCode::Enter | KeyCode::Right) => Some(UiEvent::Select),
|
||||
(Mode::Normal, KeyCode::Char('c')) => Some(UiEvent::Copy),
|
||||
(Mode::Normal, KeyCode::F(4)) => Some(UiEvent::EnterFilterMode),
|
||||
(Mode::Normal, KeyCode::F(4) | KeyCode::Char('f')) => {
|
||||
Some(UiEvent::EnterFilterMode)
|
||||
}
|
||||
|
||||
(Mode::FilterInput, KeyCode::Esc) => Some(UiEvent::ClearFilter),
|
||||
(Mode::FilterInput, KeyCode::F(4)) => Some(UiEvent::Back),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue