Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes | Protected Attributes | Events
nsMsgMailSession Class Reference

#include <nsMsgMailSession.h>

Inheritance diagram for nsMsgMailSession:
Inheritance graph
[legend]
Collaboration diagram for nsMsgMailSession:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 nsMsgMailSession ()
virtual ~nsMsgMailSession ()
NS_DECL_ISUPPORTS
NS_DECL_NSIMSGMAILSESSION
NS_DECL_NSIFOLDERLISTENER
nsresult 
Init ()
nsresult GetSelectedLocaleDataDir (nsIFile *defaultsDir)
void Shutdown ()
void AddFolderListener (in nsIFolderListener listener, in folderListenerNotifyFlagValue notifyFlags)
void RemoveFolderListener (in nsIFolderListener listener)
void AddMsgWindow (in nsIMsgWindow msgWindow)
void RemoveMsgWindow (in nsIMsgWindow msgWindow)
boolean IsFolderOpenInWindow (in nsIMsgFolder folder)
string ConvertMsgURIToMsgURL (in string aURI, in nsIMsgWindow aMsgWindow)
nsIFile getDataFilesDir (in string dirName)
void OnItemAdded (in nsIRDFResource parentItem, in nsISupports item)
void OnItemRemoved (in nsIRDFResource parentItem, in nsISupports item)
void OnItemPropertyChanged (in nsIRDFResource item, in nsIAtom property, in string oldValue, in string newValue)
void OnItemIntPropertyChanged (in nsIRDFResource item, in nsIAtom property, in long oldValue, in long newValue)
void OnItemBoolPropertyChanged (in nsIRDFResource item, in nsIAtom property, in boolean oldValue, in boolean newValue)
void OnItemUnicharPropertyChanged (in nsIRDFResource item, in nsIAtom property, in wstring oldValue, in wstring newValue)
void OnItemPropertyFlagChanged (in nsIMsgDBHdr item, in nsIAtom property, in unsigned long oldFlag, in unsigned long newFlag)
void OnItemEvent (in nsIMsgFolder item, in nsIAtom event)

Public Attributes

readonly attribute nsIMsgWindow topmostMsgWindow
readonly attribute nsISupportsArray msgWindowsArray
const folderListenerNotifyFlagValue added = 0x1
const folderListenerNotifyFlagValue removed = 0x2
const folderListenerNotifyFlagValue propertyChanged = 0x4
const folderListenerNotifyFlagValue intPropertyChanged = 0x8
const folderListenerNotifyFlagValue boolPropertyChanged = 0x10
const folderListenerNotifyFlagValue unicharPropertyChanged = 0x20
const folderListenerNotifyFlagValue propertyFlagChanged = 0x40

Protected Attributes

nsCOMArray< nsIFolderListenermListeners
nsUInt32Array mListenerNotifyFlags
nsCOMPtr< nsISupportsArraymWindows
nsCOMPtr< nsIMsgWindowm_temporaryMsgWindow
nsCOMPtr< nsISupports > m_desktopSearchService

Events

const
folderListenerNotifyFlagValue=0 
x80
const folderListenerNotifyFlagValue all = 0xFFFFFFFF

Detailed Description

Definition at line 57 of file nsMsgMailSession.h.


Constructor & Destructor Documentation

Definition at line 68 of file nsMsgMailSession.cpp.

{
}

Definition at line 73 of file nsMsgMailSession.cpp.

{
  Shutdown();
}

Here is the call graph for this function:


Member Function Documentation

string nsIMsgMailSession::ConvertMsgURIToMsgURL ( in string  aURI,
in nsIMsgWindow  aMsgWindow 
) [inherited]

Definition at line 403 of file nsMsgMailSession.cpp.

