diff options
author | Michael Meeks <michael.meeks@novell.com> | 2011-04-01 22:31:53 +0100 |
---|---|---|
committer | Michael Meeks <michael.meeks@novell.com> | 2011-04-01 22:31:53 +0100 |
commit | c1e39ca4de615b4ef4152748d1c90a45eeb2cc92 (patch) | |
tree | 3aa9463075a129bffaf3c3557bdfb4070c96169e | |
parent | 87b2413a0a62abc94bf023089273c5c21d009ead (diff) |
register lotuswordpro filter component
-rw-r--r-- | lotuswordpro/prj/d.lst | 1 | ||||
-rw-r--r-- | lotuswordpro/source/filter/genericfilter.cxx | 29 | ||||
-rw-r--r-- | lotuswordpro/util/lwpfilter.component | 8 | ||||
-rw-r--r-- | lotuswordpro/util/makefile.mk | 8 |
4 files changed, 17 insertions, 29 deletions
diff --git a/lotuswordpro/prj/d.lst b/lotuswordpro/prj/d.lst index 48efbc1cd..134657566 100644 --- a/lotuswordpro/prj/d.lst +++ b/lotuswordpro/prj/d.lst @@ -1,3 +1,4 @@ ..\%__SRC%\lib\*.so %_DEST%\lib%_EXT%\*.so ..\%__SRC%\bin\*.dll %_DEST%\lib%_EXT%\*.dll ..\%__SRC%\lib\*.dylib %_DEST%\lib%_EXT%\*.dylib +..\%__SRC%\misc\*.component %_DEST%\xml%_EXT%\*.component diff --git a/lotuswordpro/source/filter/genericfilter.cxx b/lotuswordpro/source/filter/genericfilter.cxx index 7bec7a650..059450077 100644 --- a/lotuswordpro/source/filter/genericfilter.cxx +++ b/lotuswordpro/source/filter/genericfilter.cxx @@ -19,40 +19,11 @@ using namespace ::com::sun::star::registry; extern "C" { -//================================================================================================== void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ ) { *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; } -//================================================================================================== -sal_Bool SAL_CALL component_writeInfo( - void * /*pServiceManager*/, void * pRegistryKey ) -{ - if (pRegistryKey) - { - try - { - sal_Int32 nPos = 0; - Reference< XRegistryKey > xNewKey( - reinterpret_cast< XRegistryKey * >( pRegistryKey )->createKey( LotusWordProImportFilter_getImplementationName() ) ); - xNewKey = xNewKey->createKey( OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/SERVICES")) ); - - const Sequence< OUString > & rSNL = LotusWordProImportFilter_getSupportedServiceNames(); - const OUString * pArray = rSNL.getConstArray(); - for ( nPos = rSNL.getLength(); nPos--; ) - xNewKey->createKey( pArray[nPos] ); - - return sal_True; - } - catch (InvalidRegistryException &) - { - OSL_FAIL( "### InvalidRegistryException!" ); - } - } - return sal_False; -} -//================================================================================================== void * SAL_CALL component_getFactory( const sal_Char * pImplName, void * pServiceManager, void * /*pRegistryKey*/ ) { diff --git a/lotuswordpro/util/lwpfilter.component b/lotuswordpro/util/lwpfilter.component new file mode 100644 index 000000000..030c75992 --- /dev/null +++ b/lotuswordpro/util/lwpfilter.component @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<component loader="com.sun.star.loader.SharedLibrary" + xmlns="http://openoffice.org/2010/uno-components"> + <implementation name="com.sun.star.comp.Writer.LotusWordProImportFilter"> + <service name="com.sun.star.document.ImportFilter"/> + <service name="com.sun.star.document.ExtendedTypeDetection"/> + </implementation> +</component> diff --git a/lotuswordpro/util/makefile.mk b/lotuswordpro/util/makefile.mk index 7b34a03fa..640ba297a 100644 --- a/lotuswordpro/util/makefile.mk +++ b/lotuswordpro/util/makefile.mk @@ -35,3 +35,11 @@ SHL1VERSIONMAP=$(TARGET).map DEF1NAME=$(SHL1TARGET) .INCLUDE : target.mk + +ALLTAR : $(MISC)/lwpfilter.component + +$(MISC)/lwpfilter.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \ + lwpfilter.component + $(XSLTPROC) --nonet --stringparam uri \ + '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ + $(SOLARENV)/bin/createcomponent.xslt lwpfilter.component |