Commit ff70e5ab authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use directly Akonadi::AgentConfigurationDialog

parent d4c9cda3
Pipeline #76607 passed with stage
in 6 minutes and 29 seconds
......@@ -17,6 +17,7 @@ target_link_libraries(mailtransport_akonadiplugin
KF5::MailTransportAkonadi
KF5::CoreAddons
KF5::AkonadiCore
KF5::AkonadiWidgets
KF5::I18n
KF5::ConfigWidgets
Qt::DBus
......
......@@ -9,6 +9,7 @@
#include "resourcesendjob_p.h"
#include <AkonadiCore/AgentInstanceCreateJob>
#include <AkonadiCore/AgentManager>
#include <AkonadiWidgets/AgentConfigurationDialog>
#include <KPluginFactory>
#include <MailTransport/Transport>
......@@ -71,7 +72,9 @@ bool AkonadiMailTransportPlugin::configureTransport(const QString &identifier, M
qCWarning(MAILTRANSPORT_AKONADI_LOG) << "Invalid resource instance" << transport->host();
return false;
}
instance.configure(parent); // Async...
QPointer<Akonadi::AgentConfigurationDialog> dlg = new Akonadi::AgentConfigurationDialog(instance, parent); // Async...
dlg->exec();
delete dlg;
transport->save();
return true; // No way to know here if the user cancelled or not.
}
......
Supports Markdown
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