From b30ee83058793ea8fbb020e5ac8f118bd20853d5 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 12 Oct 2012 11:44:23 +0200 Subject: fdo#46808, use service constructor for beans::Introspection Change-Id: Ieb49277020d31779979d8eb508391d6f8b97bf94 --- basic/source/classes/sbunoobj.cxx | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) (limited to 'basic') diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx index cd43e1b4c6bd..6b635aa0d58c 100644 --- a/basic/source/classes/sbunoobj.cxx +++ b/basic/source/classes/sbunoobj.cxx @@ -47,6 +47,7 @@ #include #include #include +#include #include #include #include @@ -2421,18 +2422,8 @@ void SbUnoObject::doIntrospection( void ) if( !xIntrospection.is() ) { // get the introspection service - Reference< XMultiServiceFactory > xFactory( comphelper::getProcessServiceFactory() ); - if ( xFactory.is() ) - { - Reference< XInterface > xI = xFactory->createInstance( rtl::OUString("com.sun.star.beans.Introspection") ); - if (xI.is()) - xIntrospection = Reference< XIntrospection >::query( xI ); - } - } - if( !xIntrospection.is() ) - { - StarBASIC::FatalError( ERRCODE_BASIC_EXCEPTION ); - return; + Reference< XComponentContext > xContext( comphelper::getProcessComponentContext() ); + xIntrospection = Introspection::create( xContext ); } // pass the introspection -- cgit