From a3c8a0ed0c5c6be1cb5c940750222f6381608bd7 Mon Sep 17 00:00:00 2001 From: sb Date: Fri, 10 Sep 2010 13:10:07 +0200 Subject: sb129: #i113189# change UNO components to use passive registration --- sot/prj/d.lst | 1 + sot/source/unoolestorage/register.cxx | 28 ---------------------------- sot/util/makefile.mk | 8 ++++++++ sot/util/sot.component | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 43 insertions(+), 28 deletions(-) create mode 100644 sot/util/sot.component (limited to 'sot') diff --git a/sot/prj/d.lst b/sot/prj/d.lst index 528b6863ef3c..10bed8c9fe5e 100644 --- a/sot/prj/d.lst +++ b/sot/prj/d.lst @@ -25,3 +25,4 @@ mkdir: %_DEST%\inc%_EXT%\sot ..\%__SRC%\bin\sot?????.dll %_DEST%\bin%_EXT%\sot?????.dll ..\%__SRC%\bin\sot?????.sym %_DEST%\bin%_EXT%\sot?????.sym ..\%__SRC%\misc\sot?????.map %_DEST%\bin%_EXT%\sot?????.map +..\%__SRC%\misc\sot.component %_DEST%\xml%_EXT%\sot.component diff --git a/sot/source/unoolestorage/register.cxx b/sot/source/unoolestorage/register.cxx index 00326333546d..083a4d585ca1 100644 --- a/sot/source/unoolestorage/register.cxx +++ b/sot/source/unoolestorage/register.cxx @@ -69,33 +69,5 @@ SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( const sal_Char * pImp return pRet; } -SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, void * pRegistryKey ) -{ - if (pRegistryKey) - { - try - { - uno::Reference< registry::XRegistryKey > xKey( reinterpret_cast< registry::XRegistryKey* >( pRegistryKey ) ); - - uno::Reference< registry::XRegistryKey > xNewKey; - - xNewKey = xKey->createKey( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") ) + - OLESimpleStorage::impl_staticGetImplementationName() + - ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES") ) ); - - const uno::Sequence< ::rtl::OUString > &rServices = OLESimpleStorage::impl_staticGetSupportedServiceNames(); - for( sal_Int32 ind = 0; ind < rServices.getLength(); ind++ ) - xNewKey->createKey( rServices.getConstArray()[ind] ); - - return sal_True; - } - catch (registry::InvalidRegistryException &) - { - OSL_ENSURE( sal_False, "### InvalidRegistryException!" ); - } - } - return sal_False; -} - } // extern "C" diff --git a/sot/util/makefile.mk b/sot/util/makefile.mk index 60b34c356217..72d17db189be 100644 --- a/sot/util/makefile.mk +++ b/sot/util/makefile.mk @@ -79,3 +79,11 @@ $(MISC)$/$(SHL1TARGET).flt: makefile.mk @echo Making: $@ $(TYPE) sot.flt > $@ + +ALLTAR : $(MISC)/sot.component + +$(MISC)/sot.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ + sot.component + $(XSLTPROC) --nonet --stringparam uri \ + '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ + $(SOLARENV)/bin/createcomponent.xslt sot.component diff --git a/sot/util/sot.component b/sot/util/sot.component new file mode 100644 index 000000000000..7d17c7d54475 --- /dev/null +++ b/sot/util/sot.component @@ -0,0 +1,34 @@ + + + + + + + + -- cgit