From 9738002eca0f7cba337ae856cb5bce8ba93ee293 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 4 Sep 2012 13:49:59 +0200 Subject: fdo#46808, Adapt drawing::ShapeCollection UNO service to new style No client code is using the XComponent interface, so drop it. Change-Id: Id8f6da1248da641dcc0a3cb6d0a70e3bf29e5c99 --- vbahelper/source/vbahelper/vbashaperange.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'vbahelper/source') diff --git a/vbahelper/source/vbahelper/vbashaperange.cxx b/vbahelper/source/vbahelper/vbashaperange.cxx index fb2ca53022bd..87168bbcead7 100644 --- a/vbahelper/source/vbahelper/vbashaperange.cxx +++ b/vbahelper/source/vbahelper/vbashaperange.cxx @@ -16,6 +16,7 @@ * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include #include #include #include @@ -73,8 +74,7 @@ ScVbaShapeRange::getShapes() throw (uno::RuntimeException) { if ( !m_xShapes.is() ) { - uno::Reference< lang::XMultiServiceFactory > xMSF( mxContext->getServiceManager(), uno::UNO_QUERY_THROW ); - m_xShapes.set( xMSF->createInstance( rtl::OUString("com.sun.star.drawing.ShapeCollection") ), uno::UNO_QUERY_THROW ); + m_xShapes.set( drawing::ShapeCollection::create(mxContext), uno::UNO_QUERY_THROW ); sal_Int32 nLen = m_xIndexAccess->getCount(); for ( sal_Int32 index = 0; index < nLen; ++index ) m_xShapes->add( uno::Reference< drawing::XShape >( m_xIndexAccess->getByIndex( index ), uno::UNO_QUERY_THROW ) ); -- cgit