diff options
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_dialog2.cxx | 4 | ||||
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_updatedialog.cxx | 11 |
2 files changed, 6 insertions, 9 deletions
diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx index 87c25cb7035b..cb80e01ea78a 100644 --- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx +++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx @@ -68,7 +68,7 @@ #include "com/sun/star/i18n/CollatorOptions.hpp" #include "com/sun/star/system/SystemShellExecuteFlags.hpp" -#include "com/sun/star/system/XSystemShellExecute.hpp" +#include "com/sun/star/system/SystemShellExecute.hpp" #include "com/sun/star/ui/dialogs/ExecutableDialogResults.hpp" #include "com/sun/star/ui/dialogs/TemplateDescription.hpp" @@ -632,7 +632,7 @@ void DialogHelper::openWebBrowser( const OUString & sURL, const OUString &sTitle try { uno::Reference< XSystemShellExecute > xSystemShellExecute( - m_xContext->getServiceManager()->createInstanceWithContext( OUSTR( "com.sun.star.system.SystemShellExecute" ), m_xContext), uno::UNO_QUERY_THROW); + SystemShellExecute::create(m_xContext)); //throws css::lang::IllegalArgumentException, css::system::SystemShellExecuteException xSystemShellExecute->execute( sURL, OUString(), SystemShellExecuteFlags::URIS_ONLY ); } diff --git a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx index 6704da10192b..e79d94df7e0d 100644 --- a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx +++ b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx @@ -65,7 +65,7 @@ #include "com/sun/star/lang/XMultiComponentFactory.hpp" #include "com/sun/star/lang/XSingleServiceFactory.hpp" #include "com/sun/star/system/SystemShellExecuteFlags.hpp" -#include "com/sun/star/system/XSystemShellExecute.hpp" +#include "com/sun/star/system/SystemShellExecute.hpp" #include "com/sun/star/task/XAbortChannel.hpp" #include "com/sun/star/task/XJob.hpp" #include "com/sun/star/ucb/CommandAbortedException.hpp" @@ -1413,13 +1413,10 @@ IMPL_LINK( UpdateDialog, hyperlink_clicked, svt::FixedHyperlink*, pHyperlink ) try { - uno::Reference< com::sun::star::system::XSystemShellExecute > xSystemShellExecute( - m_context->getServiceManager()->createInstanceWithContext( - OUSTR( "com.sun.star.system.SystemShellExecute" ), - m_context), uno::UNO_QUERY_THROW); + uno::Reference< system::XSystemShellExecute > xSystemShellExecute( + system::SystemShellExecute::create(m_context) ); //throws lang::IllegalArgumentException, system::SystemShellExecuteException - xSystemShellExecute->execute( - sURL, ::rtl::OUString(), com::sun::star::system::SystemShellExecuteFlags::URIS_ONLY); + xSystemShellExecute->execute( sURL, ::rtl::OUString(), system::SystemShellExecuteFlags::URIS_ONLY); } catch ( const uno::Exception& ) { |