diff --git a/retroshare-gui/src/gui/AboutWidget.cpp b/retroshare-gui/src/gui/AboutWidget.cpp index b97fb6f9e..d19e4a7bc 100644 --- a/retroshare-gui/src/gui/AboutWidget.cpp +++ b/retroshare-gui/src/gui/AboutWidget.cpp @@ -60,8 +60,8 @@ AboutWidget::AboutWidget(QWidget* parent) updateTitle(); - QObject::connect(help_button,SIGNAL(clicked()),this,SLOT(on_help_button_clicked())); - QObject::connect(copy_button,SIGNAL(clicked()),this,SLOT(on_copy_button_clicked())); + //QObject::connect(help_button,SIGNAL(clicked()),this,SLOT(on_help_button_clicked())); + //QObject::connect(copy_button,SIGNAL(clicked()),this,SLOT(on_copy_button_clicked())); } void AboutWidget::installAWidget() { @@ -226,6 +226,9 @@ void AWidget::initImages() /* Draw RetroShare version */ p.drawText(QPointF(10, 50), QString("%1 : %2").arg(tr("Retroshare version"), Rshare::retroshareVersion(true))); +#ifdef RS_ONLYHIDDENNODE + p.drawText(QPointF(10, 70), QString("Only Hidden Node")); +#endif /* Draw Qt's version number */ p.drawText(QPointF(10, 90), QString("Qt %1 : %2").arg(tr("version"), QT_VERSION_STR)); @@ -938,6 +941,9 @@ void AboutWidget::on_copy_button_clicked() QString rsVerString = "RetroShare Version: "; rsVerString+=Rshare::retroshareVersion(true); verInfo+=rsVerString; +#ifdef RS_ONLYHIDDENNODE + verInfo+=" " + tr("Only Hidden Node"); +#endif verInfo+="\n"; diff --git a/retroshare-gui/src/gui/GenCertDialog.cpp b/retroshare-gui/src/gui/GenCertDialog.cpp index bf7e64b18..869f42195 100644 --- a/retroshare-gui/src/gui/GenCertDialog.cpp +++ b/retroshare-gui/src/gui/GenCertDialog.cpp @@ -144,7 +144,7 @@ GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent) connect(ui.exportIdentity_PB, SIGNAL(clicked()), this, SLOT(exportIdentity())); connect(ui.password_input, SIGNAL(textChanged(QString)), this, SLOT(updateCheckLabels())); - connect(ui.password_input_2, SIGNAL(textChanged(QString)), this, SLOT(updateCheckLabels())); + connect(ui.password2_input, SIGNAL(textChanged(QString)), this, SLOT(updateCheckLabels())); connect(ui.name_input, SIGNAL(textChanged(QString)), this, SLOT(updateCheckLabels())); connect(ui.node_input, SIGNAL(textChanged(QString)), this, SLOT(updateCheckLabels())); connect(ui.reuse_existing_node_CB, SIGNAL(toggled(bool)), this, SLOT(updateCheckLabels())); @@ -172,7 +172,7 @@ GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent) ui.name_input->setPlaceholderText(tr("Username")); ui.nickname_input->setPlaceholderText(tr("Chat name")); ui.password_input->setPlaceholderText(tr("Password")); - ui.password_input_2->setPlaceholderText(tr("Password again")); + ui.password2_input->setPlaceholderText(tr("Password again")); #endif ui.nickname_input->setMaxLength(RSID_MAXIMUM_NICKNAME_SIZE); @@ -189,6 +189,13 @@ GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent) mAllFieldsOk = false ; mEntropyOk = false ; +#ifdef RS_ONLYHIDDENNODE + ui.adv_checkbox->setChecked(true); + ui.adv_checkbox->setVisible(false); + ui.nodeType_CB->setCurrentIndex(1); + ui.nodeType_CB->setEnabled(false); +#endif + initKeyList(); setupState(); updateCheckLabels(); @@ -292,8 +299,8 @@ void GenCertDialog::setupState() ui.password_label->setVisible(true); ui.password2_check_LB->setVisible(generate_new); - ui.password_input_2->setVisible(generate_new); - ui.password_label_2->setVisible(generate_new); + ui.password2_input->setVisible(generate_new); + ui.password2_label->setVisible(generate_new); ui.keylength_label->setVisible(adv_state); ui.keylength_comboBox->setVisible(adv_state); @@ -385,7 +392,7 @@ void GenCertDialog::updateCheckLabels() mAllFieldsOk = false ; ui.password_check_LB ->setPixmap(bad) ; } - if(ui.password_input->text().length() >= 3 && ui.password_input->text() == ui.password_input_2->text()) + if(ui.password_input->text().length() >= 3 && ui.password_input->text() == ui.password2_input->text()) ui.password2_check_LB ->setPixmap(good) ; else { @@ -533,7 +540,7 @@ void GenCertDialog::genPerson() return; } - if(ui.password_input->text() != ui.password_input_2->text()) + if(ui.password_input->text() != ui.password2_input->text()) { QMessageBox::warning(this, tr("PGP key pair generation failure"), @@ -550,8 +557,8 @@ void GenCertDialog::genPerson() ui.name_input->hide(); ui.nickname_label->hide(); ui.nickname_input->hide(); - ui.password_label_2->hide(); - ui.password_input_2->hide(); + ui.password2_label->hide(); + ui.password2_input->hide(); ui.password2_check_LB->hide(); ui.password_check_LB->hide(); ui.password_label->hide(); diff --git a/retroshare-gui/src/gui/GenCertDialog.ui b/retroshare-gui/src/gui/GenCertDialog.ui index d466675d2..28ce3bd88 100644 --- a/retroshare-gui/src/gui/GenCertDialog.ui +++ b/retroshare-gui/src/gui/GenCertDialog.ui @@ -50,12 +50,12 @@ QFrame::Raised - + 9 - + @@ -115,7 +115,7 @@ - + 24 @@ -176,7 +176,7 @@ - + 0 @@ -283,7 +283,7 @@ - + @@ -604,7 +604,7 @@ - + 24 @@ -713,7 +713,7 @@ - + Qt::Vertical @@ -750,7 +750,7 @@ name_input node_input password_input - password_input_2 + password2_input keylength_comboBox exportIdentity_PB genPGPuser diff --git a/retroshare-gui/src/gui/qss/stylesheet/Standard.qss b/retroshare-gui/src/gui/qss/stylesheet/Standard.qss index 670577b1e..7d518d4c2 100644 --- a/retroshare-gui/src/gui/qss/stylesheet/Standard.qss +++ b/retroshare-gui/src/gui/qss/stylesheet/Standard.qss @@ -697,7 +697,7 @@ GenCertDialog QLineEdit#hiddenaddr_input { background: white; font: bold; } -GenCertDialog QLineEdit#password_input_2 { +GenCertDialog QLineEdit#password2_input { border: 2px solid #0099cc; border-radius: 6px; background: white; diff --git a/retroshare.pri b/retroshare.pri index c3d54a263..7f827542f 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -56,6 +56,11 @@ no_sqlcipher:CONFIG -= sqlcipher CONFIG *= no_rs_autologin rs_autologin:CONFIG -= no_rs_autologin +# To have only hidden node generation append the following assignation +# to qmake command line "CONFIG+=rs_onlyhiddennode" +CONFIG *= no_rs_onlyhiddennode +rs_onlyhiddennode:CONFIG -= no_rs_onlyhiddennode + # To disable GXS (General eXchange System) append the following # assignation to qmake command line "CONFIG+=no_rs_gxs" CONFIG *= rs_gxs @@ -223,6 +228,11 @@ rs_autologin { warning("You have enabled RetroShare auto-login, this is discouraged. The usage of auto-login on some linux distributions may allow someone having access to your session to steal the SSL keys of your node location and therefore compromise your security") } +rs_onlyhiddennode { + DEFINES *= RS_ONLYHIDDENNODE + warning("QMAKE: You have enabled only hidden node.") +} + no_rs_deprecatedwarning { QMAKE_CXXFLAGS += -Wno-deprecated QMAKE_CXXFLAGS += -Wno-deprecated-declarations