From 110df289791a1452565ef52e7ab5779e91d8481e Mon Sep 17 00:00:00 2001 From: defnax Date: Tue, 17 Feb 2015 21:31:14 +0000 Subject: [PATCH] Added tooltip on key id column. Hide Id Type column by default. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7953 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- retroshare-gui/src/gui/Identity/IdDialog.cpp | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/retroshare-gui/src/gui/Identity/IdDialog.cpp b/retroshare-gui/src/gui/Identity/IdDialog.cpp index 787a5826b..8fa7245bd 100644 --- a/retroshare-gui/src/gui/Identity/IdDialog.cpp +++ b/retroshare-gui/src/gui/Identity/IdDialog.cpp @@ -190,12 +190,14 @@ IdDialog::IdDialog(QWidget *parent) : hideTypeAct= new QAction(headerItem->text(RSID_COL_IDTYPE),this); hideTypeAct->setCheckable(true); hideTypeAct->setToolTip(tr("Show ")+hideTypeAct->text()+tr(" Column")); connect(hideTypeAct,SIGNAL(triggered(bool)),this,SLOT(setHideIdTypeColumn(bool))) ; - + mIdQueue = new TokenQueue(rsIdentity->getTokenService(), this); mStateHelper->setActive(IDDIALOG_IDDETAILS, false); mStateHelper->setActive(IDDIALOG_REPLIST, false); + ui->treeWidget_IdList->setColumnHidden(RSID_COL_IDTYPE, true); + // Hiding RepList until that part is finished. //ui->treeWidget_RepList->setVisible(false); ui->toolButton_Reputation->setVisible(false); @@ -410,6 +412,8 @@ bool IdDialog::fillIdListItem(const RsGxsIdGroup& data, QTreeWidgetItem *&item, item->setIcon(RSID_COL_NICKNAME, QIcon(pixmap)); + QString tooltip; + if (data.mMeta.mGroupFlags & RSGXSID_GROUPFLAG_REALID) { if (data.mPgpKnown) @@ -418,11 +422,18 @@ bool IdDialog::fillIdListItem(const RsGxsIdGroup& data, QTreeWidgetItem *&item, rsPeers->getGPGDetails(data.mPgpId, details); item->setText(RSID_COL_IDTYPE, QString::fromUtf8(details.name.c_str())); item->setToolTip(RSID_COL_IDTYPE,QString::fromStdString(data.mPgpId.toStdString())) ; + + + tooltip += tr("Node name: ") + QString::fromUtf8(details.name.c_str()) + "\n"; + tooltip += tr("Node Id : ") + QString::fromStdString(data.mPgpId.toStdString()) ; + item->setToolTip(RSID_COL_KEYID,tooltip) ; } else { item->setText(RSID_COL_IDTYPE, tr("Unknown PGP key")); item->setToolTip(RSID_COL_IDTYPE,tr("Unknown key ID")) ; + item->setToolTip(RSID_COL_KEYID,tr("Unknown key ID")) ; + } } else @@ -679,7 +690,7 @@ void IdDialog::insertIdDetails(uint32_t token) ui->editIdentity->setEnabled(false); ui->removeIdentity->setEnabled(false); ui->chatIdentity->setEnabled(true); - ui->messageButton->setEnabled(true); + ui->messageButton->setEnabled(true); } /* now fill in the reputation information */