Commit e377ed0c authored by Laurent Montel's avatar Laurent Montel 😁

Continue to create it

parent bee2836e
......@@ -18,9 +18,16 @@
*/
#include "confirmaddressplugin.h"
#include "confirmaddressinterface.h"
ConfirmAddressPlugin::ConfirmAddressPlugin(QObject *parent)
: MessageComposer::PluginEditorCheckBeforeSend()
#include <KLocalizedString>
#include <kpluginfactory.h>
K_PLUGIN_FACTORY_WITH_JSON(ChangeCasePluginEditorFactory, "kmail_confirmaddressplugin.json", registerPlugin<ConfirmAddressPlugin>();)
ConfirmAddressPlugin::ConfirmAddressPlugin(QObject *parent, const QList<QVariant> &)
: MessageComposer::PluginEditorCheckBeforeSend(parent)
{
}
......@@ -32,5 +39,9 @@ ConfirmAddressPlugin::~ConfirmAddressPlugin()
MessageComposer::PluginEditorCheckBeforeSendInterface *ConfirmAddressPlugin::createInterface(QWidget *parent)
{
return {};
ConfirmAddressInterface *interface = new ConfirmAddressInterface(this);
interface->setParentWidget(parent);
return interface;
}
#include "confirmaddressplugin.moc"
......@@ -20,13 +20,14 @@
#ifndef CONFIRMADDRESSPLUGIN_H
#define CONFIRMADDRESSPLUGIN_H
#include <QVariant>
#include <MessageComposer/PluginEditorCheckBeforeSend>
class ConfirmAddressPlugin : public MessageComposer::PluginEditorCheckBeforeSend
{
Q_OBJECT
public:
explicit ConfirmAddressPlugin(QObject *parent = Q_NULLPTR);
explicit ConfirmAddressPlugin(QObject *parent = Q_NULLPTR, const QList<QVariant> & = {});
~ConfirmAddressPlugin();
MessageComposer::PluginEditorCheckBeforeSendInterface *createInterface(QWidget *parent) Q_DECL_OVERRIDE;
......
{
"KPlugin": {
"Name": "Confirm Address",
"ServiceTypes": [
"KMailEditor/PluginCheckBeforeSend"
],
"Version": "1.0"
}
}
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