summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <montel@kde.org>2016-09-22 06:16:38 (GMT)
committerMontel Laurent <montel@kde.org>2016-09-22 06:16:38 (GMT)
commitae36c72023b5728be1a00ae325371433ad93443e (patch)
tree8cb768f36544f7239d36c244920622bbd9fcff26
parentd88a60e5b10f95691faece868b34c9c616173658 (diff)
Add plugin to interface
-rw-r--r--CMakeLists.txt2
-rw-r--r--messagecomposer/src/plugineditor/plugineditorinterface.cpp14
-rw-r--r--messagecomposer/src/plugineditor/plugineditorinterface.h4
3 files changed, 18 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 005e63a..a3cb9d1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -18,7 +18,7 @@ include(KDEFrameworkCompilerSettings NO_POLICY_SCOPE)
include(ECMQtDeclareLoggingCategory)
include(ECMAddTests)
-set(PIM_VERSION "5.3.58")
+set(PIM_VERSION "5.3.59")
set(MESSAGELIB_LIB_VERSION ${PIM_VERSION})
set(AKONADIMIME_LIB_VERSION "5.3.40")
diff --git a/messagecomposer/src/plugineditor/plugineditorinterface.cpp b/messagecomposer/src/plugineditor/plugineditorinterface.cpp
index 8abda2a..fe8b4ed 100644
--- a/messagecomposer/src/plugineditor/plugineditorinterface.cpp
+++ b/messagecomposer/src/plugineditor/plugineditorinterface.cpp
@@ -49,13 +49,15 @@ class MessageComposer::PluginEditorInterfacePrivate
public:
PluginEditorInterfacePrivate()
: mParentWidget(Q_NULLPTR),
- mRichTextEditor(Q_NULLPTR)
+ mRichTextEditor(Q_NULLPTR),
+ plugin(Q_NULLPTR)
{
}
ActionType mActionType;
QWidget *mParentWidget;
KPIMTextEdit::RichTextEditor *mRichTextEditor;
+ PluginEditor *plugin;
};
PluginEditorInterface::PluginEditorInterface(QObject *parent)
@@ -80,6 +82,16 @@ ActionType PluginEditorInterface::actionType() const
return d->mActionType;
}
+void PluginEditorInterface::setPlugin(PluginEditor *plugin)
+{
+ d->plugin = plugin;
+}
+
+PluginEditor *PluginEditorInterface::plugin() const
+{
+ return d->plugin;
+}
+
void PluginEditorInterface::setParentWidget(QWidget *parent)
{
d->mParentWidget = parent;
diff --git a/messagecomposer/src/plugineditor/plugineditorinterface.h b/messagecomposer/src/plugineditor/plugineditorinterface.h
index eb88b7e..e846578 100644
--- a/messagecomposer/src/plugineditor/plugineditorinterface.h
+++ b/messagecomposer/src/plugineditor/plugineditorinterface.h
@@ -56,6 +56,7 @@ private:
};
class PluginEditorInterfacePrivate;
+class PluginEditor;
class MESSAGECOMPOSER_EXPORT PluginEditorInterface : public QObject
{
Q_OBJECT
@@ -69,6 +70,9 @@ public:
virtual void createAction(KActionCollection *ac) = 0;
virtual void exec() = 0;
+ void setPlugin(PluginEditor *plugin);
+ PluginEditor *plugin() const;
+
void setParentWidget(QWidget *parent);
QWidget *parentWidget() const;