summaryrefslogtreecommitdiff
path: root/codemaker
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2004-03-30 15:52:33 +0000
committerRüdiger Timm <rt@openoffice.org>2004-03-30 15:52:33 +0000
commit83d6cb0b76bcc0a29af5f8a28d8232c4b569087b (patch)
treec381ea79f773667460d95d2bddcc1230c6d5a64f /codemaker
parent97d36b3ffefc89fc75c32d8e75531235cac346c8 (diff)
INTEGRATION: CWS sb14 (1.5.70); FILE MERGED
2004/03/12 14:17:16 sb 1.5.70.1: #i21150# Adapted to modified registry type reader.
Diffstat (limited to 'codemaker')
-rw-r--r--codemaker/source/codemaker/typemanager.cxx27
1 files changed, 11 insertions, 16 deletions
diff --git a/codemaker/source/codemaker/typemanager.cxx b/codemaker/source/codemaker/typemanager.cxx
index b3bbb70174d6..a2ebdd4091a8 100644
--- a/codemaker/source/codemaker/typemanager.cxx
+++ b/codemaker/source/codemaker/typemanager.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: typemanager.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: dbo $ $Date: 2002-07-31 12:46:35 $
+ * last change: $Author: rt $ $Date: 2004-03-30 16:52:33 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -67,13 +67,10 @@
#include <codemaker/typemanager.hxx>
#endif
-using namespace rtl;
+#include "registry/reader.hxx"
+#include "registry/version.h"
-RegistryTypeReaderLoader & getRegistryTypeReaderLoader()
-{
- static RegistryTypeReaderLoader aLoader;
- return aLoader;
-}
+using namespace rtl;
TypeManager::TypeManager()
{
@@ -201,10 +198,10 @@ sal_Bool RegistryTypeManager::init(
return sal_True;
}
-TypeReader RegistryTypeManager::getTypeReader(
+typereg::Reader RegistryTypeManager::getTypeReader(
const OString& name, sal_Bool * pIsExtraType )
{
- TypeReader reader;
+ typereg::Reader reader;
RegistryKey key(searchTypeKey(name, pIsExtraType));
if (key.isValid())
@@ -217,9 +214,8 @@ TypeReader RegistryTypeManager::getTypeReader(
sal_uInt8* pBuffer = (sal_uInt8*)rtl_allocateMemory(valueSize);
if (!key.getValue(OUString(), pBuffer))
{
- RegistryTypeReaderLoader & rReaderLoader = getRegistryTypeReaderLoader();
-
- reader = TypeReader(rReaderLoader, pBuffer, valueSize, sal_True);
+ reader = typereg::Reader(
+ pBuffer, valueSize, true, TYPEREG_VERSION_1);
}
rtl_freeMemory(pBuffer);
}
@@ -246,9 +242,8 @@ RTTypeClass RegistryTypeManager::getTypeClass(const OString& name)
sal_uInt8* pBuffer = (sal_uInt8*)rtl_allocateMemory(valueSize);
if (!key.getValue(OUString(), pBuffer))
{
- RegistryTypeReaderLoader & rReaderLoader = getRegistryTypeReaderLoader();
-
- TypeReader reader(rReaderLoader, pBuffer, valueSize, sal_False);
+ typereg::Reader reader(
+ pBuffer, valueSize, false, TYPEREG_VERSION_1);
RTTypeClass ret = reader.getTypeClass();