summaryrefslogtreecommitdiff
path: root/svtools/source/graphic
diff options
context:
space:
mode:
authorMarcos Paulo de Souza <marcos.souza.org@gmail.com>2013-10-16 19:25:05 -0300
committerStephan Bergmann <sbergman@redhat.com>2013-10-17 14:43:28 +0200
commit3d3293144b0e0d2d28136b1b2c7154d6352463b8 (patch)
tree1ef57838dc7fa88515a69dce12612e6071bc08b9 /svtools/source/graphic
parent6fe26facd06d4d1e5e37384d25d83209209229fa (diff)
fdo#54938: Adapt svtools and comphelper module ...
to use cppu::supportsService and other pieces. Change-Id: I16893b3d31a8055acd214ff23d01e63d38fe0826 Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'svtools/source/graphic')
-rw-r--r--svtools/source/graphic/descriptor.cxx12
-rw-r--r--svtools/source/graphic/renderer.cxx12
2 files changed, 4 insertions, 20 deletions
diff --git a/svtools/source/graphic/descriptor.cxx b/svtools/source/graphic/descriptor.cxx
index 1f6515a5e143..16f3e507ff24 100644
--- a/svtools/source/graphic/descriptor.cxx
+++ b/svtools/source/graphic/descriptor.cxx
@@ -24,6 +24,7 @@
#include <vcl/graphicfilter.hxx>
#include <svl/itemprop.hxx>
#include <comphelper/servicehelper.hxx>
+#include <cppuhelper/supportsservice.hxx>
#include <com/sun/star/beans/PropertyState.hpp>
#include <com/sun/star/beans/PropertyAttribute.hpp>
@@ -245,19 +246,10 @@ OUString SAL_CALL GraphicDescriptor::getImplementationName()
return getImplementationName_Static();
}
-// ------------------------------------------------------------------------------
-
sal_Bool SAL_CALL GraphicDescriptor::supportsService( const OUString& ServiceName )
throw( uno::RuntimeException )
{
- uno::Sequence< OUString > aSNL( getSupportedServiceNames() );
- const OUString* pArray = aSNL.getConstArray();
-
- for( sal_Int32 i = 0; i < aSNL.getLength(); i++ )
- if( pArray[i] == ServiceName )
- return true;
-
- return false;
+ return cppu::supportsService(this, ServiceName);
}
// ------------------------------------------------------------------------------
diff --git a/svtools/source/graphic/renderer.cxx b/svtools/source/graphic/renderer.cxx
index 95097fbe7bd1..7d687ef96dce 100644
--- a/svtools/source/graphic/renderer.cxx
+++ b/svtools/source/graphic/renderer.cxx
@@ -25,6 +25,7 @@
#include <vcl/svapp.hxx>
#include <toolkit/helper/vclunohelper.hxx>
#include <comphelper/propertysetinfo.hxx>
+#include <cppuhelper/supportsservice.hxx>
#include <svl/itemprop.hxx>
#include <svtools/grfmgr.hxx>
#include <comphelper/servicehelper.hxx>
@@ -139,19 +140,10 @@ OUString SAL_CALL GraphicRendererVCL::getImplementationName()
return getImplementationName_Static();
}
-// ------------------------------------------------------------------------------
-
sal_Bool SAL_CALL GraphicRendererVCL::supportsService( const OUString& ServiceName )
throw( uno::RuntimeException )
{
- uno::Sequence< OUString > aSNL( getSupportedServiceNames() );
- const OUString* pArray = aSNL.getConstArray();
-
- for( sal_Int32 i = 0; i < aSNL.getLength(); i++ )
- if( pArray[i] == ServiceName )
- return true;
-
- return false;
+ return cppu::supportsService(this, ServiceName);
}
// ------------------------------------------------------------------------------