Adding nsXULKeyListener again...

This commit is contained in:
saari%netscape.com 1999-06-14 22:06:24 +00:00
Родитель 711694acda
Коммит f38a079904
2 изменённых файлов: 18 добавлений и 5 удалений

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

@ -130,12 +130,13 @@
#define NS_XULPOPUPLISTENER_CID \
{ 0x3986b301, 0x97c, 0x11d3, { 0xbf, 0x87, 0x0, 0x10, 0x5a, 0x1b, 0x6, 0x27 } }
// {3986B301-097C-11d3-BF87-00105A1B0627}
// Generate this!
#define NS_XULKEYLISTENER_CID \
{ 0x3986b301, 0x97c, 0x11d3, { 0xbf, 0x87, 0x0, 0x11, 0x5a, 0x1b, 0x6, 0x27 } }
// {FE71D561-1501-11d3-BF87-00105A1B0627}
#define NS_XULFOCUSTRACKER_CID \
{ 0xfe71d561, 0x1501, 0x11d3, { 0xbf, 0x87, 0x0, 0x10, 0x5a, 0x1b, 0x6, 0x27 } }
// {9e246e80-2064-11d3-973e-00805f916fd3}
#define NS_XULKEYLISTENER_CID \
{ 0x9e246e80, 0x2064, 0x11d3, {0x97, 0x3e, 0x00, 0x80, 0x5f, 0x91, 0x6f, 0xd3} }
#endif // nsRDFCID_h__

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

@ -46,6 +46,7 @@
#include "nsIXULSortService.h"
#include "nsIXULDocumentInfo.h"
#include "nsIXULPopupListener.h"
#include "nsIXULKeyListener.h"
#include "nsIXULFocusTracker.h"
#include "nsIServiceManager.h"
#include "nsCOMPtr.h"
@ -79,6 +80,7 @@ static NS_DEFINE_CID(kXULDocumentCID, NS_XULDOCUMENT_CID);
static NS_DEFINE_CID(kXULSortServiceCID, NS_XULSORTSERVICE_CID);
static NS_DEFINE_CID(kXULDocumentInfoCID, NS_XULDOCUMENTINFO_CID);
static NS_DEFINE_CID(kXULPopupListenerCID, NS_XULPOPUPLISTENER_CID);
static NS_DEFINE_CID(kXULKeyListenerCID, NS_XULKEYLISTENER_CID);
static NS_DEFINE_CID(kXULFocusTrackerCID, NS_XULFOCUSTRACKER_CID);
class RDFFactoryImpl : public nsIFactory
@ -176,6 +178,10 @@ RDFFactoryImpl::CreateInstance(nsISupports *aOuter,
if (NS_FAILED(rv = NS_NewXULPopupListener((nsIXULPopupListener**) &inst)))
return rv;
}
else if (mClassID.Equals(kXULKeyListenerCID)) {
if (NS_FAILED(rv = NS_NewXULKeyListener((nsIXULKeyListener**) &inst)))
return rv;
}
else if (mClassID.Equals(kXULFocusTrackerCID)) {
if (NS_FAILED(rv = NS_NewXULFocusTracker((nsIXULFocusTracker**) &inst)))
return rv;
@ -478,7 +484,13 @@ NSRegisterSelf(nsISupports* aServMgr , const char* aPath)
"XUL PopupListener",
NS_RDF_PROGID "/xul-popup-listener",
aPath, PR_TRUE, PR_TRUE);
if (NS_FAILED(rv)) goto done;
rv = compMgr->RegisterComponent(kXULKeyListenerCID,
"XUL KeyListener",
NS_RDF_PROGID "/xul-key-listener",
aPath, PR_TRUE, PR_TRUE);
if (NS_FAILED(rv)) goto done;
rv = compMgr->RegisterComponent(kXULFocusTrackerCID,
"XUL FocusTracker",