Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
PIM Messagelib
Commits
3ab8d7f6
Commit
3ab8d7f6
authored
Feb 10, 2021
by
Laurent Montel
Browse files
Add support for define type where we can apply type
parent
0389cc4b
Pipeline
#50376
passed with stage
in 41 minutes and 47 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
3ab8d7f6
cmake_minimum_required
(
VERSION 3.5 FATAL_ERROR
)
set
(
PIM_VERSION
"5.16.4
4
"
)
set
(
PIM_VERSION
"5.16.4
5
"
)
if
(
POLICY CMP0053
)
cmake_policy
(
SET CMP0053 NEW
)
...
...
messagecomposer/src/plugineditor/plugineditorinterface.cpp
View file @
3ab8d7f6
...
...
@@ -21,6 +21,7 @@ public:
delete
mComposerInterface
;
}
PluginEditorInterface
::
ApplyOnFieldTypes
mApplyOnFieldTypes
;
PluginActionType
mActionType
;
QWidget
*
mParentWidget
=
nullptr
;
KPIMTextEdit
::
RichTextEditor
*
mRichTextEditor
=
nullptr
;
...
...
@@ -96,3 +97,13 @@ bool PluginEditorInterface::processProcessKeyEvent(QKeyEvent *event)
Q_UNUSED
(
event
)
return
false
;
}
PluginEditorInterface
::
ApplyOnFieldTypes
PluginEditorInterface
::
applyOnFieldTypes
()
const
{
return
d
->
mApplyOnFieldTypes
;
}
void
PluginEditorInterface
::
setApplyOnFieldTypes
(
PluginEditorInterface
::
ApplyOnFieldTypes
types
)
{
d
->
mApplyOnFieldTypes
=
types
;
}
messagecomposer/src/plugineditor/plugineditorinterface.h
View file @
3ab8d7f6
...
...
@@ -31,6 +31,10 @@ class MESSAGECOMPOSER_EXPORT PluginEditorInterface : public PimCommon::AbstractG
{
Q_OBJECT
public:
enum
ApplyOnFieldType
{
Composer
=
1
,
EmailFields
=
2
,
SubjectField
=
4
,
All
=
Composer
|
EmailFields
|
SubjectField
};
Q_FLAG
(
ApplyOnFieldType
)
Q_DECLARE_FLAGS
(
ApplyOnFieldTypes
,
ApplyOnFieldType
)
explicit
PluginEditorInterface
(
QObject
*
parent
=
nullptr
);
~
PluginEditorInterface
()
override
;
...
...
@@ -51,6 +55,9 @@ public:
virtual
bool
processProcessKeyEvent
(
QKeyEvent
*
event
);
Q_REQUIRED_RESULT
PluginEditorInterface
::
ApplyOnFieldTypes
applyOnFieldTypes
()
const
;
void
setApplyOnFieldTypes
(
PluginEditorInterface
::
ApplyOnFieldTypes
types
);
Q_SIGNALS:
void
emitPluginActivated
(
MessageComposer
::
PluginEditorInterface
*
interface
);
void
insertText
(
const
QString
&
str
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment