diff options
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/doc/doctemplates.cxx | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx index d85ca00f72f5..c25faa6a9811 100644 --- a/sfx2/source/doc/doctemplates.cxx +++ b/sfx2/source/doc/doctemplates.cxx @@ -40,6 +40,7 @@ #include <com/sun/star/beans/XPropertyContainer.hpp> #include <com/sun/star/beans/StringPair.hpp> #include <com/sun/star/util/theMacroExpander.hpp> +#include <com/sun/star/util/theOfficeInstallationDirectories.hpp> #include <com/sun/star/configuration/theDefaultProvider.hpp> #include <com/sun/star/container/XContainerQuery.hpp> #include <com/sun/star/document/XTypeDetection.hpp> @@ -2830,15 +2831,7 @@ void SfxURLRelocator_Impl::initOfficeInstDirs() uno::Reference< XComponentContext > xCtx( comphelper::getComponentContext( mxFactory ) ); - xCtx->getValueByName( - rtl::OUString( - "/singletons/" - "com.sun.star.util.theOfficeInstallationDirectories" ) ) - >>= mxOfficeInstDirs; - - OSL_ENSURE( mxOfficeInstDirs.is(), - "Unable to obtain office installation directory " - "singleton!" ); + mxOfficeInstDirs = theOfficeInstallationDirectories::get(xCtx); } } } |