Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
PIM
Akonadi Contacts
Commits
2f8ff889
Commit
2f8ff889
authored
Jan 06, 2017
by
Laurent Montel
😁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor optimization
parent
7de3475d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
8 deletions
+4
-8
src/contactmetadata.cpp
src/contactmetadata.cpp
+1
-5
src/standardcontactactionmanager.cpp
src/standardcontactactionmanager.cpp
+3
-3
No files found.
src/contactmetadata.cpp
View file @
2f8ff889
...
...
@@ -58,11 +58,7 @@ void ContactMetaData::load(const Akonadi::Item &contact)
ContactMetaDataAttribute
*
attribute
=
contact
.
attribute
<
ContactMetaDataAttribute
>
();
const
QVariantMap
metaData
=
attribute
->
metaData
();
if
(
metaData
.
contains
(
QStringLiteral
(
"DisplayNameMode"
)))
{
d
->
mDisplayNameMode
=
metaData
.
value
(
QStringLiteral
(
"DisplayNameMode"
)).
toInt
();
}
else
{
d
->
mDisplayNameMode
=
-
1
;
}
d
->
mDisplayNameMode
=
metaData
.
value
(
QStringLiteral
(
"DisplayNameMode"
),
-
1
).
toInt
();
d
->
mCustomFieldDescriptions
=
metaData
.
value
(
QStringLiteral
(
"CustomFieldDescriptions"
)).
toList
();
}
...
...
src/standardcontactactionmanager.cpp
View file @
2f8ff889
...
...
@@ -567,11 +567,11 @@ void StandardContactActionManager::setItemSelectionModel(QItemSelectionModel *se
QAction
*
StandardContactActionManager
::
createAction
(
Type
type
)
{
if
(
d
->
mActions
.
contains
(
type
))
{
return
d
->
mActions
.
value
(
type
);
QAction
*
action
=
d
->
mActions
.
value
(
type
);
if
(
action
)
{
return
action
;
}
QAction
*
action
=
nullptr
;
switch
(
type
)
{
case
CreateContact
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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