mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
Merge pull request #791 from PhenomRetroShare/Fix_MissingMessageMarkedRead
Fix Missing messages when mark all as read.
This commit is contained in:
commit
8aa9be334f
@ -239,17 +239,21 @@ void RsGxsMsgMetaData::clear()
|
||||
mMsgId.clear();
|
||||
mThreadId.clear();
|
||||
mParentId.clear();
|
||||
mAuthorId.clear();
|
||||
mOrigMsgId.clear();
|
||||
mMsgName.clear();
|
||||
mServiceString.clear();
|
||||
mAuthorId.clear();
|
||||
|
||||
signSet.TlvClear();
|
||||
mMsgName.clear();
|
||||
mPublishTs = 0;
|
||||
mMsgFlags = 0;
|
||||
|
||||
mServiceString.clear();
|
||||
mMsgStatus = 0;
|
||||
mMsgSize = 0;
|
||||
mChildTs = 0;
|
||||
recvTS = 0;
|
||||
mHash.clear();
|
||||
validated = false;
|
||||
}
|
||||
|
||||
bool RsGxsMsgMetaData::serialise(void *data, uint32_t *size)
|
||||
|
@ -1849,6 +1849,18 @@ void GxsForumThreadWidget::setMsgReadStatus(QList<QTreeWidgetItem*> &rows, bool
|
||||
uint32_t token;
|
||||
rsGxsForums->setMessageReadStatus(token, msgPair, read);
|
||||
|
||||
// Look if older version exist to mark them too
|
||||
QMap<RsGxsMessageId,QVector<QPair<time_t,RsGxsMessageId> > >::const_iterator it = mPostVersions.find(mOrigThreadId) ;
|
||||
if(it != mPostVersions.end())
|
||||
{
|
||||
std::cerr << (*it).size() << " versions found " << std::endl;
|
||||
for(int i=0;i<(*it).size();++i)
|
||||
{
|
||||
msgPair = std::make_pair( groupId(), (*it)[i].second );
|
||||
rsGxsForums->setMessageReadStatus(token, msgPair, read);
|
||||
}
|
||||
}
|
||||
|
||||
/* Add message id to ignore list for the next updateDisplay */
|
||||
mIgnoredMsgId.push_back(RsGxsMessageId(msgId));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user