[MailNews] Allow setting "Local Folders" as always the first displayed account

This commit is contained in:
Matt A. Tobin 2020-07-27 19:18:35 -04:00 committed by Roy Tam
commit b72d30186a
2 changed files with 5 additions and 0 deletions

View file

@ -176,6 +176,10 @@ function allAccountsSorted(aExcludeIMAccounts) {
accountList = accountList.sort(compareAccounts);
}
// Set "Local Folders" as always the first displayed account
if (Services.prefs.getBoolPref("mail.accountmanager.localfolderfirst", false)) {
accountList.unshift(accountList.splice(accountList.findIndex(item => item.key === "account1"), 1)[0]);
}
return accountList;
}

View file

@ -432,6 +432,7 @@ pref("mail.default_sendlater_uri", "mailbox://nobody@Local%20Folders/Unsent%20Me
pref("mail.smtpservers", "");
pref("mail.accountmanager.accounts", "");
pref("mail.accountmanager.accounts.ordered", true);
pref("mail.accountmanager.localfolderfirst", false);
// Last used account key value
pref("mail.account.lastKey", 0);