added code for showing author on people tab

This commit is contained in:
csoler 2020-09-13 21:16:03 +02:00
parent a6a3bd3f0f
commit 395435b5f3
2 changed files with 21 additions and 0 deletions

View File

@ -31,6 +31,8 @@
#include "gui/common/FilesDefs.h"
#include "util/qtthreadsutils.h"
#include "util/HandleRichText.h"
#include "gui/Identity/IdDialog.h"
#include "gui/MainWindow.h"
#include "ui_BoardPostDisplayWidget.h"
@ -432,3 +434,21 @@ void BoardPostDisplayWidget::loadComments(bool e)
{
emit commentsRequested(mPost.mMeta.mMsgId,e);
}
void BoardPostDisplayWidget::showAuthorInPeople()
{
if(mPost.mMeta.mAuthorId.isNull())
{
std::cerr << "(EE) GxsForumThreadWidget::loadMsgData_showAuthorInPeople() ERROR Missing Message Data...";
std::cerr << std::endl;
}
/* window will destroy itself! */
IdDialog *idDialog = dynamic_cast<IdDialog*>(MainWindow::getPage(MainWindow::People));
if (!idDialog)
return ;
MainWindow::showWindow(MainWindow::People);
idDialog->navigate(RsGxsId(mPost.mMeta.mAuthorId));
}

View File

@ -71,6 +71,7 @@ protected slots:
void makeUpVote() ;
void makeDownVote() ;
void toggleNotes() ;
void showAuthorInPeople();
signals:
void vote(const RsGxsGrpMsgIdPair& msgId, bool up_or_down);