mirror of
https://git.meli.delivery/meli/meli
synced 2024-11-17 03:26:20 +00:00
Add set_seen shortcut in CompactListing
This commit is contained in:
parent
c7bcb9e553
commit
2b5472adc3
@ -1093,6 +1093,12 @@ impl Component for CompactListing {
|
||||
self.movement = Some(PageMovement::End);
|
||||
self.set_dirty();
|
||||
}
|
||||
UIEvent::Input(ref key) if *key == shortcuts["set_seen"] => {
|
||||
let thread_hash = self.get_thread_under_cursor(self.cursor_pos.2, context);
|
||||
self.perform_action(context, thread_hash, &ListingAction::SetSeen);
|
||||
self.row_updates.push(thread_hash);
|
||||
self.set_dirty();
|
||||
}
|
||||
UIEvent::Input(ref k) if self.unfocused && *k == shortcuts["exit_thread"] => {
|
||||
self.unfocused = false;
|
||||
self.dirty = true;
|
||||
@ -1331,6 +1337,14 @@ impl Component for CompactListing {
|
||||
Key::Char('v')
|
||||
},
|
||||
),
|
||||
(
|
||||
"set_seen",
|
||||
if let Some(key) = config_map.get("set_seen") {
|
||||
(*key).clone()
|
||||
} else {
|
||||
Key::Char('n')
|
||||
},
|
||||
),
|
||||
]
|
||||
.iter()
|
||||
.cloned()
|
||||
|
Loading…
Reference in New Issue
Block a user