mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-21 12:54:26 -04:00
fixed up nickname completion in chat lobbies
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8092 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
1991d6992d
commit
50caf89655
1 changed files with 162 additions and 158 deletions
|
@ -667,8 +667,12 @@ void ChatWidget::completeNickname(bool reverse)
|
||||||
if (word.length() > 0) {
|
if (word.length() > 0) {
|
||||||
// Sort participants list
|
// Sort participants list
|
||||||
std::list<QString> participants;
|
std::list<QString> participants;
|
||||||
for ( std::map<RsGxsId,time_t>::const_iterator it = lobby.gxs_ids.begin(); it != lobby.gxs_ids.end(); ++it) {
|
RsIdentityDetails details ;
|
||||||
participants.push_front(QString::fromUtf8(it->first.toStdString().c_str()));
|
|
||||||
|
for ( std::map<RsGxsId,time_t>::const_iterator it = lobby.gxs_ids.begin(); it != lobby.gxs_ids.end(); ++it)
|
||||||
|
{
|
||||||
|
if(rsIdentity->getIdDetails(it->first,details))
|
||||||
|
participants.push_front(QString::fromUtf8(details.mNickname.c_str()));
|
||||||
}
|
}
|
||||||
participants.sort(caseInsensitiveCompare);
|
participants.sort(caseInsensitiveCompare);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue