view/envelope: open message/rfc822 attachments in subview instead of new tab

pull/254/head
Manos Pitsidianakis 2023-07-10 08:34:35 +03:00
parent d93ee413a7
commit 74e15316db
Signed by: Manos Pitsidianakis
GPG Key ID: 7729C7707F7E09D0
1 changed files with 9 additions and 9 deletions

View File

@ -1451,15 +1451,15 @@ impl Component for EnvelopeView {
ContentType::MessageRfc822 => {
match Mail::new(attachment.body().to_vec(), Some(Flag::SEEN)) {
Ok(wrapper) => {
context.replies.push_back(UIEvent::Action(Tab(New(Some(
Box::new(EnvelopeView::new(
wrapper,
None,
None,
Some(self.view_settings.clone()),
context.main_loop_handler.clone(),
)),
)))));
self.mode = ViewMode::Subview;
self.subview = Some(Box::new(EnvelopeView::new(
wrapper,
None,
None,
Some(self.view_settings.clone()),
context.main_loop_handler.clone(),
)));
self.set_dirty(true);
}
Err(e) => {
context.replies.push_back(UIEvent::StatusEvent(