diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-09-14 18:08:57 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-09-14 18:24:49 +0200 |
commit | 9ac86f484b0c278aafbce685ed19d3ea005ee8f8 (patch) | |
tree | cf2fe16d76992bcbd1bd89a8693c5f4996cd55f2 /sfx2/source/appl | |
parent | 2e284203da7f9882842111265f5f68ea0a145065 (diff) |
Improvement on previous commit, UCB clean up
* As UCB is only ever initialized with "Local"/"Office", remove this
configuration vector completely. The "create" ctor creates an instance
internally initialized with those "Local"/"Office" keys. Special (test) code
can still instantiate an uninitialized one via plain createInstance. And for
backwards compatilibity process startup still ensures to create an initialized
instance early, in case there is still code out there (in extensions) that
later calls plain createInstance and expects to get the already-initialized
(single) instance.
* XInitialization is an "implementation detail" of the UniversalContentBroker
service, do not expose in XUniversalContentBroker.
* ucbhelper/configurationkeys.hxx is no longer needed and is removed.
* ucbhelper/contentbroker.hxx is an empty wrapper and is removed; however, that
requires ucbhelper::Content constructors to take explicit XComponentContext
arguments now.
* The only remaining code in ucbhelper/source/client/contentbroker.cxx is
Android-only InitUCBHelper. Is that relevant still?
Change-Id: I3f7bddd0456bffbcd13590c66d9011915c760f28
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r-- | sfx2/source/appl/appinit.cxx | 1 | ||||
-rw-r--r-- | sfx2/source/appl/newhelp.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/appl/sfxhelp.cxx | 3 | ||||
-rw-r--r-- | sfx2/source/appl/xpackcreator.cxx | 3 |
4 files changed, 6 insertions, 5 deletions
diff --git a/sfx2/source/appl/appinit.cxx b/sfx2/source/appl/appinit.cxx index 47e6bc67936d..d5f776b6e384 100644 --- a/sfx2/source/appl/appinit.cxx +++ b/sfx2/source/appl/appinit.cxx @@ -37,7 +37,6 @@ #include <unotools/configmgr.hxx> #include <rtl/ustrbuf.hxx> #include <osl/security.hxx> -#include <ucbhelper/configurationkeys.hxx> #include <unotools/pathoptions.hxx> #include <unotools/historyoptions.hxx> #include <unotools/moduleoptions.hxx> diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx index 69424dbe6516..f6da0cab9d22 100644 --- a/sfx2/source/appl/newhelp.cxx +++ b/sfx2/source/appl/newhelp.cxx @@ -634,7 +634,7 @@ void IndexTabPage_Impl::InitializeIndex() AppendConfigToken( aTemp, sal_True ); aURL = aTemp; - Content aCnt( aURL, Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + Content aCnt( aURL, Reference< ::com::sun::star::ucb::XCommandEnvironment >(), comphelper::getProcessComponentContext() ); ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > xInfo = aCnt.getProperties(); if ( xInfo->hasPropertyByName( PROPERTY_ANCHORREF ) ) { @@ -3340,7 +3340,7 @@ void SfxHelpWindow_Impl::DoAction( sal_uInt16 nActionId ) { try { - Content aCnt( aURL, Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + Content aCnt( aURL, Reference< ::com::sun::star::ucb::XCommandEnvironment >(), comphelper::getProcessComponentContext() ); ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > xInfo = aCnt.getProperties(); if ( xInfo->hasPropertyByName( PROPERTY_TITLE ) ) { diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx index f2d86c2520fa..ec88716e179d 100644 --- a/sfx2/source/appl/sfxhelp.cxx +++ b/sfx2/source/appl/sfxhelp.cxx @@ -177,7 +177,8 @@ sal_Bool GetHelpAnchor_Impl( const String& _rURL, String& _rAnchor ) try { ::ucbhelper::Content aCnt( INetURLObject( _rURL ).GetMainURL( INetURLObject::NO_DECODE ), - Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + Reference< ::com::sun::star::ucb::XCommandEnvironment >(), + comphelper::getProcessComponentContext() ); if ( ( aCnt.getPropertyValue( ::rtl::OUString("AnchorName") ) >>= sAnchor ) ) { diff --git a/sfx2/source/appl/xpackcreator.cxx b/sfx2/source/appl/xpackcreator.cxx index de3d37a002a1..302833dc9658 100644 --- a/sfx2/source/appl/xpackcreator.cxx +++ b/sfx2/source/appl/xpackcreator.cxx @@ -23,6 +23,7 @@ #include "xpackcreator.hxx" +#include <comphelper/processfactory.hxx> #include <sot/stg.hxx> #include <sot/storage.hxx> #include <tools/stream.hxx> @@ -79,7 +80,7 @@ void SAL_CALL OPackageStructureCreator::convertToPackage( const ::rtl::OUString& sal_Bool bSuccess = sal_False; ::ucbhelper::Content aContent; - if( ::ucbhelper::Content::create( aFolderUrl, xComEnv, aContent ) ) + if( ::ucbhelper::Content::create( aFolderUrl, xComEnv, comphelper::getProcessComponentContext(), aContent ) ) { SvStream* pTempStream = NULL; |