gui: chat: hide untouchable context menu actions for own identity

This commit is contained in:
chelovechishko 2022-04-02 23:12:14 +09:00
parent 47fc1902af
commit 62ad412914

View File

@ -319,6 +319,16 @@ void ChatLobbyDialog::initParticipantsContextMenu(QMenu *contextMnu, QList<RsGxs
if (!gxsid.isNull())
copyIdAct->setData(QString::fromStdString(gxsid.toStdString()));
if (!gxsid.isNull() && rsIdentity->isOwnId(gxsid))
{
distantChatAct->setVisible(false);
sendMessageAct->setVisible(false);
muteAct->setVisible(false);
votePositiveAct->setVisible(false);
voteNeutralAct->setVisible(false);
voteNegativeAct->setVisible(false);
}
if(!gxsid.isNull() && !rsIdentity->isOwnId(gxsid))
{
distantChatAct->setEnabled(true);