summaryrefslogtreecommitdiff
path: root/extensions/source/bibliography/bibbeam.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-01-31 17:19:17 +0200
committerNoel Grandin <noel@peralex.com>2013-02-11 08:02:18 +0200
commita9934b36fea86646586f10daaa310d7173ede795 (patch)
tree9105477aa9517cefb18b785b94ae7badda51a102 /extensions/source/bibliography/bibbeam.cxx
parent834dcf3acde06389d57bec64c2cd6cca8189c079 (diff)
fdo#46808, some simple conversions to XComponentContext
Change-Id: I68e90fde0645d4d1d518d22620d4c28ae91139d4
Diffstat (limited to 'extensions/source/bibliography/bibbeam.cxx')
-rw-r--r--extensions/source/bibliography/bibbeam.cxx10
1 files changed, 4 insertions, 6 deletions
diff --git a/extensions/source/bibliography/bibbeam.cxx b/extensions/source/bibliography/bibbeam.cxx
index 4eaf83ac9800..3a168a7445c8 100644
--- a/extensions/source/bibliography/bibbeam.cxx
+++ b/extensions/source/bibliography/bibbeam.cxx
@@ -137,9 +137,9 @@ namespace bib
if( m_xControlContainer.is())
{
- uno::Reference< lang::XMultiServiceFactory > xMgr = comphelper::getProcessServiceFactory();
+ uno::Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext();
- if ( m_xGridModel.is() && xMgr.is())
+ if ( m_xGridModel.is())
{
uno::Reference< XPropertySet > xPropSet( m_xGridModel, UNO_QUERY );
@@ -149,10 +149,8 @@ namespace bib
rtl::OUString aControlName;
aAny >>= aControlName;
- m_xControl = Reference< awt::XControl > (xMgr->createInstance( aControlName ), UNO_QUERY );
- DBG_ASSERT( m_xControl.is(), "no GridControl created" );
- if ( m_xControl.is() )
- m_xControl->setModel( m_xGridModel );
+ m_xControl = Reference< awt::XControl > ( xContext->getServiceManager()->createInstanceWithContext(aControlName, xContext), UNO_QUERY_THROW );
+ m_xControl->setModel( m_xGridModel );
}
if ( m_xControl.is() )