fdo#46808, Convert XMultiServiceFactory to XComponentContext
Change-Id: I804845860bf28b2f87e0474bc54e821426473a0c
This commit is contained in:
parent
1a2ab98ab8
commit
fe9f937f46
@ -65,7 +65,7 @@ namespace framework
|
||||
// XInterface, XTypeProvider, XServiceInfo
|
||||
DECLARE_XSERVICEINFO
|
||||
|
||||
ImageManager( com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory > xServiceManager );
|
||||
ImageManager( const com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext >& rxContext );
|
||||
virtual ~ImageManager();
|
||||
|
||||
// XComponent
|
||||
|
@ -80,7 +80,7 @@ namespace framework
|
||||
//*****************************************************************************************************************
|
||||
// XInterface, XTypeProvider, XServiceInfo
|
||||
//*****************************************************************************************************************
|
||||
DEFINE_XSERVICEINFO_MULTISERVICE ( ImageManager ,
|
||||
DEFINE_XSERVICEINFO_MULTISERVICE_2 ( ImageManager ,
|
||||
::cppu::OWeakObject ,
|
||||
SERVICENAME_IMAGEMANAGER ,
|
||||
IMPLEMENTATIONNAME_IMAGEMANAGER
|
||||
@ -88,9 +88,9 @@ DEFINE_XSERVICEINFO_MULTISERVICE ( ImageManager
|
||||
|
||||
DEFINE_INIT_SERVICE ( ImageManager, {} )
|
||||
|
||||
ImageManager::ImageManager( uno::Reference< XMultiServiceFactory > xServiceManager ) :
|
||||
ImageManager::ImageManager( const uno::Reference< uno::XComponentContext >& rxContext ) :
|
||||
ThreadHelpBase( &Application::GetSolarMutex() )
|
||||
, m_pImpl( new ImageManagerImpl(comphelper::getComponentContext(xServiceManager),this,false) )
|
||||
, m_pImpl( new ImageManagerImpl(rxContext, this, false) )
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -1043,9 +1043,7 @@ Reference< XInterface > SAL_CALL UIConfigurationManager::getImageManager() throw
|
||||
|
||||
if ( !m_xImageManager.is() )
|
||||
{
|
||||
Reference<XMultiServiceFactory> xMSF(m_xContext->getServiceManager(), UNO_QUERY_THROW);
|
||||
|
||||
m_xImageManager = Reference< XComponent >( static_cast< cppu::OWeakObject *>( new ImageManager( xMSF )),
|
||||
m_xImageManager = Reference< XComponent >( static_cast< cppu::OWeakObject *>( new ImageManager( m_xContext )),
|
||||
UNO_QUERY );
|
||||
Reference< XInitialization > xInit( m_xImageManager, UNO_QUERY );
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user