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 /sc | |
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 'sc')
-rw-r--r-- | sc/qa/unit/ucalc.cxx | 2 | ||||
-rw-r--r-- | sc/source/core/data/globalx.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/docshell/docsh8.cxx | 9 |
3 files changed, 8 insertions, 7 deletions
diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx index a6d51157228c..0dd8e4ea4a22 100644 --- a/sc/qa/unit/ucalc.cxx +++ b/sc/qa/unit/ucalc.cxx @@ -81,8 +81,6 @@ #include <com/sun/star/sheet/DataPilotFieldGroupBy.hpp> #include <com/sun/star/sheet/GeneralFunction.hpp> -#include <ucbhelper/contentbroker.hxx> - #include <iostream> #include <vector> diff --git a/sc/source/core/data/globalx.cxx b/sc/source/core/data/globalx.cxx index 5793a122fd07..5c00e72d893f 100644 --- a/sc/source/core/data/globalx.cxx +++ b/sc/source/core/data/globalx.cxx @@ -29,7 +29,6 @@ #include "callform.hxx" #include "global.hxx" #include <tools/urlobj.hxx> -#include <ucbhelper/contentbroker.hxx> #include <ucbhelper/content.hxx> #include <unotools/localfilehelper.hxx> @@ -79,7 +78,8 @@ void ScGlobal::InitAddIns() try { ::ucbhelper::Content aCnt( aObj.GetMainURL(INetURLObject::NO_DECODE), - Reference< XCommandEnvironment > () ); + Reference< XCommandEnvironment >(), + comphelper::getProcessComponentContext() ); Reference< sdbc::XResultSet > xResultSet; Sequence< rtl::OUString > aProps; try diff --git a/sc/source/ui/docshell/docsh8.cxx b/sc/source/ui/docshell/docsh8.cxx index 96f0a7b83ebe..63330ba9e907 100644 --- a/sc/source/ui/docshell/docsh8.cxx +++ b/sc/source/ui/docshell/docsh8.cxx @@ -187,7 +187,8 @@ bool ScDocShell::MoveFile( const INetURLObject& rSourceObj, const INetURLObject& try { ::ucbhelper::Content aDestPath( aDestPathObj.GetMainURL(INetURLObject::NO_DECODE), - uno::Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + uno::Reference< ::com::sun::star::ucb::XCommandEnvironment >(), + comphelper::getProcessComponentContext() ); uno::Reference< ::com::sun::star::ucb::XCommandInfo > xInfo = aDestPath.getCommands(); rtl::OUString aTransferName = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "transfer" )); if ( xInfo->hasCommandByName( aTransferName ) ) @@ -220,7 +221,8 @@ bool ScDocShell::KillFile( const INetURLObject& rURL ) try { ::ucbhelper::Content aCnt( rURL.GetMainURL(INetURLObject::NO_DECODE), - uno::Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + uno::Reference< ::com::sun::star::ucb::XCommandEnvironment >(), + comphelper::getProcessComponentContext() ); aCnt.executeCommand( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "delete" )), comphelper::makeBoolAny( sal_True ) ); } @@ -239,7 +241,8 @@ bool ScDocShell::IsDocument( const INetURLObject& rURL ) try { ::ucbhelper::Content aCnt( rURL.GetMainURL(INetURLObject::NO_DECODE), - uno::Reference< ::com::sun::star::ucb::XCommandEnvironment > () ); + uno::Reference< ::com::sun::star::ucb::XCommandEnvironment >(), + comphelper::getProcessComponentContext() ); bRet = aCnt.isDocument(); } catch( uno::Exception& ) |