diff options
author | Miklos Vajna <vmiklos@suse.cz> | 2012-07-12 16:19:37 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@suse.cz> | 2012-07-12 16:20:51 +0200 |
commit | 28d8b54c142df38b94079cf0d93f09c2a008459b (patch) | |
tree | 1fc78c5e61db0c2ddf4937066eb216c1feadbcbc /cui | |
parent | 058116026965ad31164fe60d5cd8a6d5fbbe8f65 (diff) |
about dialog: use new configmgr api
Change-Id: Ife65c0d9417c31e80d11e2e97ffd06765d90fb1e
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/dialogs/about.cxx | 28 |
1 files changed, 3 insertions, 25 deletions
diff --git a/cui/source/dialogs/about.cxx b/cui/source/dialogs/about.cxx index 21e4592376bb..6dc820d2e5cb 100644 --- a/cui/source/dialogs/about.cxx +++ b/cui/source/dialogs/about.cxx @@ -56,6 +56,7 @@ #include <rtl/ustrbuf.hxx> #include <vcl/bitmap.hxx> #include <vcl/rendergraphicrasterizer.hxx> +#include <officecfg/Office/Common.hxx> using namespace ::com::sun::star::uno; using namespace ::com::sun::star::beans; @@ -124,31 +125,8 @@ IMPL_LINK( AboutDialog, HandleClick, PushButton*, pButton ) sURL = m_aCreditsLinkStr; else if ( pDialogButton == (AboutDialogButton*)WEBSITE_BUTTON ) { - try - { - Reference<lang::XMultiServiceFactory> xConfig( comphelper::getProcessServiceFactory()->createInstance(rtl::OUString( "com.sun.star.configuration.ConfigurationProvider" )),UNO_QUERY); - if( xConfig.is() ) - { - Sequence<Any> args(1); - PropertyValue val( - rtl::OUString( "nodepath" ), - 0, - Any(rtl::OUString( "/org.openoffice.Office.Common/Help/StartCenter" )), - PropertyState_DIRECT_VALUE); - args.getArray()[0] <<= val; - Reference<container::XNameAccess> xNameAccess(xConfig->createInstanceWithArguments(rtl::OUString( "com.sun.star.configuration.ConfigurationAccess" ),args), UNO_QUERY); - if( xNameAccess.is() ) - { - //throws css::container::NoSuchElementException, css::lang::WrappedTargetException - Any value( xNameAccess->getByName(rtl::OUString( "InfoURL" )) ); - sURL = value.get<rtl::OUString> (); - localizeWebserviceURI(sURL); - } - } - } - catch (const Exception&) - { - } + sURL = officecfg::Office::Common::Help::StartCenter::InfoURL::get(); + localizeWebserviceURI(sURL); } // If the URL is empty, don't do anything |