Commit 16e178bf authored by Raine Makelainen's avatar Raine Makelainen

Merge branch 'jb40471' into 'master'

[qmf] Initialize messagelistmodel before processing add/remove/update of messages. Contributes to JB#40471

See merge request !12
parents adf8ca12 e6e12874
......@@ -306,9 +306,7 @@ bool QMailMessageListModelPrivate::processMessagesAdded(const QMailMessageIdList
return true;
}
if (!_initialised) {
init();
}
// Find if and where these messages should be added
if (!addMessages(ids)) {
......@@ -393,15 +391,13 @@ bool QMailMessageListModelPrivate::processMessagesUpdated(const QMailMessageIdLi
return true;
}
init();
// Find if and where these messages should be added/removed/updated
if (!updateMessages(ids)) {
return false;
}
if (!_initialised) {
init();
}
return true;
}
......@@ -519,9 +515,7 @@ bool QMailMessageListModelPrivate::processMessagesRemoved(const QMailMessageIdLi
return true;
}
if (!_initialised) {
init();
}
// Find if and where these messages should be removed from
if (!removeMessages(ids)) {
......
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