From d75144cf44779a8f6cc9bccf9b0a6328b94a5b90 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 21 Feb 2018 21:20:15 +0000 Subject: convert remaining InfoBox to weld::MessageDialog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I91d828e38d96264cf4a76f30940942556b8f78d8 Reviewed-on: https://gerrit.libreoffice.org/50205 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- uui/source/sslwarndlg.cxx | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) (limited to 'uui/source/sslwarndlg.cxx') diff --git a/uui/source/sslwarndlg.cxx b/uui/source/sslwarndlg.cxx index f88284a70610..5db56f855a95 100644 --- a/uui/source/sslwarndlg.cxx +++ b/uui/source/sslwarndlg.cxx @@ -27,7 +27,7 @@ using namespace css; -void SSLWarnDialog::ViewCert() +IMPL_LINK_NOARG(SSLWarnDialog, ViewCertHdl, ::Button*, void) { uno::Reference< css::security::XDocumentDigitalSignatures > xDocumentDigitalSignatures; @@ -36,27 +36,25 @@ void SSLWarnDialog::ViewCert() xDocumentDigitalSignatures.get()->showCertificate(m_rXCert); } - SSLWarnDialog::SSLWarnDialog(vcl::Window* pParent, const css::uno::Reference< css::security::XCertificate >& rXCert, const css::uno::Reference< css::uno::XComponentContext >& xContext) : MessageDialog(pParent, "SSLWarnDialog", "uui/ui/sslwarndialog.ui") + , m_xView(get("view")) , m_xContext(xContext) , m_rXCert(rXCert) { } -void SSLWarnDialog::response(short nResponseId) +void SSLWarnDialog::dispose() +{ + m_xView.clear(); + MessageDialog::dispose(); +} + +SSLWarnDialog::~SSLWarnDialog() { - switch (nResponseId) - { - case 101: - ViewCert(); - break; - default: - MessageDialog::response(nResponseId); - break; - } + disposeOnce(); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit v1.2.3