smsapp: Offer the default avatar if another wasn't found
This commit is contained in:
parent
a7ee4ef0c5
commit
a8c28a7ff1
1 changed files with 3 additions and 2 deletions
|
@ -25,6 +25,7 @@
|
|||
#include <QRegularExpression>
|
||||
#include <QString>
|
||||
#include <QLoggingCategory>
|
||||
#include <QStandardPaths>
|
||||
#include <QHash>
|
||||
|
||||
#include <KPeople/KPeople/PersonData>
|
||||
|
@ -254,8 +255,8 @@ QIcon SmsHelper::getIconForAddresses(const QList<ConversationAddress>& addresses
|
|||
if (personData) {
|
||||
icons.append(personData->photo());
|
||||
} else {
|
||||
// The contact is not known to KPeople
|
||||
// TODO: Use generic icon from KPeople
|
||||
static QString dummyAvatar = QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kf5/kpeople/dummy_avatar.png"));
|
||||
icons.append(QPixmap(dummyAvatar));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue