fixed adding groups to message recipient (Patch from Phenom, modified)

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7664 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2014-11-07 19:06:23 +00:00
parent 38bc87412d
commit 8edc8511c3

View File

@ -2348,23 +2348,15 @@ void MessageComposer::fileHashingFinished(QList<HashedFile> hashedFiles)
void MessageComposer::addContact(enumType type) void MessageComposer::addContact(enumType type)
{ {
// std::list<std::string> ids; std::list<RsPeerId> peerIds ;
// ui.friendSelectionWidget->selectedIds<std::string,FriendSelectionWidget::IDTYPE_GROUP>(ids,false); ui.friendSelectionWidget->selectedIds<RsPeerId,FriendSelectionWidget::IDTYPE_SSL>(peerIds, false);
//
// std::list<std::string>::iterator idIt;
// for (idIt = ids.begin(); idIt != ids.end(); ++idIt) {
// addRecipient(type, *idIt, true);
// }
std::list<RsPeerId> ids ; for (std::list<RsPeerId>::const_iterator idIt = peerIds.begin(); idIt != peerIds.end(); ++idIt)
ui.friendSelectionWidget->selectedIds<RsPeerId,FriendSelectionWidget::IDTYPE_SSL>(ids, true);
for (std::list<RsPeerId>::const_iterator idIt = ids.begin(); idIt != ids.end(); ++idIt) {
addRecipient(type, *idIt); addRecipient(type, *idIt);
}
std::list<RsGxsId> id2 ; std::list<RsGxsId> gxsIds ;
ui.friendSelectionWidget->selectedIds<RsGxsId,FriendSelectionWidget::IDTYPE_GXS>(id2, true); ui.friendSelectionWidget->selectedIds<RsGxsId,FriendSelectionWidget::IDTYPE_GXS>(gxsIds, false);
for (std::list<RsGxsId>::const_iterator idIt = id2.begin(); idIt != id2.end(); ++idIt) for (std::list<RsGxsId>::const_iterator idIt = gxsIds.begin(); idIt != gxsIds.end(); ++idIt)
addRecipient(type, *idIt); addRecipient(type, *idIt);
} }