Commit 31b9eac2 authored by Laurent Montel's avatar Laurent Montel 😁

Remove mailtransport namespace

parent c508520d
......@@ -25,11 +25,10 @@
#include <QDialogButtonBox>
#include <QVBoxLayout>
#include <QPushButton>
#include <QDebug>
using namespace MailTransport;
SendMailConfigDialog::SendMailConfigDialog(Transport *transport, QWidget *parent)
SendMailConfigDialog::SendMailConfigDialog(MailTransport::Transport *transport, QWidget *parent)
: QDialog(parent)
, mTransport(transport)
, mConfigWidget(nullptr)
......@@ -50,7 +49,7 @@ SendMailConfigDialog::SendMailConfigDialog(Transport *transport, QWidget *parent
connect(mOkButton, &QAbstractButton::clicked, this, &SendMailConfigDialog::okClicked);
connect(buttonBox, &QDialogButtonBox::accepted, this, &SendMailConfigDialog::accept);
connect(buttonBox, &QDialogButtonBox::rejected, this, &SendMailConfigDialog::reject);
connect(mConfigWidget, &SendmailConfigWidget::enableButtonOk, this, &SendMailConfigDialog::slotEnabledOkButton);
connect(mConfigWidget, &MailTransport::SendmailConfigWidget::enableButtonOk, this, &SendMailConfigDialog::slotEnabledOkButton);
slotEnabledOkButton(!mConfigWidget->pathIsEmpty());
}
......@@ -73,5 +72,3 @@ void SendMailConfigDialog::slotTextChanged(const QString &text)
{
mOkButton->setEnabled(!text.isEmpty());
}
#include "moc_sendmailconfigdialog.cpp"
......@@ -24,12 +24,12 @@
namespace MailTransport {
class Transport;
class SendmailConfigWidget;
}
class SendMailConfigDialog : public QDialog
{
Q_OBJECT
public:
explicit SendMailConfigDialog(Transport *transport, QWidget *parent = nullptr);
explicit SendMailConfigDialog(MailTransport::Transport *transport, QWidget *parent = nullptr);
virtual ~SendMailConfigDialog();
private:
......@@ -37,10 +37,9 @@ private:
void slotTextChanged(const QString &text);
void slotEnabledOkButton(bool);
Transport *mTransport;
MailTransport::Transport *mTransport;
MailTransport::SendmailConfigWidget *mConfigWidget;
QPushButton *mOkButton;
};
} // namespace MailTransport
#endif
......@@ -49,8 +49,8 @@ QVector<MailTransport::TransportAbstractPluginInfo> SendMailTransportPlugin::nam
bool SendMailTransportPlugin::configureTransport(const QString &identifier, MailTransport::Transport *transport, QWidget *parent)
{
Q_UNUSED(identifier);
QPointer<MailTransport::SendMailConfigDialog> transportConfigDialog
= new MailTransport::SendMailConfigDialog(transport, parent);
QPointer<SendMailConfigDialog> transportConfigDialog
= new SendMailConfigDialog(transport, parent);
transportConfigDialog->setWindowTitle(i18n("Configure account"));
bool okClicked = (transportConfigDialog->exec() == QDialog::Accepted);
delete transportConfigDialog;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment