diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-09-27 14:09:21 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-09-28 08:48:55 +0100 |
commit | aee968e3540faefeaba27832a3b537a512ba1fed (patch) | |
tree | 8cb6c46ef92044771c84618b2f8068dfa7882315 /vcl | |
parent | 9582aa03c5631f1a2b3fbe9a3001644f8ec3f33d (diff) |
adapt uipreviewer for ucbhelper change
Change-Id: I60463d107d49ecc78053dd2592fc207164708040
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/uipreviewer/previewer.cxx | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/vcl/source/uipreviewer/previewer.cxx b/vcl/source/uipreviewer/previewer.cxx index 24329863f6df..dc16a2a36387 100644 --- a/vcl/source/uipreviewer/previewer.cxx +++ b/vcl/source/uipreviewer/previewer.cxx @@ -10,11 +10,10 @@ #include <com/sun/star/lang/XComponent.hpp> #include <com/sun/star/lang/XMultiComponentFactory.hpp> #include <com/sun/star/lang/XMultiServiceFactory.hpp> +#include <com/sun/star/ucb/UniversalContentBroker.hpp> #include <comphelper/processfactory.hxx> #include <cppuhelper/bootstrap.hxx> #include <osl/file.hxx> -#include <ucbhelper/configurationkeys.hxx> -#include <ucbhelper/contentbroker.hxx> #include <vcl/builder.hxx> #include <vcl/dialog.hxx> #include <vcl/help.hxx> @@ -52,11 +51,10 @@ int UIPreviewApp::Main() uno::Reference<lang::XMultiServiceFactory> (xFactory, uno::UNO_QUERY_THROW); comphelper::setProcessServiceFactory(xSFactory); - // Create UCB. - uno::Sequence< uno::Any > aArgs(2); - aArgs[ 0 ] <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(UCB_CONFIGURATION_KEY1_LOCAL)); - aArgs[ 1 ] <<= rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(UCB_CONFIGURATION_KEY2_OFFICE)); - ::ucbhelper::ContentBroker::initialize(xSFactory, aArgs); + // Create UCB (for backwards compatibility, in case some code still uses + // plain createInstance w/o args directly to obtain an instance): + ::ucb::UniversalContentBroker::create( + comphelper::getProcessComponentContext() ); // turn on tooltips Help::EnableQuickHelp(); @@ -88,9 +86,6 @@ int UIPreviewApp::Main() } return false; - - ::ucbhelper::ContentBroker::deinitialize(); - return EXIT_SUCCESS; } |