summaryrefslogtreecommitdiff
path: root/svl
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2012-08-21 08:07:58 +0200
committerStephan Bergmann <sbergman@redhat.com>2012-08-27 15:40:07 +0200
commit8638f1e72a3fe830c0e8dcc1bd847d4fb9e599ee (patch)
treed398e9c43b4dd1570145210690a75762d81f4dc4 /svl
parent4381f3dd5ae9e042840a16f69d07267208160420 (diff)
fdo#46808, Adapt script::Converter service code to new style
Change-Id: I19b3ba7c978e02ce865360f0411007525012149c
Diffstat (limited to 'svl')
-rw-r--r--svl/source/items/globalnameitem.cxx5
-rw-r--r--svl/source/items/ilstitem.cxx5
2 files changed, 4 insertions, 6 deletions
diff --git a/svl/source/items/globalnameitem.cxx b/svl/source/items/globalnameitem.cxx
index 2e89bca14abd..333a97c3ae45 100644
--- a/svl/source/items/globalnameitem.cxx
+++ b/svl/source/items/globalnameitem.cxx
@@ -19,7 +19,7 @@
#include <com/sun/star/uno/Any.hxx>
#include <com/sun/star/uno/Sequence.hxx>
-#include <com/sun/star/script/XTypeConverter.hpp>
+#include <com/sun/star/script/Converter.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
@@ -73,8 +73,7 @@ SfxPoolItem* SfxGlobalNameItem::Clone(SfxItemPool *) const
bool SfxGlobalNameItem::PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 )
{
com::sun::star::uno::Reference < com::sun::star::script::XTypeConverter > xConverter
- ( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString("com.sun.star.script.Converter")),
- com::sun::star::uno::UNO_QUERY );
+ ( com::sun::star::script::Converter::create( ::comphelper::getProcessComponentContext() ));
com::sun::star::uno::Sequence< sal_Int8 > aSeq;
com::sun::star::uno::Any aNew;
diff --git a/svl/source/items/ilstitem.cxx b/svl/source/items/ilstitem.cxx
index 15398473b9d6..e9b94fdba65d 100644
--- a/svl/source/items/ilstitem.cxx
+++ b/svl/source/items/ilstitem.cxx
@@ -17,7 +17,7 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#include <com/sun/star/script/XTypeConverter.hpp>
+#include <com/sun/star/script/Converter.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <comphelper/processfactory.hxx>
@@ -73,8 +73,7 @@ SfxPoolItem* SfxIntegerListItem::Clone( SfxItemPool * ) const
bool SfxIntegerListItem::PutValue ( const com::sun::star::uno::Any& rVal, sal_uInt8 )
{
::com::sun::star::uno::Reference < ::com::sun::star::script::XTypeConverter > xConverter
- ( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString("com.sun.star.script.Converter")),
- ::com::sun::star::uno::UNO_QUERY );
+ ( ::com::sun::star::script::Converter::create(::comphelper::getProcessComponentContext()) );
::com::sun::star::uno::Any aNew;
try { aNew = xConverter->convertTo( rVal, ::getCppuType((const ::com::sun::star::uno::Sequence < sal_Int32 >*)0) ); }
catch (::com::sun::star::uno::Exception&)