diff options
author | sb <sb@openoffice.org> | 2010-09-10 13:10:07 +0200 |
---|---|---|
committer | sb <sb@openoffice.org> | 2010-09-10 13:10:07 +0200 |
commit | 04c708938a8232437119c13cabb6f7a65dcc19e0 (patch) | |
tree | af0a7a55c773e5bfa110a3c17eb6ec7cb4d6ccef /extensions/source/ole | |
parent | faea3cb5a9d96bfc897606130cfcb93e61db54bb (diff) |
sb129: #i113189# change UNO components to use passive registration
Diffstat (limited to 'extensions/source/ole')
-rw-r--r-- | extensions/source/ole/makefile.mk | 7 | ||||
-rw-r--r-- | extensions/source/ole/oleautobridge.component | 46 | ||||
-rw-r--r-- | extensions/source/ole/oleautobridge.uno.dxp | 1 | ||||
-rw-r--r-- | extensions/source/ole/servreg.cxx | 41 |
4 files changed, 53 insertions, 42 deletions
diff --git a/extensions/source/ole/makefile.mk b/extensions/source/ole/makefile.mk index ad4ecee72..806cd027e 100644 --- a/extensions/source/ole/makefile.mk +++ b/extensions/source/ole/makefile.mk @@ -129,3 +129,10 @@ DEF2EXPORTFILE=$(TARGET).dxp .INCLUDE : target.mk +ALLTAR : $(MISC)/oleautobridge.component + +$(MISC)/oleautobridge.component .ERRREMOVE : \ + $(SOLARENV)/bin/createcomponent.xslt oleautobridge.component + $(XSLTPROC) --nonet --stringparam uri \ + '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ + $(SOLARENV)/bin/createcomponent.xslt oleautobridge.component diff --git a/extensions/source/ole/oleautobridge.component b/extensions/source/ole/oleautobridge.component new file mode 100644 index 000000000..6f5309e42 --- /dev/null +++ b/extensions/source/ole/oleautobridge.component @@ -0,0 +1,46 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--********************************************************************** +* +* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +* +* Copyright 2000, 2010 Oracle and/or its affiliates. +* +* OpenOffice.org - a multi-platform office productivity suite +* +* This file is part of OpenOffice.org. +* +* OpenOffice.org is free software: you can redistribute it and/or modify +* it under the terms of the GNU Lesser General Public License version 3 +* only, as published by the Free Software Foundation. +* +* OpenOffice.org is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Lesser General Public License version 3 for more details +* (a copy is included in the LICENSE file that accompanied this code). +* +* You should have received a copy of the GNU Lesser General Public License +* version 3 along with OpenOffice.org. If not, see +* <http://www.openoffice.org/license.html> +* for a copy of the LGPLv3 License. +* +**********************************************************************--> + +<component loader="com.sun.star.loader.SharedLibrary" + xmlns="http://openoffice.org/2010/uno-components"> + <implementation name="com.sun.star.comp.ole.OleClient"> + <service name="com.sun.star.bridge.OleObjectFactory"/> + <service name="com.sun.star.bridge.oleautomation.Factory"/> + </implementation> + <implementation name="com.sun.star.comp.ole.OleConverter2"> + <service name="com.sun.star.bridge.OleBridgeSupplier2"/> + <service name="com.sun.star.bridge.oleautomation.BridgeSupplier"/> + </implementation> + <implementation name="com.sun.star.comp.ole.OleConverterVar1"> + <service name="com.sun.star.bridge.OleBridgeSupplierVar1"/> + </implementation> + <implementation name="com.sun.star.comp.ole.OleServer"> + <service name="com.sun.star.bridge.OleApplicationRegistration"/> + <service name="com.sun.star.bridge.oleautomation.ApplicationRegistration"/> + </implementation> +</component> diff --git a/extensions/source/ole/oleautobridge.uno.dxp b/extensions/source/ole/oleautobridge.uno.dxp index e7947188a..1f26fd019 100644 --- a/extensions/source/ole/oleautobridge.uno.dxp +++ b/extensions/source/ole/oleautobridge.uno.dxp @@ -1,4 +1,3 @@ -component_writeInfo @100 component_getFactory @101 component_getImplementationEnvironment @102 component_canUnload @103 diff --git a/extensions/source/ole/servreg.cxx b/extensions/source/ole/servreg.cxx index a0bd98e33..f43b4f6bf 100644 --- a/extensions/source/ole/servreg.cxx +++ b/extensions/source/ole/servreg.cxx @@ -119,47 +119,6 @@ extern "C" void * SAL_CALL component_getFactory( } -extern "C" sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, void * pRegistryKey ) -{ - if (pRegistryKey) - { - try - { - //deprecated - Reference<XRegistryKey> xNewKey = - reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleConverter2/UNO/SERVICES")); - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleBridgeSupplier2")); - - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.BridgeSupplier")); - - //deprecated - xNewKey = - reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleConverterVar1/UNO/SERVICES")); - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleBridgeSupplierVar1")); - - //deprecated - xNewKey = - reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleClient/UNO/SERVICES")); - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleObjectFactory")); - - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.Factory")); - //deprecated - xNewKey = - reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleServer/UNO/SERVICES")); - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleApplicationRegistration")); - - xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.ApplicationRegistration")); - - return sal_True; - } - catch (InvalidRegistryException &) - { - OSL_ENSURE( sal_False, "### InvalidRegistryException!" ); - } - } - return sal_False; -} - extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ ) { |