some warnings fixed, new way of drawing avatars in message line
This commit is contained in:
parent
e27ae1a82f
commit
7130e674c4
7 changed files with 65 additions and 16 deletions
|
@ -601,6 +601,9 @@ void Core::Account::onClientError(QXmppClient::Error err)
|
|||
errorText = "Policy violation";
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
errorText = "Unknown Error";
|
||||
break;
|
||||
}
|
||||
|
||||
errorType = "Client stream error";
|
||||
|
@ -837,7 +840,6 @@ void Core::Account::uploadVCard(const Shared::VCard& card)
|
|||
QXmppVCardIq iq;
|
||||
initializeQXmppVCard(iq, card);
|
||||
|
||||
bool avatarChanged = false;
|
||||
if (card.getAvatarType() != Shared::Avatar::empty) {
|
||||
QString newPath = card.getAvatarPath();
|
||||
QString oldPath = getAvatarPath();
|
||||
|
@ -859,7 +861,6 @@ void Core::Account::uploadVCard(const Shared::VCard& card)
|
|||
}
|
||||
} else {
|
||||
data = avatar.readAll();
|
||||
avatarChanged = true;
|
||||
}
|
||||
} else {
|
||||
if (avatarType.size() > 0) {
|
||||
|
|
|
@ -264,7 +264,7 @@ void Core::initializeQXmppVCard(QXmppVCardIq& iq, const Shared::VCard& card) {
|
|||
phone.setType(phone.type() | QXmppVCardPhone::Preferred);
|
||||
}
|
||||
}
|
||||
for (const std::pair<QString, QXmppVCardPhone>& phone : phones) {
|
||||
for (const std::pair<const QString, QXmppVCardPhone>& phone : phones) {
|
||||
phs.push_back(phone.second);
|
||||
}
|
||||
|
||||
|
|
|
@ -356,7 +356,7 @@ Shared::VCard Core::Conference::handleResponseVCard(const QXmppVCardIq& card, co
|
|||
QMap<QString, QVariant> Core::Conference::getAllAvatars() const
|
||||
{
|
||||
QMap<QString, QVariant> result;
|
||||
for (const std::pair<QString, Archive::AvatarInfo>& pair : exParticipants) {
|
||||
for (const std::pair<const QString, Archive::AvatarInfo>& pair : exParticipants) {
|
||||
result.insert(pair.first, avatarPath(pair.first) + "." + pair.second.type);
|
||||
}
|
||||
return result;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue