Browse Source

statusbar: delete num buffer chars with Backspace

jmap-eventsource
Manos Pitsidianakis 1 year ago
parent
commit
9f39a7c5a1
Signed by: epilys GPG Key ID: 73627C2F690DF710
  1. 9
      src/components/mail/listing.rs

9
src/components/mail/listing.rs

@ -1229,6 +1229,15 @@ impl Component for Listing {
self.get_status(context),
)));
}
UIEvent::Input(Key::Backspace) if !self.cmd_buf.is_empty() => {
self.cmd_buf.pop();
context
.replies
.push_back(UIEvent::StatusEvent(StatusEvent::BufSet(
self.cmd_buf.clone(),
)));
return true;
}
UIEvent::Input(Key::Esc) | UIEvent::Input(Key::Alt('')) if !self.cmd_buf.is_empty() => {
self.cmd_buf.clear();
self.component.set_command_modifier(false);

Loading…
Cancel
Save