fixed not working setAsReadOnActivate preferences/forum button

This commit is contained in:
csoler 2019-01-14 23:51:53 +01:00
parent 2de7ac26d5
commit 104e122102
No known key found for this signature in database
GPG Key ID: 7BCA522266C0804C

View File

@ -995,7 +995,10 @@ void GxsForumThreadWidget::changedThread(QModelIndex index)
#ifdef DEBUG_FORUMS
std::cerr << "Setting message read status to true" << std::endl;
#endif
mThreadModel->setMsgReadStatus(src_index, true,false);
bool setToReadOnActive = Settings->getForumMsgSetToReadOnActivate();
if(setToReadOnActive)
mThreadModel->setMsgReadStatus(src_index, true,false);
}
void GxsForumThreadWidget::clickedThread(QModelIndex index)
@ -1301,10 +1304,10 @@ void GxsForumThreadWidget::insertMessageData(const RsGxsForumMsg &msg)
uint32_t overall_reputation = rsReputations->overallReputationLevel(msg.mMeta.mAuthorId) ;
bool redacted = (overall_reputation == RsReputations::REPUTATION_LOCALLY_NEGATIVE) ;
#ifdef TO_REMOVE
bool setToReadOnActive = Settings->getForumMsgSetToReadOnActivate();
uint32_t status = msg.mMeta.mMsgStatus ;//item->data(RsGxsForumModel::COLUMN_THREAD_DATA, ROLE_THREAD_STATUS).toUInt();
#ifdef TO_REMOVE
QModelIndex index = getCurrentIndex();
if (IS_MSG_NEW(status)) {
if (setToReadOnActive) {