Fix for Card View to show the Banned Image when author is banned.

This commit is contained in:
defnax 2020-10-08 19:56:08 +02:00
parent 05a97c13a7
commit d8f65f0c76

View file

@ -479,6 +479,15 @@ void BoardPostDisplayWidget_card::setup()
{
BoardPostDisplayWidgetBase::setup();
RsReputationLevel overall_reputation = rsReputations->overallReputationLevel(mPost.mMeta.mAuthorId);
bool redacted = (overall_reputation == RsReputationLevel::LOCALLY_NEGATIVE);
if(redacted)
{
ui->pictureLabel->setPixmap( FilesDefs::getPixmapFromQtResourcePath(":/images/thumb-blocked.png") );
}
else
{
if(mPost.mImage.mData != NULL)
{
QPixmap pixmap;
@ -497,6 +506,7 @@ void BoardPostDisplayWidget_card::setup()
}
else
ui->pictureLabel->hide();
}
QTextDocument doc;
doc.setHtml(notes()->text());