mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-03 11:00:14 -05:00
Add possibility to create GXSId directly on GenCertDialog.
This commit is contained in:
parent
6db747a263
commit
6edd7bb8e3
@ -62,6 +62,7 @@ extern RsIdentity *rsIdentity;
|
||||
|
||||
// Unicode symbols. NOT utf-8 bytes, because of multi byte characters
|
||||
#define RSID_MAXIMUM_NICKNAME_SIZE 30
|
||||
#define RSID_MINIMUM_NICKNAME_SIZE 2
|
||||
|
||||
std::string rsIdTypeToString(uint32_t idtype);
|
||||
|
||||
|
@ -19,21 +19,26 @@
|
||||
* Boston, MA 02110-1301, USA.
|
||||
****************************************************************/
|
||||
|
||||
#include <rshare.h>
|
||||
#include <util/rsrandom.h>
|
||||
#include <retroshare/rsinit.h>
|
||||
#include <rsserver/rsaccounts.h>
|
||||
#include "gui/settings/rsharesettings.h"
|
||||
#include "util/misc.h"
|
||||
#include "GenCertDialog.h"
|
||||
|
||||
#include <QAbstractEventDispatcher>
|
||||
#include <QFileDialog>
|
||||
#include <QGraphicsOpacityEffect>
|
||||
#include <QTimer>
|
||||
#include <QMessageBox>
|
||||
#include <QMouseEvent>
|
||||
#include <QTextBrowser>
|
||||
#include <QTimer>
|
||||
#include <QProgressBar>
|
||||
|
||||
#include <rshare.h>
|
||||
#include "gui/settings/rsharesettings.h"
|
||||
#include "util/misc.h"
|
||||
|
||||
#include <retroshare/rsidentity.h>
|
||||
#include <retroshare/rsinit.h>
|
||||
#include <rsserver/rsaccounts.h>
|
||||
#include <util/rsrandom.h>
|
||||
|
||||
#include <time.h>
|
||||
#include <math.h>
|
||||
#include <iostream>
|
||||
@ -99,18 +104,18 @@ void GenCertDialog::grabMouse()
|
||||
|
||||
ui.entropy_bar->setValue(count*100/2048) ;
|
||||
|
||||
if(ui.entropy_bar->value() < 20)
|
||||
{
|
||||
ui.genButton2->setEnabled(false) ;
|
||||
ui.genButton2->setIcon(QIcon(":/images/delete.png")) ;
|
||||
ui.genButton2->setToolTip(tr("Currently disabled. Please move your mouse around until you reach at least 20%")) ;
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.genButton2->setEnabled(true) ;
|
||||
ui.genButton2->setIcon(QIcon(":/images/resume.png")) ;
|
||||
ui.genButton2->setToolTip(tr("Click to create your node and/or profile")) ;
|
||||
}
|
||||
if(ui.entropy_bar->value() < 20)
|
||||
{
|
||||
ui.genButton->setEnabled(false) ;
|
||||
ui.genButton->setIcon(QIcon(":/images/delete.png")) ;
|
||||
ui.genButton->setToolTip(tr("Currently disabled. Please move your mouse around until you reach at least 20%")) ;
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.genButton->setEnabled(true) ;
|
||||
ui.genButton->setIcon(QIcon(":/images/resume.png")) ;
|
||||
ui.genButton->setToolTip(tr("Click to create your node and/or profile")) ;
|
||||
}
|
||||
|
||||
RsInit::collectEntropy(E+(F << 16)) ;
|
||||
}
|
||||
@ -121,7 +126,9 @@ void GenCertDialog::grabMouse()
|
||||
//}
|
||||
/** Default constructor */
|
||||
GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent)
|
||||
: QDialog(parent, Qt::WindowSystemMenuHint | Qt::WindowTitleHint | Qt::WindowCloseButtonHint), mOnlyGenerateIdentity(onlyGenerateIdentity)
|
||||
: QDialog(parent, Qt::WindowSystemMenuHint | Qt::WindowTitleHint | Qt::WindowCloseButtonHint)
|
||||
, mOnlyGenerateIdentity(onlyGenerateIdentity)
|
||||
, mGXSNickname("")
|
||||
{
|
||||
/* Invoke Qt Designer generated QObject setup routine */
|
||||
ui.setupUi(this);
|
||||
@ -130,10 +137,10 @@ GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent)
|
||||
ui.headerFrame->setHeaderText(tr("Create a new profile"));
|
||||
|
||||
connect(ui.new_gpg_key_checkbox, SIGNAL(clicked()), this, SLOT(newGPGKeyGenUiSetup()));
|
||||
connect(ui.adv_checkbox, SIGNAL(clicked()), this, SLOT(updateUiSetup()));
|
||||
connect(ui.hidden_checkbox, SIGNAL(clicked()), this, SLOT(updateUiSetup()));
|
||||
connect(ui.adv_checkbox, SIGNAL(clicked()), this, SLOT(updateUiSetup()));
|
||||
connect(ui.hidden_checkbox, SIGNAL(clicked()), this, SLOT(updateUiSetup()));
|
||||
|
||||
connect(ui.genButton2, SIGNAL(clicked()), this, SLOT(genPerson()));
|
||||
connect(ui.genButton, SIGNAL(clicked()), this, SLOT(genPerson()));
|
||||
connect(ui.importIdentity_PB, SIGNAL(clicked()), this, SLOT(importIdentity()));
|
||||
connect(ui.exportIdentity_PB, SIGNAL(clicked()), this, SLOT(exportIdentity()));
|
||||
|
||||
@ -162,17 +169,20 @@ GenCertDialog::GenCertDialog(bool onlyGenerateIdentity, QWidget *parent)
|
||||
// make sure that QVariant always takes an 'int' otherwise the program will crash!
|
||||
ui.keylength_comboBox->addItem("default (2048 bits, recommended)", QVariant(2048));
|
||||
ui.keylength_comboBox->addItem("high (3072 bits)", QVariant(3072));
|
||||
ui.keylength_comboBox->addItem("insane (4096 bits)", QVariant(4096));
|
||||
ui.keylength_comboBox->addItem("insane (4096 bits)", QVariant(4096));
|
||||
|
||||
#if QT_VERSION >= 0x040700
|
||||
ui.email_input->setPlaceholderText(tr("[Optional] Visible to your friends, and friends of friends.")) ;
|
||||
ui.node_input->setPlaceholderText(tr("[Required] Examples: Home, Laptop,...")) ;
|
||||
ui.hiddenaddr_input->setPlaceholderText(tr("[Required] Tor/I2P address - Examples: xa76giaf6ifda7ri63i263.onion (obtained by you from Tor)")) ;
|
||||
ui.name_input->setPlaceholderText(tr("[Required] Visible to your friends, and friends of friends."));
|
||||
ui.nickname_input->setPlaceholderText(tr("[Optional] Used when you write in chat lobbies, forums and channel comments."));
|
||||
ui.password_input->setPlaceholderText(tr("[Required] This password protects your private PGP key."));
|
||||
ui.password_input_2->setPlaceholderText(tr("[Required] Type the same password again here."));
|
||||
#endif
|
||||
|
||||
ui.nickname_input->setMaxLength(RSID_MAXIMUM_NICKNAME_SIZE);
|
||||
|
||||
ui.node_input->setToolTip(tr("Enter a meaningful node description. e.g. : home, laptop, etc. \nThis field will be used to differentiate different installations with\nthe same profile (PGP key pair).")) ;
|
||||
|
||||
ui.email_input->hide() ;
|
||||
@ -223,7 +233,7 @@ void GenCertDialog::init()
|
||||
ui.header_label->show();
|
||||
ui.new_gpg_key_checkbox->setChecked(false);
|
||||
setWindowTitle(tr("Create new node"));
|
||||
ui.genButton2->setText(tr("Generate new node"));
|
||||
ui.genButton->setText(tr("Generate new node"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new node"));
|
||||
genNewGPGKey = false;
|
||||
} else {
|
||||
@ -232,7 +242,7 @@ void GenCertDialog::init()
|
||||
ui.new_gpg_key_checkbox->setChecked(true);
|
||||
ui.new_gpg_key_checkbox->setEnabled(true);
|
||||
setWindowTitle(tr("Create new profile"));
|
||||
ui.genButton2->setText(tr("Generate new profile and node"));
|
||||
ui.genButton->setText(tr("Generate new profile and node"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new profile and node"));
|
||||
genNewGPGKey = true;
|
||||
}
|
||||
@ -271,35 +281,45 @@ void GenCertDialog::newGPGKeyGenUiSetup() {
|
||||
|
||||
if (ui.new_gpg_key_checkbox->isChecked()) {
|
||||
genNewGPGKey = true;
|
||||
setWindowTitle(tr("Create new profile"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new profile and node"));
|
||||
if (!mOnlyGenerateIdentity) {
|
||||
ui.header_label->setVisible(haveGPGKeys);
|
||||
}
|
||||
ui.genprofileinfo_label->setVisible(false);
|
||||
ui.no_gpg_key_label->setText(tr("Welcome to Retroshare. Before you can proceed you need to create a profile and associate a node with it. To do so please fill out this form.\nAlternatively you can import a (previously exported) profile. Just uncheck \"Create a new profile\""));
|
||||
|
||||
ui.importIdentity_PB->hide() ;
|
||||
ui.exportIdentity_PB->hide();
|
||||
ui.adv_checkbox->setVisible(true);
|
||||
|
||||
ui.genPGPuserlabel->hide();
|
||||
ui.genPGPuser->hide();
|
||||
ui.name_label->show();
|
||||
ui.name_input->show();
|
||||
ui.nickname_label->setVisible(!mOnlyGenerateIdentity);
|
||||
ui.nickname_input->setVisible(!mOnlyGenerateIdentity);
|
||||
ui.node_label->setVisible(true);
|
||||
ui.node_input->setVisible(true);
|
||||
// ui.email_label->show();
|
||||
// ui.email_input->show();
|
||||
ui.password_label->show();
|
||||
ui.password_label_2->show();
|
||||
ui.password_input->show();
|
||||
ui.password_input_2->show();
|
||||
ui.genPGPuserlabel->hide();
|
||||
ui.genPGPuser->hide();
|
||||
ui.importIdentity_PB->hide() ;
|
||||
ui.exportIdentity_PB->hide();
|
||||
setWindowTitle(tr("Create new profile"));
|
||||
ui.genButton2->setText(tr("Generate new profile and node"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new profile and node"));
|
||||
ui.no_gpg_key_label->setText(tr("Welcome to Retroshare. Before you can proceed you need to create a profile and associate a node with it. To do so please fill out this form.\nAlternatively you can import a (previously exported) profile. Just uncheck \"Create a new profile\""));
|
||||
ui.genButton2->setVisible(true);
|
||||
ui.adv_checkbox->setVisible(true);
|
||||
ui.node_label->setVisible(true);
|
||||
ui.node_input->setVisible(true);
|
||||
ui.entropy_label->setVisible(true);
|
||||
ui.entropy_bar->setVisible(true);
|
||||
ui.genprofileinfo_label->setVisible(false);
|
||||
if (!mOnlyGenerateIdentity) {
|
||||
ui.header_label->setVisible(haveGPGKeys);
|
||||
}
|
||||
//ui.keylength_label->show();
|
||||
//ui.keylength_comboBox->show();
|
||||
|
||||
ui.entropy_label->setVisible(true);
|
||||
ui.entropy_bar->setVisible(true);
|
||||
|
||||
ui.genButton->setVisible(true);
|
||||
ui.genButton->setText(tr("Generate new profile and node"));
|
||||
} else {
|
||||
genNewGPGKey = false;
|
||||
setWindowTitle(tr("Create new node"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new node"));
|
||||
ui.header_label->setVisible(false);
|
||||
//haveGPGKeys = (ui.genPGPuser->count() != 0)?true:false;
|
||||
if (haveGPGKeys) {
|
||||
QVariant data = ui.genPGPuser->itemData(ui.genPGPuser->currentIndex());
|
||||
@ -310,37 +330,39 @@ void GenCertDialog::newGPGKeyGenUiSetup() {
|
||||
ui.genprofileinfo_label->show();
|
||||
}
|
||||
}
|
||||
genNewGPGKey = false;
|
||||
ui.name_label->hide();
|
||||
ui.name_input->hide();
|
||||
// ui.email_label->hide();
|
||||
// ui.email_input->hide();
|
||||
ui.password_label->hide();
|
||||
ui.password_label_2->hide();
|
||||
ui.password_input->hide();
|
||||
ui.password_input_2->hide();
|
||||
ui.genPGPuserlabel->show();
|
||||
ui.genPGPuser->show();
|
||||
//ui.genprofileinfo_label->show();
|
||||
ui.no_gpg_key_label->setText(tr("Welcome to Retroshare. Before you can proceed you need to import a profile and after that associate a node with it."));
|
||||
|
||||
ui.importIdentity_PB->setVisible(!mOnlyGenerateIdentity);
|
||||
ui.exportIdentity_PB->setVisible(haveGPGKeys);
|
||||
ui.exportIdentity_PB->setEnabled(haveGPGKeys);
|
||||
setWindowTitle(tr("Create new node"));
|
||||
ui.genButton2->setText(tr("Generate new node"));
|
||||
ui.headerFrame->setHeaderText(tr("Create a new node"));
|
||||
ui.no_gpg_key_label->setText(tr("Welcome to Retroshare. Before you can proceed you need to import a profile and after that associate a node with it."));
|
||||
ui.genButton2->setVisible(haveGPGKeys);
|
||||
ui.adv_checkbox->setVisible(haveGPGKeys);
|
||||
ui.adv_checkbox->setChecked(haveGPGKeys && adv_state);
|
||||
ui.genPGPuser->setVisible(haveGPGKeys);
|
||||
|
||||
//ui.genPGPuserlabel->show();
|
||||
//ui.genPGPuser->show();
|
||||
ui.genPGPuserlabel->setVisible(haveGPGKeys);
|
||||
ui.genPGPuser->setVisible(haveGPGKeys);
|
||||
ui.name_label->hide();
|
||||
ui.name_input->hide();
|
||||
ui.nickname_label->setVisible(!mOnlyGenerateIdentity && haveGPGKeys);
|
||||
ui.nickname_input->setVisible(!mOnlyGenerateIdentity && haveGPGKeys);
|
||||
ui.node_label->setVisible(haveGPGKeys);
|
||||
ui.node_input->setVisible(haveGPGKeys);
|
||||
ui.entropy_label->setVisible(haveGPGKeys);
|
||||
ui.entropy_bar->setVisible(haveGPGKeys);
|
||||
//ui.genprofileinfo_label->show();
|
||||
ui.header_label->setVisible(false);
|
||||
// ui.email_label->hide();
|
||||
// ui.email_input->hide();
|
||||
ui.password_label->hide();
|
||||
ui.password_input->hide();
|
||||
ui.password_label_2->hide();
|
||||
ui.password_input_2->hide();
|
||||
ui.keylength_label->hide();
|
||||
ui.keylength_comboBox->hide();
|
||||
|
||||
ui.entropy_label->setVisible(haveGPGKeys);
|
||||
ui.entropy_bar->setVisible(haveGPGKeys);
|
||||
|
||||
ui.genButton->setText(tr("Generate new node"));
|
||||
ui.genButton->setVisible(haveGPGKeys);
|
||||
}
|
||||
updateUiSetup();
|
||||
ui.adv_checkbox->setChecked(adv_state);
|
||||
@ -349,10 +371,10 @@ void GenCertDialog::newGPGKeyGenUiSetup() {
|
||||
|
||||
void GenCertDialog::updateUiSetup()
|
||||
{
|
||||
if (ui.adv_checkbox->isChecked())
|
||||
{
|
||||
ui.hidden_checkbox->show();
|
||||
|
||||
if (ui.adv_checkbox->isChecked())
|
||||
{
|
||||
ui.hidden_checkbox->show();
|
||||
|
||||
if (ui.new_gpg_key_checkbox->isChecked())
|
||||
{
|
||||
// key length is only for pgp key creation
|
||||
@ -364,39 +386,39 @@ void GenCertDialog::updateUiSetup()
|
||||
ui.keylength_label->hide();
|
||||
ui.keylength_comboBox->hide();
|
||||
}
|
||||
|
||||
if(ui.hidden_checkbox->isChecked())
|
||||
{
|
||||
ui.hiddenaddr_input->show();
|
||||
ui.hiddenaddr_label->show();
|
||||
ui.label_hiddenaddr2->show();
|
||||
ui.hiddenport_label->show();
|
||||
ui.hiddenport_spinBox->show();
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.hiddenaddr_input->hide();
|
||||
ui.hiddenaddr_label->hide();
|
||||
ui.label_hiddenaddr2->hide();
|
||||
ui.hiddenport_label->hide();
|
||||
ui.hiddenport_spinBox->hide();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.hiddenaddr_input->hide();
|
||||
ui.hiddenaddr_label->hide();
|
||||
ui.label_hiddenaddr2->hide();
|
||||
ui.hiddenport_label->hide();
|
||||
ui.hiddenport_spinBox->hide();
|
||||
|
||||
ui.hidden_checkbox->hide();
|
||||
ui.keylength_label->hide();
|
||||
ui.keylength_comboBox->hide();
|
||||
if(ui.hidden_checkbox->isChecked())
|
||||
{
|
||||
ui.hiddenaddr_input->show();
|
||||
ui.hiddenaddr_label->show();
|
||||
ui.label_hiddenaddr->show();
|
||||
ui.hiddenport_label->show();
|
||||
ui.hiddenport_spinBox->show();
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.hiddenaddr_input->hide();
|
||||
ui.hiddenaddr_label->hide();
|
||||
ui.label_hiddenaddr->hide();
|
||||
ui.hiddenport_label->hide();
|
||||
ui.hiddenport_spinBox->hide();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ui.hiddenaddr_input->hide();
|
||||
ui.hiddenaddr_label->hide();
|
||||
ui.label_hiddenaddr->hide();
|
||||
ui.hiddenport_label->hide();
|
||||
ui.hiddenport_spinBox->hide();
|
||||
|
||||
if(ui.hidden_checkbox->isChecked())
|
||||
ui.hidden_checkbox->setChecked(false) ;
|
||||
}
|
||||
ui.hidden_checkbox->hide();
|
||||
ui.keylength_label->hide();
|
||||
ui.keylength_comboBox->hide();
|
||||
|
||||
if(ui.hidden_checkbox->isChecked())
|
||||
ui.hidden_checkbox->setChecked(false) ;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -418,9 +440,9 @@ void GenCertDialog::exportIdentity()
|
||||
|
||||
void GenCertDialog::importIdentity()
|
||||
{
|
||||
QString fname ;
|
||||
if(!misc::getOpenFileName(this,RshareSettings::LASTDIR_CERT,tr("Import profile"), tr("RetroShare profile files (*.asc);;All files (*)"),fname))
|
||||
return ;
|
||||
QString fname ;
|
||||
if(!misc::getOpenFileName(this,RshareSettings::LASTDIR_CERT,tr("Import profile"), tr("RetroShare profile files (*.asc);;All files (*)"),fname))
|
||||
return ;
|
||||
|
||||
if(fname.isNull())
|
||||
return ;
|
||||
@ -453,7 +475,30 @@ void GenCertDialog::genPerson()
|
||||
RsPgpId PGPId;
|
||||
bool isHiddenLoc = false;
|
||||
|
||||
if (ui.hidden_checkbox->isChecked())
|
||||
mGXSNickname = ui.nickname_input->text();
|
||||
if (!mGXSNickname.isEmpty())
|
||||
{
|
||||
if (mGXSNickname.size() < RSID_MINIMUM_NICKNAME_SIZE)
|
||||
{
|
||||
std::cerr << "GenCertDialog::genPerson() GXS Nickname too short (min " << RSID_MINIMUM_NICKNAME_SIZE<< " chars)";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QMessageBox::warning(this, "", tr("The GXS nickname is too short. Please input at least %1 characters.").arg(RSID_MINIMUM_NICKNAME_SIZE), QMessageBox::Ok, QMessageBox::Ok);
|
||||
mGXSNickname = "";
|
||||
return;
|
||||
}
|
||||
if (mGXSNickname.size() > RSID_MAXIMUM_NICKNAME_SIZE)
|
||||
{
|
||||
std::cerr << "GenCertDialog::genPerson() GXS Nickname too long (max " << RSID_MAXIMUM_NICKNAME_SIZE<< " chars)";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QMessageBox::warning(this, "", tr("The GXS nickname is too long. Please reduce the length to %1 characters.").arg(RSID_MAXIMUM_NICKNAME_SIZE), QMessageBox::Ok, QMessageBox::Ok);
|
||||
mGXSNickname = "";
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (ui.hidden_checkbox->isChecked())
|
||||
{
|
||||
std::string hl = ui.hiddenaddr_input->text().toStdString();
|
||||
uint16_t port = ui.hiddenport_spinBox->value();
|
||||
@ -515,6 +560,8 @@ void GenCertDialog::genPerson()
|
||||
ui.new_gpg_key_checkbox->hide();
|
||||
ui.name_label->hide();
|
||||
ui.name_input->hide();
|
||||
ui.nickname_label->hide();
|
||||
ui.nickname_input->hide();
|
||||
// ui.email_label->hide();
|
||||
// ui.email_input->hide();
|
||||
ui.password_label_2->hide();
|
||||
@ -525,12 +572,12 @@ void GenCertDialog::genPerson()
|
||||
ui.genPGPuser->hide();
|
||||
ui.node_label->hide();
|
||||
ui.node_input->hide();
|
||||
ui.genButton2->hide();
|
||||
ui.genButton->hide();
|
||||
ui.importIdentity_PB->hide();
|
||||
ui.genprofileinfo_label->hide();
|
||||
ui.hidden_checkbox->hide();
|
||||
ui.adv_checkbox->hide();
|
||||
ui.keylength_label->hide();
|
||||
ui.hidden_checkbox->hide();
|
||||
ui.adv_checkbox->hide();
|
||||
ui.keylength_label->hide();
|
||||
ui.keylength_comboBox->hide();
|
||||
|
||||
setCursor(Qt::WaitCursor) ;
|
||||
@ -569,6 +616,7 @@ void GenCertDialog::genPerson()
|
||||
/* complete the process */
|
||||
RsInit::LoadPassword(sslPasswd);
|
||||
if (Rshare::loadCertificate(sslId, false)) {
|
||||
|
||||
accept();
|
||||
}
|
||||
}
|
||||
|
@ -36,6 +36,7 @@ public:
|
||||
|
||||
virtual ~GenCertDialog() ;
|
||||
virtual void mouseMoveEvent(QMouseEvent *e) ;
|
||||
QString getGXSNickname() {return mGXSNickname;}
|
||||
private slots:
|
||||
void genPerson();
|
||||
void importIdentity();
|
||||
@ -53,6 +54,7 @@ private:
|
||||
bool genNewGPGKey;
|
||||
bool haveGPGKeys;
|
||||
bool mOnlyGenerateIdentity;
|
||||
QString mGXSNickname;
|
||||
|
||||
QTimer *entropy_timer ;
|
||||
};
|
||||
|
@ -17,7 +17,7 @@
|
||||
<iconset resource="images.qrc">
|
||||
<normaloff>:/images/logo/logo_48.png</normaloff>:/images/logo/logo_48.png</iconset>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<layout class="QVBoxLayout" name="GenCertDialogVLayout">
|
||||
<item>
|
||||
<widget class="HeaderFrame" name="headerFrame">
|
||||
<property name="sizePolicy">
|
||||
@ -219,7 +219,7 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<layout class="QHBoxLayout" name="toolBarHLayout">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="new_gpg_key_checkbox">
|
||||
<property name="maximumSize">
|
||||
@ -305,7 +305,7 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<spacer name="toolBarHSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
@ -320,7 +320,7 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2" stretch="0,0">
|
||||
<layout class="QHBoxLayout" name="advOptionHLayout" stretch="0,0">
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
@ -338,7 +338,7 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<spacer name="hiddenNodeHSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
@ -353,107 +353,184 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="genPGPuserlabel">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Use profile</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="name_label">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="email_label">
|
||||
<property name="text">
|
||||
<string>Email</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="password_label">
|
||||
<property name="toolTip">
|
||||
<string>This password is for PGP</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Password</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="password_label_2">
|
||||
<property name="toolTip">
|
||||
<string>This password is for PGP</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Password (check)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="node_label">
|
||||
<property name="text">
|
||||
<string>Node</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="hiddenaddr_label">
|
||||
<property name="text">
|
||||
<string>hidden address</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<layout class="QGridLayout" name="profilGLayout">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="genPGPuserlabel">
|
||||
<property name="text">
|
||||
<string>Use profile</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="genPGPuser">
|
||||
<property name="toolTip">
|
||||
<string>Your profile is associated with a PGP key pair. RetroShare currently ignores DSA keys.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="name_label">
|
||||
<property name="text">
|
||||
<string>Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QLineEdit" name="name_input">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Enter your nickname here</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="nickname_label">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>You can have one or more identities. They are used when you write in chat lobbies, forums and channel comments. They act as the destination for distant chat and the Retroshare distant mail system.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>GXS Nickname</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QLineEdit" name="nickname_input">
|
||||
<property name="toolTip">
|
||||
<string>You can have one or more identities. They are used when you write in chat lobbies, forums and channel comments. They act as the destination for distant chat and the Retroshare distant mail system.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="email_label">
|
||||
<property name="text">
|
||||
<string>Email</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QLineEdit" name="email_input">
|
||||
<property name="toolTip">
|
||||
<string>Be careful: this email will be visible to your friends and friends
|
||||
of your friends. This information is required by PGP, but to stay
|
||||
anonymous, you can use a fake email.</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="password_label">
|
||||
<property name="toolTip">
|
||||
<string>This password is for PGP</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Password</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QLineEdit" name="password_input">
|
||||
<property name="toolTip">
|
||||
<string>Put a strong password here. This password protects your private PGP key.</string>
|
||||
</property>
|
||||
<property name="inputMask">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>1024</number>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Password</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="password_label_2">
|
||||
<property name="toolTip">
|
||||
<string>This password is for PGP</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Password (check)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QLineEdit" name="password_input_2">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Put a strong password here. This password protects your private PGP key.</string>
|
||||
</property>
|
||||
<property name="inputMask">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>1024</number>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Password</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QLabel" name="node_label">
|
||||
<property name="text">
|
||||
<string>Node</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="1">
|
||||
<widget class="QLineEdit" name="node_input">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<widget class="QLabel" name="hiddenaddr_label">
|
||||
<property name="text">
|
||||
<string>hidden address</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="1">
|
||||
<layout class="QHBoxLayout" name="hiddenInfoHLayout">
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QComboBox" name="genPGPuser">
|
||||
<property name="toolTip">
|
||||
<string>Your profile is associated with a PGP key pair. RetroShare currently ignores DSA keys.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="name_input">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<widget class="QLineEdit" name="hiddenaddr_input">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -466,171 +543,55 @@ Alternatively you can use an existing profile. Just uncheck "Create a new p
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Enter your nickname here</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="email_input">
|
||||
<property name="toolTip">
|
||||
<string>Be careful: this email will be visible to your friends and friends
|
||||
of your friends. This information is required by PGP, but to stay
|
||||
anonymous, you can use a fake email.</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="password_input">
|
||||
<property name="toolTip">
|
||||
<string>Put a strong password here. This password protects your private PGP key.</string>
|
||||
</property>
|
||||
<property name="inputMask">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>1024</number>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Password</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="password_input_2">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Put a strong password here. This password protects your private PGP key.</string>
|
||||
</property>
|
||||
<property name="inputMask">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>1024</number>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Password</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="node_input">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="hiddenaddr_input">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>64</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="hiddenport_label">
|
||||
<property name="text">
|
||||
<string>Port</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSpinBox" name="hiddenport_spinBox">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>This is your connection port.</p><p>Any value between 1024 and 65535 </p><p>should be ok. You can change it later.</p></body></html></string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>65535</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>7812</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_hiddenaddr2">
|
||||
<property name="text">
|
||||
<string><html><head/><body><p>This can be a Tor Onion address of the form: xa76giaf6ifda7ri63i263.onion <br/>or an I2P address in the form: [52 characters].b32.i2p </p><p>In order to get one, you must configure either Tor or I2P to create a new hidden service / server tunnel. If you do not yet have one, you can still go on, and make it right later in RetroShare's Options-&gt;Network-&gt;Hidden Service configuration panel.</p></body></html></string>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_1">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_1">
|
||||
<item>
|
||||
<widget class="QLabel" name="keylength_label">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>120</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<widget class="QLabel" name="hiddenport_label">
|
||||
<property name="text">
|
||||
<string>PGP key length</string>
|
||||
<string>Port</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSpinBox" name="hiddenport_spinBox">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>This is your connection port.</p><p>Any value between 1024 and 65535 </p><p>should be ok. You can change it later.</p></body></html></string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>65535</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>7812</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<widget class="QComboBox" name="keylength_comboBox"/>
|
||||
</item>
|
||||
</layout>
|
||||
<item row="8" column="0" colspan="2">
|
||||
<widget class="QLabel" name="label_hiddenaddr">
|
||||
<property name="text">
|
||||
<string><html><head/><body><p>This can be a Tor Onion address of the form: xa76giaf6ifda7ri63i263.onion <br/>or an I2P address in the form: [52 characters].b32.i2p </p><p>In order to get one, you must configure either Tor or I2P to create a new hidden service / server tunnel. If you do not yet have one, you can still go on, and make it right later in RetroShare's Options-&gt;Network-&gt;Hidden Service configuration panel.</p></body></html></string>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="0">
|
||||
<widget class="QLabel" name="keylength_label">
|
||||
<property name="text">
|
||||
<string>PGP key length</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="1">
|
||||
<widget class="QComboBox" name="keylength_comboBox"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
@ -722,7 +683,7 @@ anonymous, you can use a fake email.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="genButton2">
|
||||
<widget class="QPushButton" name="genButton">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
@ -748,7 +709,7 @@ anonymous, you can use a fake email.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<spacer name="mainVSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
@ -761,16 +722,6 @@ anonymous, you can use a fake email.</string>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
<zorder>no_node_label</zorder>
|
||||
<zorder>genButton2</zorder>
|
||||
<zorder>header_label</zorder>
|
||||
<zorder>genprofileinfo_label</zorder>
|
||||
<zorder>entropy_bar</zorder>
|
||||
<zorder>entropy_label</zorder>
|
||||
<zorder>headerFrame</zorder>
|
||||
<zorder>no_gpg_key_label</zorder>
|
||||
<zorder>verticalSpacer</zorder>
|
||||
<zorder>label_hiddenaddr2</zorder>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
<customwidget>
|
||||
@ -785,6 +736,23 @@ anonymous, you can use a fake email.</string>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<tabstops>
|
||||
<tabstop>new_gpg_key_checkbox</tabstop>
|
||||
<tabstop>importIdentity_PB</tabstop>
|
||||
<tabstop>exportIdentity_PB</tabstop>
|
||||
<tabstop>adv_checkbox</tabstop>
|
||||
<tabstop>hidden_checkbox</tabstop>
|
||||
<tabstop>genPGPuser</tabstop>
|
||||
<tabstop>name_input</tabstop>
|
||||
<tabstop>nickname_input</tabstop>
|
||||
<tabstop>email_input</tabstop>
|
||||
<tabstop>password_input</tabstop>
|
||||
<tabstop>password_input_2</tabstop>
|
||||
<tabstop>node_input</tabstop>
|
||||
<tabstop>hiddenaddr_input</tabstop>
|
||||
<tabstop>hiddenport_spinBox</tabstop>
|
||||
<tabstop>genButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="images.qrc"/>
|
||||
</resources>
|
||||
|
@ -505,17 +505,17 @@ void IdEditDialog::createId()
|
||||
{
|
||||
QString groupname = ui->lineEdit_Nickname->text();
|
||||
|
||||
if (groupname.size() < 2)
|
||||
if (groupname.size() < RSID_MINIMUM_NICKNAME_SIZE)
|
||||
{
|
||||
std::cerr << "IdEditDialog::createId() Nickname too short";
|
||||
std::cerr << "IdEditDialog::createId() Nickname too short (min " << RSID_MINIMUM_NICKNAME_SIZE << " chars)";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QMessageBox::warning(this, "", tr("The nickname is too short. Please input at least %1 characters.").arg(2), QMessageBox::Ok, QMessageBox::Ok);
|
||||
QMessageBox::warning(this, "", tr("The nickname is too short. Please input at least %1 characters.").arg(RSID_MINIMUM_NICKNAME_SIZE), QMessageBox::Ok, QMessageBox::Ok);
|
||||
return;
|
||||
}
|
||||
if (groupname.size() > RSID_MAXIMUM_NICKNAME_SIZE)
|
||||
{
|
||||
std::cerr << "IdEditDialog::createId() Nickname too long (max " << RSID_MAXIMUM_NICKNAME_SIZE<< " chars)";
|
||||
std::cerr << "IdEditDialog::createId() Nickname too long (max " << RSID_MAXIMUM_NICKNAME_SIZE << " chars)";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QMessageBox::warning(this, "", tr("The nickname is too long. Please reduce the length to %1 characters.").arg(RSID_MAXIMUM_NICKNAME_SIZE), QMessageBox::Ok, QMessageBox::Ok);
|
||||
|
@ -28,7 +28,7 @@ GenCertDialog QLabel#genprofileinfo_label, QLabel#header_label, QLabel#entropy_l
|
||||
background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 #FFFFD7, stop:1 #FFFFB2);
|
||||
}
|
||||
|
||||
GenCertDialog QLabel#label_hiddenaddr2 {
|
||||
GenCertDialog QLabel#label_hiddenaddr {
|
||||
border: 1px solid #50FF5B;
|
||||
border-radius: 6px;
|
||||
background: #CCFFCC;
|
||||
@ -52,19 +52,6 @@ GenCertDialog > QFrame#frame {
|
||||
border: 1px solid #CCCCCC;
|
||||
}
|
||||
|
||||
GenCertDialog QPushButton#genButton {
|
||||
border-image: url(:/images/btn_blue.png) 4;
|
||||
border-width: 4;
|
||||
padding: 0px 6px;
|
||||
font-size: 14px;
|
||||
font: bold;
|
||||
color: white;
|
||||
}
|
||||
|
||||
GenCertDialog QPushButton#genButton:hover {
|
||||
border-image: url(:/images/btn_blue_hover.png) 4;
|
||||
}
|
||||
|
||||
/* ConnectFriendWizard */
|
||||
|
||||
ConnectFriendWizard {
|
||||
|
@ -22,29 +22,32 @@
|
||||
#include <QObject>
|
||||
#include <QMessageBox>
|
||||
#include <QSplashScreen>
|
||||
|
||||
#include <rshare.h>
|
||||
#include "gui/MainWindow.h"
|
||||
#include "gui/FriendsDialog.h"
|
||||
#include "gui/GenCertDialog.h"
|
||||
#include "gui/MainWindow.h"
|
||||
#include "gui/MessengerWindow.h"
|
||||
#include "gui/NetworkDialog.h"
|
||||
#include "gui/NetworkView.h"
|
||||
#include "gui/QuickStartWizard.h"
|
||||
#include "gui/RetroShareLink.h"
|
||||
#include "gui/SharedFilesDialog.h"
|
||||
#include "gui/SoundManager.h"
|
||||
#include "gui/StartDialog.h"
|
||||
#include "gui/chat/ChatDialog.h"
|
||||
#include "gui/connect/ConfCertDialog.h"
|
||||
#include "gui/common/Emoticons.h"
|
||||
#include "gui/FileTransfer/SearchDialog.h"
|
||||
#include "gui/FileTransfer/TransfersDialog.h"
|
||||
#include "gui/SharedFilesDialog.h"
|
||||
#include "gui/NetworkDialog.h"
|
||||
#include "gui/chat/ChatDialog.h"
|
||||
#include "gui/QuickStartWizard.h"
|
||||
#include "gui/MessengerWindow.h"
|
||||
#include "gui/StartDialog.h"
|
||||
#include "gui/GenCertDialog.h"
|
||||
#include "gui/settings/rsharesettings.h"
|
||||
#include "gui/settings/RsharePeerSettings.h"
|
||||
#include "gui/connect/ConfCertDialog.h"
|
||||
#include "gui/settings/rsharesettings.h"
|
||||
#include "gui/settings/WebuiPage.h"
|
||||
#include "idle/idle.h"
|
||||
#include "gui/common/Emoticons.h"
|
||||
#include "gui/RetroShareLink.h"
|
||||
#include "gui/SoundManager.h"
|
||||
#include "gui/NetworkView.h"
|
||||
#include "lang/languagesupport.h"
|
||||
#include "util/RsGxsUpdateBroadcast.h"
|
||||
#include "gui/settings/WebuiPage.h"
|
||||
|
||||
#include "retroshare/rsidentity.h"
|
||||
|
||||
#ifdef SIGFPE_DEBUG
|
||||
#include <fenv.h>
|
||||
@ -250,6 +253,7 @@ feenableexcept(FE_INVALID | FE_DIVBYZERO);
|
||||
/* Start RetroShare */
|
||||
QSplashScreen splashScreen(QPixmap(":/images/logo/logo_splash.png")/* , Qt::WindowStaysOnTopHint*/);
|
||||
|
||||
QString sDefaultGXSIdToCreate = "";
|
||||
switch (initResult) {
|
||||
case RS_INIT_OK:
|
||||
{
|
||||
@ -278,6 +282,7 @@ feenableexcept(FE_INVALID | FE_DIVBYZERO);
|
||||
if (gd.exec () == QDialog::Rejected) {
|
||||
return 1;
|
||||
}
|
||||
sDefaultGXSIdToCreate = gd.getGXSNickname();
|
||||
}
|
||||
|
||||
splashScreen.show();
|
||||
@ -356,6 +361,15 @@ feenableexcept(FE_INVALID | FE_DIVBYZERO);
|
||||
|
||||
w->processLastArgs();
|
||||
|
||||
if (!sDefaultGXSIdToCreate.isEmpty()) {
|
||||
RsIdentityParameters params;
|
||||
params.nickname = sDefaultGXSIdToCreate.toUtf8().constData();
|
||||
params.isPgpLinked = true;
|
||||
params.mImage.clear();
|
||||
uint32_t token = 0;
|
||||
rsIdentity->createIdentity(token, params);
|
||||
}
|
||||
|
||||
// I'm using a signal to transfer the hashing info to the mainwindow, because Qt schedules signals properly to
|
||||
// avoid clashes between infos from threads.
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user