Browse Source

ui/accounts: show totals in account tab

tags/pre-alpha-0.4.0
Manos Pitsidianakis 4 months ago
parent
commit
c64ce58653
WARNING! Although there is a key with this ID in the database it does not verify this commit! This commit is SUSPICIOUS. GPG Key ID: 73627C2F690DF710
1 changed files with 4 additions and 21 deletions
  1. +4
    -21
      ui/src/components/mail/accounts.rs

+ 4
- 21
ui/src/components/mail/accounts.rs View File

@@ -276,18 +276,10 @@ impl AccountsPanel {
self.content[(2, h + y + 1)].set_ch(' ');
}
}
let (x, _) = write_string_to_grid(
"- Settings",
&mut self.content,
Color::Default,
Color::Default,
Attr::Default,
((5, y + 3), (120 - 2, y + 3)),
true,
);
write_string_to_grid(
&format!(
"total {}",
"Messages total {}, unseen {}",
a.collection.len(),
a.collection
.envelopes
.values()
@@ -298,11 +290,11 @@ impl AccountsPanel {
Color::Default,
Color::Default,
Attr::Default,
((10 + x, y + 3), (120 - 2, y + 3)),
((5, y + 3), (120 - 2, y + 3)),
true,
);
write_string_to_grid(
"- Contacts",
&format!("Contacts total {}", a.address_book.len()),
&mut self.content,
Color::Default,
Color::Default,
@@ -310,15 +302,6 @@ impl AccountsPanel {
((5, y + 4), (120 - 2, y + 4)),
true,
);
write_string_to_grid(
"- Mailing Lists",
&mut self.content,
Color::Default,
Color::Default,
Attr::Default,
((5, y + 5), (120 - 2, y + 5)),
true,
);
}
}
}

Loading…
Cancel
Save