fix for #119404 (mail folders come up empty the first time that you open them).

fix by bienvenu.  r=naving,blizzard, sr=sspitzer, a=blizzard
This commit is contained in:
sspitzer%netscape.com 2002-01-18 22:48:24 +00:00
Родитель 58c8d86d22
Коммит cf74ccbb3a
3 изменённых файлов: 14 добавлений и 0 удалений

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

@ -43,6 +43,7 @@ interface nsIMsgWindow;
interface nsIMessenger;
interface nsIMsgDBHdr;
interface nsIMsgDBViewCommandUpdater;
interface nsIMsgDatabase;
typedef long nsMsgViewNotificationCodeValue;
typedef long nsMsgViewCommandCheckStateValue;
@ -296,6 +297,8 @@ interface nsIMsgDBView : nsISupports
//to notify outliner that rows are going away
void onDeleteCompleted(in boolean succeeded);
readonly attribute nsIMsgDatabase db;
};
/* this interface is rapidly morphing from a command updater interface into a more generic

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

@ -108,6 +108,10 @@ var folderListener = {
// which will cause us to update commands.
if (gDBView) {
gDBView.suppressCommandUpdating = true;
// if the db's view isn't set, something went wrong and we should reroot
// the folder, which will re-open the view.
if (!gDBView.db)
gRerootOnFolderLoad = true;
}
if (gRerootOnFolderLoad)
RerootFolder(uri, msgFolder, gCurrentLoadingFolderViewType, gCurrentLoadingFolderViewFlags, gCurrentLoadingFolderSortType, gCurrentLoadingFolderSortOrder);

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

@ -4908,6 +4908,13 @@ nsMsgDBView::OnDeleteCompleted(PRBool aSucceeded)
}
NS_IMETHODIMP nsMsgDBView::GetDb(nsIMsgDatabase **aDB)
{
NS_ENSURE_ARG_POINTER(aDB);
NS_IF_ADDREF(*aDB = m_db);
return NS_OK;
}
PRBool nsMsgDBView::OfflineMsgSelected(nsMsgViewIndex * indices, PRInt32 numIndices)
{
nsCOMPtr <nsIMsgLocalMailFolder> localFolder = do_QueryInterface(m_folder);