diff options
Diffstat (limited to 'vcl/source/control/fixedhyper.cxx')
-rw-r--r-- | vcl/source/control/fixedhyper.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/vcl/source/control/fixedhyper.cxx b/vcl/source/control/fixedhyper.cxx index 4d0631b85867..49ce74bb502e 100644 --- a/vcl/source/control/fixedhyper.cxx +++ b/vcl/source/control/fixedhyper.cxx @@ -19,7 +19,7 @@ #include <vcl/fixedhyper.hxx> #include <vcl/svapp.hxx> -#include <vcl/layout.hxx> +#include <vcl/weld.hxx> #include <comphelper/anytostring.hxx> #include <comphelper/processfactory.hxx> #include <cppuhelper/exc_hlp.hxx> @@ -149,7 +149,7 @@ bool FixedHyperlink::set_property(const OString &rKey, const OUString &rValue) return true; } -IMPL_STATIC_LINK(FixedHyperlink, HandleClick, FixedHyperlink&, rHyperlink, void) +IMPL_LINK(FixedHyperlink, HandleClick, FixedHyperlink&, rHyperlink, void) { if ( rHyperlink.m_sURL.isEmpty() ) // Nothing to do, when the URL is empty return; @@ -165,10 +165,10 @@ IMPL_STATIC_LINK(FixedHyperlink, HandleClick, FixedHyperlink&, rHyperlink, void) { uno::Any exc(cppu::getCaughtException()); OUString msg(comphelper::anyToString(exc)); - const SolarMutexGuard guard; - ScopedVclPtrInstance< MessageDialog > aErrorBox(nullptr, msg); - aErrorBox->SetText( rHyperlink.GetText() ); - aErrorBox->Execute(); + SolarMutexGuard g; + std::unique_ptr<weld::MessageDialog> xErrorBox(Application::CreateMessageDialog(GetFrameWeld(), VclMessageType::Error, VclButtonsType::Ok, msg)); + xErrorBox->set_title(rHyperlink.GetText()); + xErrorBox->run(); } } |