mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-23 06:31:20 -04:00
improved name support for distant peers in messages
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6653 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
8aaa4db85c
commit
abd8c1e32f
3 changed files with 47 additions and 8 deletions
|
@ -1481,7 +1481,10 @@ static void processList(const QStringList &list, const QString &textSingular, co
|
|||
std::cerr << " RetroShareLink::process MessageRequest : id : " << link.hash().toStdString() << ", subject : " << link.name().toStdString() << std::endl;
|
||||
#endif
|
||||
RsPeerDetails detail;
|
||||
if (rsPeers->getPeerDetails(link.hash().toStdString(), detail)) {
|
||||
std::string dm_hash ;
|
||||
|
||||
if (rsPeers->getPeerDetails(link.hash().toStdString(), detail))
|
||||
{
|
||||
if (detail.accept_connection || detail.id == rsPeers->getOwnId() || detail.id == rsPeers->getGPGOwnId()) {
|
||||
MessageComposer *msg = MessageComposer::newMsg();
|
||||
msg->addRecipient(MessageComposer::TO, detail.id, false);
|
||||
|
@ -1490,7 +1493,21 @@ static void processList(const QStringList &list, const QString &textSingular, co
|
|||
}
|
||||
msg->show();
|
||||
messageStarted.append(PeerDefs::nameWithLocation(detail));
|
||||
} else {
|
||||
}
|
||||
else if(rsMsgs->getDistantMessageHash(detail.gpg_id,dm_hash))
|
||||
{
|
||||
MessageComposer *msg = MessageComposer::newMsg();
|
||||
msg->addRecipient(MessageComposer::TO, dm_hash,detail.gpg_id) ;
|
||||
|
||||
if (link.subject().isEmpty() == false) {
|
||||
msg->setTitleText(link.subject());
|
||||
}
|
||||
msg->show();
|
||||
messageStarted.append(PeerDefs::nameWithLocation(detail));
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
messageReceipientNotAccepted.append(PeerDefs::nameWithLocation(detail));
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue