From 350b6358e29699721c636c18f8928acb68a05ade Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Mon, 14 Sep 2026 12:30:34 +0200 Subject: fix(desktop): start the mail Accounts singleton at shell launch The singleton was referenced only inside lazy Components, so its qtmaildir.conf watcher and unread-count refresh did not start until the drawer first opened, contradicting alwaysActive and the old MailPanel, which shell.qml instantiated directly. Naming Accounts at the Module top level creates it at shell load; the page keeps its own refresh on open. --- desktop/modules/mail/MailModule.qml | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'desktop/modules/mail') diff --git a/desktop/modules/mail/MailModule.qml b/desktop/modules/mail/MailModule.qml index 99ddaff..5f501ba 100644 --- a/desktop/modules/mail/MailModule.qml +++ b/desktop/modules/mail/MailModule.qml @@ -22,6 +22,13 @@ Module { label: "Mail" alwaysActive: true + // Accounts is a singleton; nothing names it at shell start otherwise, so + // this reference instantiates it here. That is what makes alwaysActive + // true mean something: the config FileView starts and the unread count is + // fetched while the drawer is closed, as the old MailPanel did, rather + // than first when the drawer opens. + Component.onCompleted: Accounts.refresh() + tileContent: Component { MailTile {} } page: Component { -- cgit v1.2.3