[PATCH] removed newlines
Michael Koch
miko at gmx.ch
Thu Jan 20 18:06:00 PST 2011
---
.../source/xmlfilteradaptor/XmlFilterAdaptor.hxx | 60 ++-----------------
filter/source/xmlfilterdetect/fdcomp.cxx | 65 --------------------
filter/source/xmlfilterdetect/filterdetect.hxx | 56 ++---------------
3 files changed, 10 insertions(+), 171 deletions(-)
diff --git a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.hxx b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.hxx
index 45eb8a1..b84ae2e 100644
--- a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.hxx
+++ b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.hxx
@@ -52,135 +52,85 @@ enum FilterType
class XmlFilterAdaptor : public cppu::WeakImplHelper5
<
-
com::sun::star::document::XFilter,
-
com::sun::star::document::XExporter,
-
com::sun::star::document::XImporter,
-
com::sun::star::lang::XInitialization,
-
com::sun::star::lang::XServiceInfo
-
>
{
protected:
- ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMSF;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent > mxDoc;
-
- ::rtl::OUString msFilterName;
-
- ::com::sun::star::uno::Sequence< ::rtl::OUString > msUserData;
-
- ::rtl::OUString msTemplateName;
+ ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMSF;
+ ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent > mxDoc;
+ ::rtl::OUString msFilterName;
+ ::com::sun::star::uno::Sequence< ::rtl::OUString > msUserData;
+ ::rtl::OUString msTemplateName;
FilterType meType;
sal_Bool SAL_CALL exportImpl( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor )
-
throw (::com::sun::star::uno::RuntimeException);
sal_Bool SAL_CALL importImpl( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor )
-
throw (::com::sun::star::uno::RuntimeException);
-
-
public:
XmlFilterAdaptor( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > &rxMSF)
-
: mxMSF( rxMSF ) {}
virtual ~XmlFilterAdaptor() {}
-
-
// XFilter
-
virtual sal_Bool SAL_CALL filter( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor )
-
throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL cancel( )
-
throw (::com::sun::star::uno::RuntimeException);
-
-
// XExporter
-
virtual void SAL_CALL setSourceDocument( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >& xDoc )
-
throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
-
-
// XImporter
virtual void SAL_CALL setTargetDocument( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >& xDoc )
-
throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
-
-
// XInitialization
virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments )
-
throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
-
-
// XServiceInfo
virtual ::rtl::OUString SAL_CALL getImplementationName( )
-
throw (::com::sun::star::uno::RuntimeException);
virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
-
throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( )
-
throw (::com::sun::star::uno::RuntimeException);
-
};
-
-
::rtl::OUString XmlFilterAdaptor_getImplementationName()
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
sal_Bool SAL_CALL XmlFilterAdaptor_supportsService( const ::rtl::OUString& ServiceName )
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL XmlFilterAdaptor_getSupportedServiceNames( )
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
SAL_CALL XmlFilterAdaptor_createInstance( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > & rSMgr)
-
throw ( ::com::sun::star::uno::Exception );
-
-
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/filter/source/xmlfilterdetect/fdcomp.cxx b/filter/source/xmlfilterdetect/fdcomp.cxx
index 2b24406..a41303f 100644
--- a/filter/source/xmlfilterdetect/fdcomp.cxx
+++ b/filter/source/xmlfilterdetect/fdcomp.cxx
@@ -28,43 +28,23 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_filter.hxx"
-
#include <stdio.h>
-
-
-
#include <osl/mutex.hxx>
-
#include <osl/thread.h>
-
#include <cppuhelper/factory.hxx>
-
-
#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
-
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-
#endif
-
-
#include "filterdetect.hxx"
-
-
using namespace ::rtl;
-
using namespace ::cppu;
-
using namespace ::com::sun::star::uno;
-
using namespace ::com::sun::star::lang;
-
using namespace ::com::sun::star::registry;
-
-
extern "C"
{
@@ -72,109 +52,64 @@ 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
-
{
-
Reference< XRegistryKey > xNewKey(
-
reinterpret_cast< XRegistryKey * >( pRegistryKey )->createKey( FilterDetect_getImplementationName() ) );
-
xNewKey = xNewKey->createKey( OUString( RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES" )) );
-
-
const Sequence< OUString > & rSNL = FilterDetect_getSupportedServiceNames();
-
const OUString * pArray = rSNL.getConstArray();
for ( sal_Int32 nPos = rSNL.getLength(); nPos--; )
-
xNewKey->createKey( pArray[nPos] );
-
-
return sal_True;
-
}
-
catch (InvalidRegistryException &)
-
{
-
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
-
}
-
}
-
return sal_False;
-
}
//==================================================================================================
void * SAL_CALL component_getFactory(
-
const sal_Char * pImplName, void * pServiceManager, void * /* pRegistryKey */ )
-
{
-
void * pRet = 0;
-
-
OUString implName = OUString::createFromAscii( pImplName );
if ( pServiceManager && implName.equals(FilterDetect_getImplementationName()) )
-
{
-
Reference< XSingleServiceFactory > xFactory( createSingleFactory(
-
reinterpret_cast< XMultiServiceFactory * >( pServiceManager ),
OUString::createFromAscii( pImplName ),
-
FilterDetect_createInstance, FilterDetect_getSupportedServiceNames() ) );
-
-
if (xFactory.is())
-
{
-
xFactory->acquire();
-
pRet = xFactory.get();
-
}
-
}
-
return pRet;
-
}
}
diff --git a/filter/source/xmlfilterdetect/filterdetect.hxx b/filter/source/xmlfilterdetect/filterdetect.hxx
index b85b36b..62f7486 100644
--- a/filter/source/xmlfilterdetect/filterdetect.hxx
+++ b/filter/source/xmlfilterdetect/filterdetect.hxx
@@ -53,116 +53,70 @@ enum FilterType
* member calls */
class FilterDetect : public cppu::WeakImplHelper3
-
<
-
-
com::sun::star::document::XExtendedFilterDetection,
-
com::sun::star::lang::XInitialization,
-
com::sun::star::lang::XServiceInfo
-
>
{
protected:
- ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMSF;
-
- ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent > mxDoc;
-
- ::rtl::OUString msFilterName;
-
- ::com::sun::star::uno::Sequence< ::rtl::OUString > msUserData;
-
- ::rtl::OUString msTemplateName;
-
-
+ ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMSF;
+ ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent > mxDoc;
+ ::rtl::OUString msFilterName;
+ ::com::sun::star::uno::Sequence< ::rtl::OUString > msUserData;
+ ::rtl::OUString msTemplateName;
sal_Bool SAL_CALL exportImpl( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor )
-
throw (::com::sun::star::uno::RuntimeException);
sal_Bool SAL_CALL importImpl( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor )
-
throw (::com::sun::star::uno::RuntimeException);
-
-
-
-
public:
FilterDetect( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > &rxMSF)
-
: mxMSF( rxMSF ) {}
virtual ~FilterDetect() {}
-
-
-
-
-
//XExtendedFilterDetection
virtual ::rtl::OUString SAL_CALL detect( com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue >& lDescriptor )
throw( com::sun::star::uno::RuntimeException );
// XInitialization
-
virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments )
-
throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
-
-
// XServiceInfo
-
virtual ::rtl::OUString SAL_CALL getImplementationName( )
-
throw (::com::sun::star::uno::RuntimeException);
virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
-
throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( )
-
throw (::com::sun::star::uno::RuntimeException);
};
-
-
::rtl::OUString FilterDetect_getImplementationName()
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
sal_Bool SAL_CALL FilterDetect_supportsService( const ::rtl::OUString& ServiceName )
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL FilterDetect_getSupportedServiceNames( )
-
throw ( ::com::sun::star::uno::RuntimeException );
-
-
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
SAL_CALL FilterDetect_createInstance( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > & rSMgr)
-
throw ( ::com::sun::star::uno::Exception );
-
-
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
--
1.7.0.4
--------------050606060709060303020908--
More information about the LibreOffice
mailing list