Skip to content

Commit 59ecb1e

Browse files
committed
fix(multiverse): Add a shortcut to mark rooms as read back
1 parent 7adf60d commit 59ecb1e

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

labs/multiverse/src/main.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -352,6 +352,10 @@ impl App {
352352
self.room_view.set_selected_room(room_id);
353353
}
354354

355+
Event::Key(KeyEvent { code: Char('m'), modifiers: KeyModifiers::ALT, .. }) => {
356+
self.room_view.mark_as_read().await
357+
}
358+
355359
Event::Key(KeyEvent { code: Char('q'), modifiers: KeyModifiers::CONTROL, .. }) => {
356360
if !matches!(self.state.global_mode, GlobalMode::Default) {
357361
self.set_global_mode(GlobalMode::Default);

labs/multiverse/src/widgets/help.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ impl Widget for &mut HelpView {
2727
Row::new(vec![Cell::from("ALT-l"), Cell::from("Open the linked chunk details view")]),
2828
Row::new(vec![Cell::from("ALT-e"), Cell::from("Open the events details view")]),
2929
Row::new(vec![Cell::from("ALT-r"), Cell::from("Open the read receipt details view")]),
30+
Row::new(vec![
31+
Cell::from("ALT-m"),
32+
Cell::from("Mark the currently selected room as read"),
33+
]),
3034
Row::new(vec![Cell::from("Ctrl-q"), Cell::from("Quit Multiverse")]),
3135
Row::new(vec![
3236
Cell::from("Ctrl-j / Ctrl-down"),

0 commit comments

Comments
 (0)