mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
fixed hide some options with old certificate format
This commit is contained in:
parent
b9a4cdcd50
commit
53d43324db
@ -78,6 +78,13 @@ HomePage::HomePage(QWidget *parent) :
|
|||||||
menu->addAction(RecAction);
|
menu->addAction(RecAction);
|
||||||
menu->addSeparator();
|
menu->addSeparator();
|
||||||
|
|
||||||
|
mUseOldFormatact = new QAction(QIcon(), tr("Use old certificate format"),this);
|
||||||
|
mUseOldFormatact->setToolTip(tr("Displays the certificate format used up to version 0.6.5\nOld Retroshare nodes will not understand the\nnew short format"));
|
||||||
|
connect(mUseOldFormatact, SIGNAL(triggered()), this, SLOT(switchCertificateFormat()));
|
||||||
|
mUseOldFormatact->setCheckable(true);
|
||||||
|
mUseOldFormatact->setChecked(false);
|
||||||
|
menu->addAction(mUseOldFormatact);
|
||||||
|
|
||||||
if(!RsAccounts::isHiddenNode())
|
if(!RsAccounts::isHiddenNode())
|
||||||
{
|
{
|
||||||
mIncludeLocIPact = new QAction(QIcon(), tr("Include current local IP"),this);
|
mIncludeLocIPact = new QAction(QIcon(), tr("Include current local IP"),this);
|
||||||
@ -105,13 +112,6 @@ HomePage::HomePage(QWidget *parent) :
|
|||||||
menu->addAction(mIncludeIPHistoryact);
|
menu->addAction(mIncludeIPHistoryact);
|
||||||
}
|
}
|
||||||
|
|
||||||
mUseOldFormatact = new QAction(QIcon(), tr("Use old certificate format"),this);
|
|
||||||
mUseOldFormatact->setToolTip(tr("Displays the certificate format used up to version 0.6.5\nOld Retroshare nodes will not understand the\nnew short format"));
|
|
||||||
connect(mUseOldFormatact, SIGNAL(triggered()), this, SLOT(updateOwnCert()));
|
|
||||||
mUseOldFormatact->setCheckable(true);
|
|
||||||
mUseOldFormatact->setChecked(false);
|
|
||||||
menu->addAction(mUseOldFormatact);
|
|
||||||
|
|
||||||
ui->shareButton->setMenu(menu);
|
ui->shareButton->setMenu(menu);
|
||||||
|
|
||||||
connect(ui->openwebhelp,SIGNAL(clicked()), this,SLOT(openWebHelp())) ;
|
connect(ui->openwebhelp,SIGNAL(clicked()), this,SLOT(openWebHelp())) ;
|
||||||
@ -164,6 +164,15 @@ void HomePage::handleEvent(std::shared_ptr<const RsEvent> e)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void HomePage::switchCertificateFormat()
|
||||||
|
{
|
||||||
|
whileBlocking(mIncludeDNSact)->setVisible(!mUseOldFormatact->isChecked());
|
||||||
|
whileBlocking(mIncludeLocIPact)->setVisible(!mUseOldFormatact->isChecked());
|
||||||
|
whileBlocking(mIncludeExtIPact)->setVisible(!mUseOldFormatact->isChecked());
|
||||||
|
|
||||||
|
updateOwnCert();
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef DEAD_CODE
|
#ifdef DEAD_CODE
|
||||||
void HomePage::certContextMenu(QPoint /*point*/)
|
void HomePage::certContextMenu(QPoint /*point*/)
|
||||||
{
|
{
|
||||||
@ -247,7 +256,7 @@ void HomePage::updateOwnCert()
|
|||||||
|
|
||||||
getOwnCert(certificate,description);
|
getOwnCert(certificate,description);
|
||||||
|
|
||||||
if(!mUseOldFormatact->isChecked()) // in this case we have to split the cert for a bettr display
|
if(!mUseOldFormatact->isChecked()) // in this case we have to split the cert for a better display
|
||||||
{
|
{
|
||||||
QString S;
|
QString S;
|
||||||
QString txt;
|
QString txt;
|
||||||
|
@ -63,6 +63,7 @@ private slots:
|
|||||||
void webMail();
|
void webMail();
|
||||||
void openWebHelp() ;
|
void openWebHelp() ;
|
||||||
void recommendFriends();
|
void recommendFriends();
|
||||||
|
void switchCertificateFormat();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Ui::HomePage *ui;
|
Ui::HomePage *ui;
|
||||||
|
Loading…
Reference in New Issue
Block a user