remove the useless MigratePrefs method. change upgradePrefs() into UpgradePrefs() and make it part of the nsIMsgAccountManager interface, so alecf can call it from js.

This commit is contained in:
sspitzer%netscape.com 1999-09-03 08:06:13 +00:00
Родитель 963ee4f0de
Коммит 3f30819ff0
2 изменённых файлов: 5 добавлений и 20 удалений

Просмотреть файл

@ -112,7 +112,7 @@ interface nsIMsgAccountManager : nsISupports {
void WriteToFolderCache(in nsIMsgFolderCache folderCache);
/* search for 4.x prefs, and migrate to 5.0 prefs */
void MigratePrefs();
/* search for 4.x mailnews prefs, and migrate to 5.0 prefs */
void UpgradePrefs();
};

Просмотреть файл

@ -296,8 +296,6 @@ private:
static PRBool writeFolderCache(nsHashKey *aKey, void *aData, void *closure);
// methods for migration / upgrading
nsresult upgradePrefs();
nsresult createSpecialFile(nsFileSpec & dir, const char *specialFileName);
nsresult CopyIdentity(nsIMsgIdentity *srcIdentity, nsIMsgIdentity *destIdentity);
@ -912,7 +910,7 @@ nsMsgAccountManager::LoadAccounts()
#ifdef DEBUG_ACCOUNTMANAGER
printf("No accounts. I'll try to migrate 4.x prefs..\n");
#endif
rv = upgradePrefs();
rv = UpgradePrefs();
return rv;
}
@ -985,19 +983,6 @@ nsMsgAccountManager::WriteToFolderCache(nsIMsgFolderCache *folderCache)
return folderCache->Close();
}
nsresult
nsMsgAccountManager::MigratePrefs()
{
#ifdef DEBUG_ACCOUNTMANAGER
printf("nsMsgAccountManager::MigratePrefs()\n");
#endif
// do nothing right now.
// right now, all the migration happens when we don't find
// the mail.accountmanager.accounts pref in LoadAccounts()
return NS_OK;
}
nsresult
nsMsgAccountManager::createKeyedAccount(const char* key,
nsIMsgAccount ** aAccount)
@ -1110,8 +1095,8 @@ nsMsgAccountManager::createSpecialFile(nsFileSpec & dir, const char *specialFile
return rv;
}
nsresult
nsMsgAccountManager::upgradePrefs()
NS_IMETHODIMP
nsMsgAccountManager::UpgradePrefs()
{
nsresult rv;
PRInt32 oldMailType;