зеркало из https://github.com/mozilla/pjs.git
add kPlatformCharsetCID
This commit is contained in:
Родитель
13f67bd41c
Коммит
61cbd28524
|
@ -20,6 +20,8 @@
|
|||
#include "nsRepository.h"
|
||||
#include "nsICharsetConverterManager.h"
|
||||
#include "nsCharsetConverterManager.h"
|
||||
#include "nsIPlatformCharset.h"
|
||||
#include "nsPlatformCharsetFactory.h"
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// Global functions and data [declaration]
|
||||
|
@ -54,6 +56,9 @@ extern "C" NS_EXPORT nsresult NSGetFactory(const nsCID &aCID, nsISupports* servi
|
|||
|
||||
return res;
|
||||
}
|
||||
if (aCID.Equals(kPlatformCharsetCID)) {
|
||||
*aFactory = NEW_PLATFORMCHARSETFACTORY();
|
||||
}
|
||||
|
||||
return NS_NOINTERFACE;
|
||||
}
|
||||
|
@ -64,6 +69,8 @@ extern "C" NS_EXPORT nsresult NSRegisterSelf(const char * path)
|
|||
|
||||
res = nsRepository::RegisterFactory(kCharsetConverterManagerCID, path,
|
||||
PR_TRUE, PR_TRUE);
|
||||
res = nsRepository::RegisterFactory(kPlatformCharsetCID, path,
|
||||
PR_TRUE, PR_TRUE);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
@ -72,5 +79,6 @@ extern "C" NS_EXPORT nsresult NSUnregisterSelf(const char * path)
|
|||
nsresult res;
|
||||
|
||||
res = nsRepository::UnregisterFactory(kCharsetConverterManagerCID, path);
|
||||
res = nsRepository::UnregisterFactory(kPlatformCharsetCID, path);
|
||||
return res;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче