Forward display-name in VCards
This commit is contained in:
parent
f1734c98a8
commit
3ec7beccda
2 changed files with 10 additions and 1 deletions
|
@ -537,6 +537,15 @@ static void *notify_user_info(PurpleConnection *gc, const char *who, PurpleNotif
|
|||
vcardEntries = vcardEntries->next;
|
||||
}
|
||||
|
||||
const gchar *displayname = purple_connection_get_display_name(gc);
|
||||
if (!displayname) {
|
||||
displayname = purple_account_get_name_for_display(account);
|
||||
}
|
||||
|
||||
if (displayname) {
|
||||
nickname = displayname;
|
||||
}
|
||||
|
||||
if ((!firstName.empty() || !lastName.empty()) && fullName.empty())
|
||||
fullName = firstName + " " + lastName;
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ void NetworkPluginServer::handleVCardPayload(const std::string &data) {
|
|||
// TODO: ERROR
|
||||
return;
|
||||
}
|
||||
std::cout << "OMG?\n";
|
||||
|
||||
boost::shared_ptr<Swift::VCard> vcard(new Swift::VCard());
|
||||
vcard->setFullName(payload.fullname());
|
||||
vcard->setPhoto(Swift::createByteArray(payload.photo()));
|
||||
|
|
Loading…
Add table
Reference in a new issue