feat: add keybinds for tabs 1-10 (0 for 10th)

This commit is contained in:
2026-01-01 04:56:08 +02:00
parent c8b7d0ccbe
commit 691e30b4a4
3 changed files with 16 additions and 1 deletions

View File

@@ -12,6 +12,11 @@ pub struct KeybindsConfig {
pub switch_tab_3: String,
pub switch_tab_4: String,
pub switch_tab_5: String,
pub switch_tab_6: String,
pub switch_tab_7: String,
pub switch_tab_8: String,
pub switch_tab_9: String,
pub switch_tab_10: String,
pub toggle_torrent: String,
pub toggle_all: String,
pub delete: String,

View File

@@ -60,6 +60,11 @@ pub async fn get_action(key_event: KeyEvent, app: &mut App) -> Result<Option<Act
(Action::SwitchTab(2), &keybinds.switch_tab_3),
(Action::SwitchTab(3), &keybinds.switch_tab_4),
(Action::SwitchTab(4), &keybinds.switch_tab_5),
(Action::SwitchTab(5), &keybinds.switch_tab_6),
(Action::SwitchTab(6), &keybinds.switch_tab_7),
(Action::SwitchTab(7), &keybinds.switch_tab_8),
(Action::SwitchTab(8), &keybinds.switch_tab_9),
(Action::SwitchTab(9), &keybinds.switch_tab_10),
(Action::ToggleTorrent, &keybinds.toggle_torrent),
(Action::ToggleAll, &keybinds.toggle_all),
(Action::Delete(false), &keybinds.delete),