diff options
Diffstat (limited to 'basctl/source/dlged/dlgedfac.cxx')
-rw-r--r-- | basctl/source/dlged/dlgedfac.cxx | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/basctl/source/dlged/dlgedfac.cxx b/basctl/source/dlged/dlgedfac.cxx index 1ffbff22968d..a092c8ffeea9 100644 --- a/basctl/source/dlged/dlgedfac.cxx +++ b/basctl/source/dlged/dlgedfac.cxx @@ -24,6 +24,8 @@ #include <com/sun/star/beans/PropertyValue.hpp> #include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/awt/ScrollBarOrientation.hpp> +#include <com/sun/star/awt/UnoControlDialogModel.hpp> + namespace basctl { @@ -46,17 +48,11 @@ DlgEdFactory::~DlgEdFactory() IMPL_LINK( DlgEdFactory, MakeObject, SdrObjFactory *, pObjFactory ) { static bool bNeedsInit = true; - static uno::Reference< lang::XMultiServiceFactory > xDialogSFact; + static uno::Reference< awt::XUnoControlDialogModel > xDialogSFact; if( bNeedsInit ) { - uno::Reference< lang::XMultiServiceFactory > xMSF = ::comphelper::getProcessServiceFactory(); - uno::Reference< container::XNameContainer > xC( xMSF->createInstance( "com.sun.star.awt.UnoControlDialogModel" ), uno::UNO_QUERY ); - if( xC.is() ) - { - uno::Reference< lang::XMultiServiceFactory > xModFact( xC, uno::UNO_QUERY ); - xDialogSFact = xModFact; - } + xDialogSFact = awt::UnoControlDialogModel::create( ::comphelper::getProcessComponentContext() ); bNeedsInit = false; } |