зеркало из https://github.com/mozilla/pjs.git
IDLify this interface - had to change char* to const char*
This commit is contained in:
Родитель
807582fa6c
Коммит
1d0dce99b6
|
@ -1,79 +0,0 @@
|
|||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
*
|
||||
* The contents of this file are subject to the Netscape Public License
|
||||
* Version 1.0 (the "NPL"); you may not use this file except in
|
||||
* compliance with the NPL. You may obtain a copy of the NPL at
|
||||
* http://www.mozilla.org/NPL/
|
||||
*
|
||||
* Software distributed under the NPL is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
|
||||
* for the specific language governing rights and limitations under the
|
||||
* NPL.
|
||||
*
|
||||
* The Initial Developer of this code under the NPL is Netscape
|
||||
* Communications Corporation. Portions created by Netscape are
|
||||
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
|
||||
* Reserved.
|
||||
*/
|
||||
|
||||
#ifndef nsIMsgMailSession_h___
|
||||
#define nsIMsgMailSession_h___
|
||||
|
||||
#include "nsISupports.h"
|
||||
|
||||
/* D5124440-D59E-11d2-806A-006008128C4E */
|
||||
|
||||
#define NS_IMSGMAILSESSION_IID \
|
||||
{ 0xd5124440, 0xd59e, 0x11d2, \
|
||||
{ 0x80, 0x6a, 0x0, 0x60, 0x8, 0x12, 0x8c, 0x4e } }
|
||||
|
||||
/* D5124441-D59E-11d2-806A-006008128C4E */
|
||||
#define NS_MSGMAILSESSION_CID \
|
||||
{ 0xd5124441, 0xd59e, 0x11d2, \
|
||||
{ 0x80, 0x6a, 0x0, 0x60, 0x8, 0x12, 0x8c, 0x4e } }
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// The mail session is a replacement for the old 4.x MSG_Master object. It contains
|
||||
// mail session generic information such as the user's current mail identity, ....
|
||||
// I'm starting this off as an empty interface and as people feel they need to
|
||||
// add more information to it, they can. I think this is a better approach than
|
||||
// trying to port over the old MSG_Master in its entirety as that had a lot of
|
||||
// cruft in it....
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "nsIMsgIdentity.h"
|
||||
#include "nsIMsgIncomingServer.h"
|
||||
#include "nsIMsgAccountManager.h"
|
||||
#include "nsIFolder.h"
|
||||
#include "nsIFolderListener.h"
|
||||
|
||||
class nsIMsgMailSession : public nsISupports
|
||||
{
|
||||
public:
|
||||
static const nsIID& GetIID() { static nsIID iid = NS_IMSGMAILSESSION_IID; return iid; }
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// The user's current identity is used to abstract out information such as the
|
||||
// user name, pwd, mail server to use, etc....
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
NS_IMETHOD GetCurrentIdentity(nsIMsgIdentity ** aIdentity) = 0;
|
||||
NS_IMETHOD GetCurrentServer(nsIMsgIncomingServer* *aServer) = 0;
|
||||
NS_IMETHOD GetAccountManager(nsIMsgAccountManager* *aAccountManager) = 0;
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// Some objects want to get folder notifications from every folder. Instead of forcing them
|
||||
// to register with every folder, this is a central place where they can register and get all
|
||||
// notifications.
|
||||
//////////////////////////////////////////////////////////////////////////////////////
|
||||
NS_IMETHOD AddFolderListener(nsIFolderListener *listener) = 0;
|
||||
NS_IMETHOD RemoveFolderListener(nsIFolderListener *listener) = 0;
|
||||
NS_IMETHOD NotifyFolderItemPropertyChanged(nsISupports *item, char *property, char* oldValue, char* newValue) = 0;
|
||||
NS_IMETHOD NotifyFolderItemPropertyFlagChanged(nsISupports *item, char *property, PRUint32 oldValue,
|
||||
PRUint32 newValue) = 0;
|
||||
NS_IMETHOD NotifyFolderItemAdded(nsIFolder *folder, nsISupports *item)= 0;
|
||||
NS_IMETHOD NotifyFolderItemDeleted(nsIFolder *folder, nsISupports *item)= 0;
|
||||
|
||||
};
|
||||
|
||||
#endif /* nsIMsgMailSession_h___ */
|
|
@ -0,0 +1,57 @@
|
|||
/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
*
|
||||
* The contents of this file are subject to the Netscape Public License
|
||||
* Version 1.0 (the "NPL"); you may not use this file except in
|
||||
* compliance with the NPL. You may obtain a copy of the NPL at
|
||||
* http://www.mozilla.org/NPL/
|
||||
*
|
||||
* Software distributed under the NPL is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
|
||||
* for the specific language governing rights and limitations under the
|
||||
* NPL.
|
||||
*
|
||||
* The Initial Developer of this code under the NPL is Netscape
|
||||
* Communications Corporation. Portions created by Netscape are
|
||||
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
|
||||
* Reserved.
|
||||
*/
|
||||
|
||||
#include "nsISupports.idl"
|
||||
|
||||
/*
|
||||
* The mail session is a replacement for the old 4.x MSG_Master object. It
|
||||
* contains mail session generic information such as the account manager, etc
|
||||
* I'm starting this off as an empty interface and as people feel they need to
|
||||
* add more information to it, they can. I think this is a better approach
|
||||
* than trying to port over the old MSG_Master in its entirety as that had a
|
||||
* lot of cruft in it....
|
||||
*/
|
||||
|
||||
#include "nsISupports.idl"
|
||||
#include "nsIMsgIdentity.idl"
|
||||
#include "nsIMsgIncomingServer.idl"
|
||||
#include "nsIMsgAccountManager.idl"
|
||||
#include "nsIFolderListener.idl"
|
||||
|
||||
[scriptable, uuid(D5124440-D59E-11d2-806A-006008128C4E)]
|
||||
interface nsIMsgMailSession : nsISupports {
|
||||
|
||||
readonly attribute nsIMsgIdentity currentIdentity;
|
||||
readonly attribute nsIMsgIncomingServer currentServer;
|
||||
readonly attribute nsIMsgAccountManager accountManager;
|
||||
|
||||
void AddFolderListener(in nsIFolderListener listener);
|
||||
void RemoveFolderListener(in nsIFolderListener listener);
|
||||
void NotifyFolderItemPropertyChanged(in nsISupports item,
|
||||
in string property,
|
||||
in string oldValue,
|
||||
in string newValue);
|
||||
void NotifyFolderItemPropertyFlagChanged(in nsISupports item,
|
||||
in string property,
|
||||
in unsigned long oldValue,
|
||||
in unsigned long newValue);
|
||||
|
||||
void NotifyFolderItemAdded(in nsIFolder folder, in nsISupports item);
|
||||
void NotifyFolderItemDeleted(in nsIFolder folder, in nsISupports item);
|
||||
};
|
||||
|
|
@ -120,7 +120,11 @@ NS_IMETHODIMP nsMsgMailSession::RemoveFolderListener(nsIFolderListener * listene
|
|||
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsMsgMailSession::NotifyFolderItemPropertyChanged(nsISupports *item, char *property, char* oldValue, char* newValue)
|
||||
NS_IMETHODIMP
|
||||
nsMsgMailSession::NotifyFolderItemPropertyChanged(nsISupports *item,
|
||||
const char *property,
|
||||
const char* oldValue,
|
||||
const char* newValue)
|
||||
{
|
||||
PRInt32 i;
|
||||
for(i = 0; i < mListeners->Count(); i++)
|
||||
|
@ -134,8 +138,11 @@ NS_IMETHODIMP nsMsgMailSession::NotifyFolderItemPropertyChanged(nsISupports *ite
|
|||
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsMsgMailSession::NotifyFolderItemPropertyFlagChanged(nsISupports *item, char *property,
|
||||
PRUint32 oldValue, PRUint32 newValue)
|
||||
NS_IMETHODIMP
|
||||
nsMsgMailSession::NotifyFolderItemPropertyFlagChanged(nsISupports *item,
|
||||
const char *property,
|
||||
PRUint32 oldValue,
|
||||
PRUint32 newValue)
|
||||
{
|
||||
PRInt32 i;
|
||||
for(i = 0; i < mListeners->Count(); i++)
|
||||
|
|
|
@ -48,8 +48,8 @@ public:
|
|||
|
||||
NS_IMETHOD AddFolderListener(nsIFolderListener *listener);
|
||||
NS_IMETHOD RemoveFolderListener(nsIFolderListener *listener);
|
||||
NS_IMETHOD NotifyFolderItemPropertyChanged(nsISupports *item, char *property, char* oldValue, char* newValue);
|
||||
NS_IMETHOD NotifyFolderItemPropertyFlagChanged(nsISupports *item, char *property, PRUint32 oldValue,
|
||||
NS_IMETHOD NotifyFolderItemPropertyChanged(nsISupports *item, const char *property, const char* oldValue, const char* newValue);
|
||||
NS_IMETHOD NotifyFolderItemPropertyFlagChanged(nsISupports *item, const char *property, PRUint32 oldValue,
|
||||
PRUint32 newValue);
|
||||
NS_IMETHOD NotifyFolderItemAdded(nsIFolder *folder, nsISupports *item);
|
||||
NS_IMETHOD NotifyFolderItemDeleted(nsIFolder *folder, nsISupports *item);
|
||||
|
|
Загрузка…
Ссылка в новой задаче