From 86b0d4f0c27a11ecd85a805ca2b40907ecc74f88 Mon Sep 17 00:00:00 2001 From: Erik Kundt Date: Tue, 23 Jan 2024 11:19:01 +0100 Subject: [PATCH] patch-select: Cleanup operations --- bin/commands/patch/select/event.rs | 7 ------- bin/commands/patch/select/ui.rs | 9 +++------ 2 files changed, 3 insertions(+), 13 deletions(-) diff --git a/bin/commands/patch/select/event.rs b/bin/commands/patch/select/event.rs index 2fe20b7a..3b80edf6 100644 --- a/bin/commands/patch/select/event.rs +++ b/bin/commands/patch/select/event.rs @@ -118,13 +118,6 @@ impl tuirealm::Component for Widget { let output = Output::new(Some(PatchOperation::Checkout), PatchId::from(id)); Message::Quit(Some(output)) }), - Event::Keyboard(KeyEvent { - code: Key::Char('r'), - .. - }) => submit().map(|id| { - let output = Output::new(Some(PatchOperation::Review), PatchId::from(id)); - Message::Quit(Some(output)) - }), Event::Keyboard(KeyEvent { code: Key::Char('d'), .. diff --git a/bin/commands/patch/select/ui.rs b/bin/commands/patch/select/ui.rs index 23aa2c4e..eca5e7b3 100644 --- a/bin/commands/patch/select/ui.rs +++ b/bin/commands/patch/select/ui.rs @@ -39,8 +39,7 @@ impl IdSelect { tui::ui::shortcuts( &self.theme, vec![ - tui::ui::shortcut(&self.theme, "↑/↓", "navigate"), - tui::ui::shortcut(&self.theme, "enter", "show"), + tui::ui::shortcut(&self.theme, "enter", "select"), tui::ui::shortcut(&self.theme, "q", "quit"), ], ), @@ -90,13 +89,11 @@ impl OperationSelect { tui::ui::shortcuts( &self.theme, vec![ - tui::ui::shortcut(&self.theme, "↑/↓", "navigate"), tui::ui::shortcut(&self.theme, "enter", "show"), tui::ui::shortcut(&self.theme, "c", "checkout"), - tui::ui::shortcut(&self.theme, "r", "review"), - tui::ui::shortcut(&self.theme, "d", "delete"), - tui::ui::shortcut(&self.theme, "e", "edit"), tui::ui::shortcut(&self.theme, "m", "comment"), + tui::ui::shortcut(&self.theme, "e", "edit"), + tui::ui::shortcut(&self.theme, "d", "delete"), tui::ui::shortcut(&self.theme, "q", "quit"), ], ),