{                                                                               
  NS_ENSURE_ARG_POINTER(defaultsDir);                                     

  nsresult rv;                                                                
  PRBool baseDirExists = PR_FALSE;                                            
  rv = defaultsDir->Exists(&baseDirExists);                               
  NS_ENSURE_SUCCESS(rv,rv);                                                   

  if (baseDirExists) {                                                        
    nsCOMPtr<nsIXULChromeRegistry> packageRegistry =
      do_GetService("@mozilla.org/chrome/chrome-registry;1", &rv);
    if (NS_SUCCEEDED(rv)) {                                                 
      nsCAutoString localeName;                                           
      rv = packageRegistry->GetSelectedLocale(NS_LITERAL_CSTRING("global-region"), localeName);

      if (NS_SUCCEEDED(rv) && !localeName.IsEmpty()) {
        PRBool localeDirExists = PR_FALSE;                              
        nsCOMPtr<nsIFile> localeDataDir;                                
        
        rv = defaultsDir->Clone(getter_AddRefs(localeDataDir));     
        NS_ENSURE_SUCCESS(rv,rv);                                       

        rv = localeDataDir->AppendNative(localeName);
        NS_ENSURE_SUCCESS(rv,rv);                                       

        rv = localeDataDir->Exists(&localeDirExists);                   
        NS_ENSURE_SUCCESS(rv,rv);                                       

        if (localeDirExists) {                                          
          // use locale provider instead                              
          rv = defaultsDir->AppendNative(localeName);
          NS_ENSURE_SUCCESS(rv,rv);                                   
        }                                                               
      }                                                                   
    }                                                                       
  }                                                                           
  return NS_OK;                                                               
} 

Here is the call graph for this function:

Definition at line 78 of file nsMsgMailSession.cpp.

{
  m_desktopSearchService = do_GetService("@mozilla.org/desktop-search-integration;1");
  return NS_NewISupportsArray(getter_AddRefs(mWindows));
}

Here is the call graph for this function:

void nsIFolderListener::OnItemAdded ( in nsIRDFResource  parentItem,
in nsISupports  item 
) [inherited]

Here is the caller graph for this function:

void nsIFolderListener::OnItemBoolPropertyChanged ( in nsIRDFResource  item,
in nsIAtom  property,
in boolean  oldValue,
in boolean  newValue 
) [inherited]

Here is the caller graph for this function:

void nsIFolderListener::OnItemEvent ( in nsIMsgFolder  item,
in nsIAtom  event 
) [inherited]

Here is the caller graph for this function:

void nsIFolderListener::OnItemIntPropertyChanged ( in nsIRDFResource  item,
in nsIAtom  property,
in long  oldValue,
in long  newValue 
) [inherited]

Here is the caller graph for this function:

void nsIFolderListener::OnItemPropertyChanged ( in nsIRDFResource  item,
in nsIAtom  property,
in string  oldValue,
in string  newValue 
) [inherited]
void nsIFolderListener::OnItemPropertyFlagChanged ( in nsIMsgDBHdr  item,
in nsIAtom  property,
in unsigned long  oldFlag,
in unsigned long  newFlag 
) [inherited]

Here is the caller graph for this function:

void nsIFolderListener::OnItemRemoved ( in nsIRDFResource  parentItem,
in nsISupports  item 
) [inherited]
void nsIFolderListener::OnItemUnicharPropertyChanged ( in nsIRDFResource  item,
in nsIAtom  property,
in wstring  oldValue,
in wstring  newValue 
) [inherited]

Here is the caller graph for this function:


Member Data Documentation

Definition at line 49 of file nsIFolderListener.idl.

Definition at line 69 of file nsIFolderListener.idl.

Definition at line 63 of file nsIFolderListener.idl.

Definition at line 78 of file nsMsgMailSession.h.

Definition at line 77 of file nsMsgMailSession.h.

nsUInt32Array nsMsgMailSession::mListenerNotifyFlags [protected]

Definition at line 73 of file nsMsgMailSession.h.

Definition at line 72 of file nsMsgMailSession.h.

Definition at line 67 of file nsIMsgMailSession.idl.

Definition at line 75 of file nsMsgMailSession.h.

Definition at line 57 of file nsIFolderListener.idl.

Definition at line 81 of file nsIFolderListener.idl.

Definition at line 53 of file nsIFolderListener.idl.

Definition at line 64 of file nsIMsgMailSession.idl.

Definition at line 75 of file nsIFolderListener.idl.


Event Documentation

Definition at line 90 of file nsIFolderListener.idl.

Definition at line 87 of file nsIFolderListener.idl.


The documentation for this class was generated from the following files: