Fixed to hide unwanted labels and buttons on a ssl request

This commit is contained in:
defnax 2021-02-20 16:14:27 +01:00
parent b461d3c782
commit 9d4bc677bb
3 changed files with 18 additions and 6 deletions

View File

@ -138,6 +138,7 @@ void SecurityItem::updateItemStatic()
title = tr("Missing/Damaged certificate. Not a real Retroshare user.");
requestLabel->hide();
}
avatar->setDefaultAvatar(":icons/ssl.png");
break;
case RS_FEED_ITEM_SEC_INTERNAL_ERROR:
title = tr("Certificate caused an internal error.");
@ -186,7 +187,7 @@ void SecurityItem::updateItem()
*/
/* set peer name */
peerNameLabel->setText(tr("A unknown peer"));
//peerNameLabel->setText(tr("A unknown peer"));
nameLabel->setText(tr("Unknown") + " (" + tr("Profile ID: ") + QString::fromStdString(mGpgId.toStdString()) + ")");
idLabel->setText(QString::fromStdString(mSslId.toStdString()));
@ -205,15 +206,25 @@ void SecurityItem::updateItem()
connLeftLabel->hide();
chatButton->hide();
//quickmsgButton->hide();
requestLabel->hide();
removeFriendButton->setEnabled(false);
removeFriendButton->hide();
peerDetailsButton->setEnabled(false);
if(mType == RS_FEED_ITEM_SEC_BAD_CERTIFICATE)
{
peerNameLabel->setText(tr("SSL request"));
friendRequesttoolButton->hide();
requestLabel->hide();
peerDetailsButton->hide;
}
else
{
peerNameLabel->setText(tr("A unknown peer"));
friendRequesttoolButton->show();
requestLabel->show();
peerDetailsButton->show();
}
return;
}

View File

@ -63,6 +63,7 @@
<file>icons/logo_2_connected_128.png</file>
<file>icons/outlook.png</file>
<file>icons/question.png</file>
<file>icons/ssl.png</file>
<file>icons/plugins_128.png</file>
<file>icons/png/add.png</file>
<file>icons/png/add-identity.png</file>

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB