diff options
author | Noel Grandin <noel@peralex.com> | 2012-05-30 16:45:36 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-06-06 10:01:22 +0200 |
commit | 392a483e1040787857fa09fead0547d567c570b5 (patch) | |
tree | 76f2f1aab1a5a9c81c30e212e0df3f568fa92e34 /basic/source/uno | |
parent | d08578912f2c9ef42d4349079422e25b951e544e (diff) |
fdo#46808, Adapt UNO services to new style, Part 7, updating ::create
Update code to use factory method PathSubstitutions::create
Change-Id: I3721bd93c36b207d849eea19102f5ac61cadd205
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>, added some tweaks.
Diffstat (limited to 'basic/source/uno')
-rw-r--r-- | basic/source/uno/namecont.cxx | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx index 7a954000d239..2baa1853a35b 100644 --- a/basic/source/uno/namecont.cxx +++ b/basic/source/uno/namecont.cxx @@ -62,6 +62,7 @@ #include <com/sun/star/script/LibraryNotLoadedException.hpp> #include <com/sun/star/script/vba/VBAScriptEventId.hpp> #include <com/sun/star/ucb/SimpleFileAccess.hpp> +#include <com/sun/star/util/PathSubstitution.hpp> #include <com/sun/star/deployment/ExtensionManager.hpp> #include <comphelper/componentcontext.hxx> #include <comphelper/storagehelper.hxx> @@ -388,11 +389,7 @@ SfxLibraryContainer::SfxLibraryContainer( void ) mxSFI = ucb::SimpleFileAccess::create( comphelper::ComponentContext(mxMSF).getUNOContext() ); - mxStringSubstitution = Reference< XStringSubstitution >( mxMSF->createInstance - ( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.PathSubstitution")) ), UNO_QUERY ); - SAL_WARN_IF( - !mxStringSubstitution.is(), "basic", - "couldn't create PathSubstitution component"); + mxStringSubstitution = util::PathSubstitution::create( comphelper::ComponentContext(mxMSF).getUNOContext() ); } SfxLibraryContainer::~SfxLibraryContainer() |