summaryrefslogtreecommitdiffstats
path: root/ui/src/components
diff options
context:
space:
mode:
authorManos Pitsidianakis <el13635@mail.ntua.gr>2019-12-18 15:44:44 +0200
committerManos Pitsidianakis <el13635@mail.ntua.gr>2019-12-18 15:44:44 +0200
commit921191340516038a3152769444aa6963eefce75c (patch)
tree377af062c7194bca45c8d90391f69c3b85f61551 /ui/src/components
parent7eceef93e99c9f89326f2275b3c5f2aa0f4d73df (diff)
meli/backends: honor mailbox subscriptions in IMAP/JMAP
Diffstat (limited to 'ui/src/components')
-rw-r--r--ui/src/components/mail/status.rs53
1 files changed, 53 insertions, 0 deletions
diff --git a/ui/src/components/mail/status.rs b/ui/src/components/mail/status.rs
index d0734614..0917957f 100644
--- a/ui/src/components/mail/status.rs
+++ b/ui/src/components/mail/status.rs
@@ -446,6 +446,59 @@ impl Component for AccountStatus {
((_x, _y), (width - 1, height - 1)),
None,
);
+ line += 1;
+
+ write_string_to_grid(
+ "Special Mailboxes:",
+ &mut self.content,
+ Color::Default,
+ Color::Default,
+ Attr::Bold,
+ ((1, line), (width - 1, height - 1)),
+ None,
+ );
+ for (i, f) in a
+ .ref_folders
+ .values()
+ .filter(|f| f.special_usage() != SpecialUsageMailbox::Normal)
+ .enumerate()
+ {
+ line += 1;
+ write_string_to_grid(
+ &format!("{}: {}", f.path(), f.special_usage()),
+ &mut self.content,
+ Color::Default,
+ Color::Default,
+ Attr::Default,
+ ((1, line), (width - 1, height - 1)),
+ None,
+ );
+ }
+ line += 2;
+ write_string_to_grid(
+ "Subscribed folders:",
+ &mut self.content,
+ Color::Default,
+ Color::Default,
+ Attr::Bold,
+ ((1, line), (width - 1, height - 1)),
+ None,
+ );
+ line += 2;
+ for f in a.list_folders() {
+ if f.is_subscribed() {
+ write_string_to_grid(
+ f.path(),
+ &mut self.content,
+ Color::Default,
+ Color::Default,
+ Attr::Default,
+ ((1, line), (width - 1, height - 1)),
+ None,
+ );
+ line += 1;
+ }
+ }
line += 1;
if a.settings.account().format() == "imap" {