mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-08-08 14:22:31 -04:00
fixed GUI update of avatars and status for distant chat. Updated backend for new model. Fixed a few bugs in serialisation
This commit is contained in:
parent
6951d730a5
commit
81ab43beb9
27 changed files with 515 additions and 289 deletions
|
@ -208,7 +208,7 @@ p3Config::p3Config()
|
|||
}
|
||||
|
||||
|
||||
bool p3Config::loadConfiguration(RsFileHash &loadHash)
|
||||
bool p3Config::loadConfiguration(RsFileHash& /* loadHash */)
|
||||
{
|
||||
return loadConfig();
|
||||
}
|
||||
|
|
|
@ -99,17 +99,14 @@ void p3HistoryMgr::addMessage(const ChatMessage& cm)
|
|||
enabled = true;
|
||||
}
|
||||
|
||||
if (cm.chat_id.isGxsId() && mPrivateEnable == true) {
|
||||
if (cm.incoming) {
|
||||
peerName = cm.chat_id.toGxsId().toStdString();
|
||||
} else {
|
||||
uint32_t status;
|
||||
DistantChatPeerInfo dcpinfo;
|
||||
if (rsMsgs->getDistantChatStatus(cm.chat_id.toPeerId(), dcpinfo))
|
||||
peerName = cm.chat_id.toPeerId().toStdString();
|
||||
}
|
||||
enabled = true;
|
||||
}
|
||||
if(cm.chat_id.isDistantChatId())
|
||||
{
|
||||
uint32_t status;
|
||||
DistantChatPeerInfo dcpinfo;
|
||||
if (rsMsgs->getDistantChatStatus(cm.chat_id.toDistantChatId(), dcpinfo))
|
||||
peerName = cm.chat_id.toPeerId().toStdString();
|
||||
enabled = true;
|
||||
}
|
||||
|
||||
if(enabled == false)
|
||||
return;
|
||||
|
@ -397,8 +394,8 @@ bool p3HistoryMgr::chatIdToVirtualPeerId(ChatId chat_id, RsPeerId &peer_id)
|
|||
return true;
|
||||
}
|
||||
|
||||
if (chat_id.isGxsId()) {
|
||||
peer_id = RsPeerId(chat_id.toGxsId());
|
||||
if (chat_id.isDistantChatId()) {
|
||||
peer_id = RsPeerId(chat_id.toDistantChatId());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -436,7 +433,7 @@ bool p3HistoryMgr::getMessages(const ChatId &chatId, std::list<HistoryMsg> &msgs
|
|||
if (chatId.isLobbyId() && mLobbyEnable == true) {
|
||||
enabled = true;
|
||||
}
|
||||
if (chatId.isGxsId() && mPrivateEnable == true) {
|
||||
if (chatId.isDistantChatId() && mPrivateEnable == true) {
|
||||
enabled = true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue