forked from qt-creator/qt-creator
Maemo: Add authentication options (password or key based)
This commit is contained in:
@@ -37,6 +37,7 @@
|
|||||||
#include <coreplugin/icore.h>
|
#include <coreplugin/icore.h>
|
||||||
|
|
||||||
#include <QtCore/QSettings>
|
#include <QtCore/QSettings>
|
||||||
|
#include <QtGui/QDesktopServices>
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
|
||||||
@@ -52,9 +53,15 @@ namespace {
|
|||||||
const QLatin1String HostKey("Host");
|
const QLatin1String HostKey("Host");
|
||||||
const QLatin1String PortKey("Port");
|
const QLatin1String PortKey("Port");
|
||||||
const QLatin1String UserNameKey("Uname");
|
const QLatin1String UserNameKey("Uname");
|
||||||
|
const QLatin1String AuthKey("Authentication");
|
||||||
|
const QLatin1String KeyFileKey("KeyFile");
|
||||||
const QLatin1String PasswordKey("Password");
|
const QLatin1String PasswordKey("Password");
|
||||||
const QLatin1String TimeoutKey("Timeout");
|
const QLatin1String TimeoutKey("Timeout");
|
||||||
const QLatin1String InternalIdKey("InternalId");
|
const QLatin1String InternalIdKey("InternalId");
|
||||||
|
|
||||||
|
const QString DefaultKeyFile =
|
||||||
|
QDesktopServices::storageLocation(QDesktopServices::HomeLocation)
|
||||||
|
+ QLatin1String("/.ssh/id_rsa");
|
||||||
};
|
};
|
||||||
|
|
||||||
class DevConfIdMatcher
|
class DevConfIdMatcher
|
||||||
@@ -73,6 +80,8 @@ MaemoDeviceConfigurations::DeviceConfig::DeviceConfig(const QString &name)
|
|||||||
: name(name),
|
: name(name),
|
||||||
type(Physical),
|
type(Physical),
|
||||||
port(22),
|
port(22),
|
||||||
|
authentication(Key),
|
||||||
|
keyFile(DefaultKeyFile),
|
||||||
timeout(30),
|
timeout(30),
|
||||||
internalId(MaemoDeviceConfigurations::instance().m_nextId++)
|
internalId(MaemoDeviceConfigurations::instance().m_nextId++)
|
||||||
{
|
{
|
||||||
@@ -84,7 +93,9 @@ MaemoDeviceConfigurations::DeviceConfig::DeviceConfig(const QSettings &settings)
|
|||||||
host(settings.value(HostKey).toString()),
|
host(settings.value(HostKey).toString()),
|
||||||
port(settings.value(PortKey, 22).toInt()),
|
port(settings.value(PortKey, 22).toInt()),
|
||||||
uname(settings.value(UserNameKey).toString()),
|
uname(settings.value(UserNameKey).toString()),
|
||||||
|
authentication(static_cast<AuthType>(settings.value(AuthKey).toInt())),
|
||||||
pwd(settings.value(PasswordKey).toString()),
|
pwd(settings.value(PasswordKey).toString()),
|
||||||
|
keyFile(settings.value(KeyFileKey).toString()),
|
||||||
timeout(settings.value(TimeoutKey, 30).toInt()),
|
timeout(settings.value(TimeoutKey, 30).toInt()),
|
||||||
internalId(settings.value(InternalIdKey, MaemoDeviceConfigurations::instance().m_nextId).toInt())
|
internalId(settings.value(InternalIdKey, MaemoDeviceConfigurations::instance().m_nextId).toInt())
|
||||||
{
|
{
|
||||||
@@ -110,7 +121,9 @@ void MaemoDeviceConfigurations::DeviceConfig::save(QSettings &settings) const
|
|||||||
settings.setValue(HostKey, host);
|
settings.setValue(HostKey, host);
|
||||||
settings.setValue(PortKey, port);
|
settings.setValue(PortKey, port);
|
||||||
settings.setValue(UserNameKey, uname);
|
settings.setValue(UserNameKey, uname);
|
||||||
|
settings.setValue(AuthKey, authentication);
|
||||||
settings.setValue(PasswordKey, pwd);
|
settings.setValue(PasswordKey, pwd);
|
||||||
|
settings.setValue(KeyFileKey, keyFile);
|
||||||
settings.setValue(TimeoutKey, timeout);
|
settings.setValue(TimeoutKey, timeout);
|
||||||
settings.setValue(InternalIdKey, internalId);
|
settings.setValue(InternalIdKey, internalId);
|
||||||
}
|
}
|
||||||
|
@@ -56,6 +56,7 @@ public:
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
enum DeviceType { Physical, Simulator };
|
enum DeviceType { Physical, Simulator };
|
||||||
|
enum AuthType { Password, Key };
|
||||||
DeviceConfig();
|
DeviceConfig();
|
||||||
DeviceConfig(const QString &name);
|
DeviceConfig(const QString &name);
|
||||||
DeviceConfig(const QSettings &settings);
|
DeviceConfig(const QSettings &settings);
|
||||||
@@ -66,7 +67,9 @@ public:
|
|||||||
QString host;
|
QString host;
|
||||||
int port;
|
int port;
|
||||||
QString uname;
|
QString uname;
|
||||||
|
AuthType authentication;
|
||||||
QString pwd;
|
QString pwd;
|
||||||
|
QString keyFile;
|
||||||
int timeout;
|
int timeout;
|
||||||
quint64 internalId;
|
quint64 internalId;
|
||||||
|
|
||||||
|
@@ -112,6 +112,7 @@ protected:
|
|||||||
const QString port() const;
|
const QString port() const;
|
||||||
const QString targetCmdLinePrefix() const;
|
const QString targetCmdLinePrefix() const;
|
||||||
const QString remoteDir() const;
|
const QString remoteDir() const;
|
||||||
|
const QStringList options() const;
|
||||||
virtual void deploymentFinished(bool success)=0;
|
virtual void deploymentFinished(bool success)=0;
|
||||||
virtual bool setProcessEnvironment(QProcess &process);
|
virtual bool setProcessEnvironment(QProcess &process);
|
||||||
private slots:
|
private slots:
|
||||||
@@ -752,6 +753,7 @@ MaemoRunConfigurationWidget::MaemoRunConfigurationWidget(
|
|||||||
m_configNameLineEdit = new QLineEdit(m_runConfiguration->name());
|
m_configNameLineEdit = new QLineEdit(m_runConfiguration->name());
|
||||||
mainLayout->addRow(tr("Run configuration name:"), m_configNameLineEdit);
|
mainLayout->addRow(tr("Run configuration name:"), m_configNameLineEdit);
|
||||||
m_devConfBox = new QComboBox;
|
m_devConfBox = new QComboBox;
|
||||||
|
m_devConfBox->setSizeAdjustPolicy(QComboBox::AdjustToContents);
|
||||||
mainLayout->addRow(new QLabel(tr("Device Configuration:")), m_devConfBox);
|
mainLayout->addRow(new QLabel(tr("Device Configuration:")), m_devConfBox);
|
||||||
m_executableLabel = new QLabel(m_runConfiguration->executable());
|
m_executableLabel = new QLabel(m_runConfiguration->executable());
|
||||||
mainLayout->addRow(tr("Executable:"), m_executableLabel);
|
mainLayout->addRow(tr("Executable:"), m_executableLabel);
|
||||||
@@ -1031,8 +1033,10 @@ AbstractMaemoRunControl::AbstractMaemoRunControl(RunConfiguration *rc)
|
|||||||
void AbstractMaemoRunControl::startDeployment(bool forDebugging)
|
void AbstractMaemoRunControl::startDeployment(bool forDebugging)
|
||||||
{
|
{
|
||||||
QTC_ASSERT(runConfig, return);
|
QTC_ASSERT(runConfig, return);
|
||||||
if (!devConfig.isValid())
|
if (!devConfig.isValid()) {
|
||||||
deploymentFinished(false);
|
deploymentFinished(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
QStringList deployables;
|
QStringList deployables;
|
||||||
if (runConfig->currentlyNeedsDeployment()) {
|
if (runConfig->currentlyNeedsDeployment()) {
|
||||||
deployingExecutable = true;
|
deployingExecutable = true;
|
||||||
@@ -1050,8 +1054,8 @@ void AbstractMaemoRunControl::startDeployment(bool forDebugging)
|
|||||||
emit addToOutputWindow(this, tr("Files to deploy: %1.")
|
emit addToOutputWindow(this, tr("Files to deploy: %1.")
|
||||||
.arg(deployables.join(" ")));
|
.arg(deployables.join(" ")));
|
||||||
QStringList cmdArgs;
|
QStringList cmdArgs;
|
||||||
cmdArgs << "-P" << port() << deployables << (devConfig.uname
|
cmdArgs << "-P" << port() << options() << deployables
|
||||||
+ "@" + devConfig.host + ":" + remoteDir());
|
<< (devConfig.uname + "@" + devConfig.host + ":" + remoteDir());
|
||||||
deployProcess.setWorkingDirectory(QFileInfo(executableOnHost()).absolutePath());
|
deployProcess.setWorkingDirectory(QFileInfo(executableOnHost()).absolutePath());
|
||||||
deployProcess.start(runConfig->scpCmd(), cmdArgs);
|
deployProcess.start(runConfig->scpCmd(), cmdArgs);
|
||||||
if (!deployProcess.waitForStarted()) {
|
if (!deployProcess.waitForStarted()) {
|
||||||
@@ -1114,6 +1118,19 @@ const QString AbstractMaemoRunControl::remoteDir() const
|
|||||||
: QString::fromLocal8Bit("/home/") + devConfig.uname;
|
: QString::fromLocal8Bit("/home/") + devConfig.uname;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const QStringList AbstractMaemoRunControl::options() const
|
||||||
|
{
|
||||||
|
const bool usePassword =
|
||||||
|
devConfig.authentication == MaemoDeviceConfigurations::DeviceConfig::Password;
|
||||||
|
const QLatin1String opt("-o");
|
||||||
|
return QStringList() << opt
|
||||||
|
<< QString::fromLatin1("PasswordAuthentication=%1").
|
||||||
|
arg(usePassword ? "yes" : "no") << opt
|
||||||
|
<< QString::fromLatin1("PubkeyAuthentication=%1").
|
||||||
|
arg(usePassword ? "no" : "yes") << opt
|
||||||
|
<< QString::fromLatin1("ConnectTimeout=%1").arg(devConfig.timeout);
|
||||||
|
}
|
||||||
|
|
||||||
const QString AbstractMaemoRunControl::executableOnTarget() const
|
const QString AbstractMaemoRunControl::executableOnTarget() const
|
||||||
{
|
{
|
||||||
return QString::fromLocal8Bit("%1/%2").arg(remoteDir()).
|
return QString::fromLocal8Bit("%1/%2").arg(remoteDir()).
|
||||||
@@ -1202,7 +1219,7 @@ void MaemoRunControl::startExecution()
|
|||||||
|
|
||||||
QStringList cmdArgs;
|
QStringList cmdArgs;
|
||||||
cmdArgs << "-n" << "-p" << port() << "-l" << devConfig.uname
|
cmdArgs << "-n" << "-p" << port() << "-l" << devConfig.uname
|
||||||
<< devConfig.host << remoteCall;
|
<< options() << devConfig.host << remoteCall;
|
||||||
sshProcess.start(runConfig->sshCmd(), cmdArgs);
|
sshProcess.start(runConfig->sshCmd(), cmdArgs);
|
||||||
|
|
||||||
sshProcess.start(runConfig->sshCmd(), cmdArgs);
|
sshProcess.start(runConfig->sshCmd(), cmdArgs);
|
||||||
@@ -1237,7 +1254,7 @@ void MaemoRunControl::stop()
|
|||||||
const QString remoteCall = QString::fromLocal8Bit("pkill -x %1; "
|
const QString remoteCall = QString::fromLocal8Bit("pkill -x %1; "
|
||||||
"sleep 1; pkill -x -9 %1").arg(executableFileName());
|
"sleep 1; pkill -x -9 %1").arg(executableFileName());
|
||||||
cmdArgs << "-n" << "-p" << port() << "-l" << devConfig.uname
|
cmdArgs << "-n" << "-p" << port() << "-l" << devConfig.uname
|
||||||
<< devConfig.host << remoteCall;
|
<< options() << devConfig.host << remoteCall;
|
||||||
stopProcess.start(runConfig->sshCmd(), cmdArgs);
|
stopProcess.start(runConfig->sshCmd(), cmdArgs);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1311,7 +1328,7 @@ void MaemoDebugRunControl::startGdbServer()
|
|||||||
.arg(runConfig->arguments().join(" ")));
|
.arg(runConfig->arguments().join(" ")));
|
||||||
QStringList sshArgs;
|
QStringList sshArgs;
|
||||||
sshArgs << "-t" << "-n" << "-l" << devConfig.uname << "-p"
|
sshArgs << "-t" << "-n" << "-l" << devConfig.uname << "-p"
|
||||||
<< port() << devConfig.host << remoteCall;
|
<< port() << options() << devConfig.host << remoteCall;
|
||||||
inferiorPid = -1;
|
inferiorPid = -1;
|
||||||
disconnect(&gdbServer, SIGNAL(readyReadStandardError()), 0, 0);
|
disconnect(&gdbServer, SIGNAL(readyReadStandardError()), 0, 0);
|
||||||
connect(&gdbServer, SIGNAL(readyReadStandardError()), this,
|
connect(&gdbServer, SIGNAL(readyReadStandardError()), this,
|
||||||
@@ -1394,7 +1411,7 @@ void MaemoDebugRunControl::debuggingFinished()
|
|||||||
"kill -9 %1; pkill -x -9 gdbserver").arg(inferiorPid);
|
"kill -9 %1; pkill -x -9 gdbserver").arg(inferiorPid);
|
||||||
QStringList sshArgs;
|
QStringList sshArgs;
|
||||||
sshArgs << "-n" << "-l" << devConfig.uname << "-p" << port()
|
sshArgs << "-n" << "-l" << devConfig.uname << "-p" << port()
|
||||||
<< devConfig.host << remoteCall;
|
<< options() << devConfig.host << remoteCall;
|
||||||
stopProcess.start(runConfig->sshCmd(), sshArgs);
|
stopProcess.start(runConfig->sshCmd(), sshArgs);
|
||||||
}
|
}
|
||||||
qDebug("ssh return code is %d", gdbServer.exitCode());
|
qDebug("ssh return code is %d", gdbServer.exitCode());
|
||||||
|
@@ -127,11 +127,13 @@ private slots:
|
|||||||
void deleteConfig();
|
void deleteConfig();
|
||||||
void configNameEditingFinished();
|
void configNameEditingFinished();
|
||||||
void deviceTypeChanged();
|
void deviceTypeChanged();
|
||||||
|
void authenticationTypeChanged();
|
||||||
void hostNameEditingFinished();
|
void hostNameEditingFinished();
|
||||||
void portEditingFinished();
|
void portEditingFinished();
|
||||||
void timeoutEditingFinished();
|
void timeoutEditingFinished();
|
||||||
void userNameEditingFinished();
|
void userNameEditingFinished();
|
||||||
void passwordEditingFinished();
|
void passwordEditingFinished();
|
||||||
|
void keyFileEditingFinished();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void initGui();
|
void initGui();
|
||||||
@@ -151,12 +153,10 @@ private:
|
|||||||
MaemoSettingsPage::MaemoSettingsPage(QObject *parent)
|
MaemoSettingsPage::MaemoSettingsPage(QObject *parent)
|
||||||
: Core::IOptionsPage(parent)
|
: Core::IOptionsPage(parent)
|
||||||
{
|
{
|
||||||
qDebug("Creating maemo settings page");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MaemoSettingsPage::~MaemoSettingsPage()
|
MaemoSettingsPage::~MaemoSettingsPage()
|
||||||
{
|
{
|
||||||
qDebug("deleting maemo settings page");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QString MaemoSettingsPage::id() const
|
QString MaemoSettingsPage::id() const
|
||||||
@@ -193,7 +193,6 @@ void MaemoSettingsPage::apply()
|
|||||||
|
|
||||||
void MaemoSettingsPage::finish()
|
void MaemoSettingsPage::finish()
|
||||||
{
|
{
|
||||||
// apply();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MaemoSettingsWidget::MaemoSettingsWidget(QWidget *parent)
|
MaemoSettingsWidget::MaemoSettingsWidget(QWidget *parent)
|
||||||
@@ -203,13 +202,11 @@ MaemoSettingsWidget::MaemoSettingsWidget(QWidget *parent)
|
|||||||
m_nameValidator(m_devConfs)
|
m_nameValidator(m_devConfs)
|
||||||
|
|
||||||
{
|
{
|
||||||
qDebug("creating maemo settings widget");
|
|
||||||
initGui();
|
initGui();
|
||||||
}
|
}
|
||||||
|
|
||||||
MaemoSettingsWidget::~MaemoSettingsWidget()
|
MaemoSettingsWidget::~MaemoSettingsWidget()
|
||||||
{
|
{
|
||||||
qDebug("Deleting maemo settings widget");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void MaemoSettingsWidget::initGui()
|
void MaemoSettingsWidget::initGui()
|
||||||
@@ -265,11 +262,16 @@ void MaemoSettingsWidget::display(const MaemoDeviceConfigurations::DeviceConfig
|
|||||||
m_ui->deviceButton->setChecked(true);
|
m_ui->deviceButton->setChecked(true);
|
||||||
else
|
else
|
||||||
m_ui->simulatorButton->setChecked(true);
|
m_ui->simulatorButton->setChecked(true);
|
||||||
|
if (devConfig.authentication == MaemoDeviceConfigurations::DeviceConfig::Password)
|
||||||
|
m_ui->passwordButton->setChecked(true);
|
||||||
|
else
|
||||||
|
m_ui->keyButton->setChecked(true);
|
||||||
m_ui->hostLineEdit->setText(devConfig.host);
|
m_ui->hostLineEdit->setText(devConfig.host);
|
||||||
m_ui->portLineEdit->setText(QString::number(devConfig.port));
|
m_ui->portLineEdit->setText(QString::number(devConfig.port));
|
||||||
m_ui->timeoutLineEdit->setText(QString::number(devConfig.timeout));
|
m_ui->timeoutLineEdit->setText(QString::number(devConfig.timeout));
|
||||||
m_ui->userLineEdit->setText(devConfig.uname);
|
m_ui->userLineEdit->setText(devConfig.uname);
|
||||||
m_ui->pwdLineEdit->setText(devConfig.pwd);
|
m_ui->pwdLineEdit->setText(devConfig.pwd);
|
||||||
|
m_ui->keyFileLineEdit->setText(devConfig.keyFile);
|
||||||
m_ui->detailsWidget->setEnabled(true);
|
m_ui->detailsWidget->setEnabled(true);
|
||||||
m_nameValidator.setName(devConfig.name);
|
m_nameValidator.setName(devConfig.name);
|
||||||
m_portValidator.setValue(devConfig.port);
|
m_portValidator.setValue(devConfig.port);
|
||||||
@@ -284,13 +286,11 @@ void MaemoSettingsWidget::saveSettings()
|
|||||||
|
|
||||||
MaemoDeviceConfigurations::DeviceConfig &MaemoSettingsWidget::currentConfig()
|
MaemoDeviceConfigurations::DeviceConfig &MaemoSettingsWidget::currentConfig()
|
||||||
{
|
{
|
||||||
qDebug("%d/%d", m_ui->configListWidget->count(), m_devConfs.count());
|
|
||||||
Q_ASSERT(m_ui->configListWidget->count() == m_devConfs.count());
|
Q_ASSERT(m_ui->configListWidget->count() == m_devConfs.count());
|
||||||
const QList<QListWidgetItem *> &selectedItems =
|
const QList<QListWidgetItem *> &selectedItems =
|
||||||
m_ui->configListWidget->selectedItems();
|
m_ui->configListWidget->selectedItems();
|
||||||
Q_ASSERT(selectedItems.count() == 1);
|
Q_ASSERT(selectedItems.count() == 1);
|
||||||
const int selectedRow = m_ui->configListWidget->row(selectedItems.first());
|
const int selectedRow = m_ui->configListWidget->row(selectedItems.first());
|
||||||
qDebug("selected row = %d", selectedRow);
|
|
||||||
Q_ASSERT(selectedRow < m_devConfs.count());
|
Q_ASSERT(selectedRow < m_devConfs.count());
|
||||||
return m_devConfs[selectedRow];
|
return m_devConfs[selectedRow];
|
||||||
}
|
}
|
||||||
@@ -311,6 +311,18 @@ void MaemoSettingsWidget::deviceTypeChanged()
|
|||||||
: MaemoDeviceConfigurations::DeviceConfig::Simulator;
|
: MaemoDeviceConfigurations::DeviceConfig::Simulator;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MaemoSettingsWidget::authenticationTypeChanged()
|
||||||
|
{
|
||||||
|
const bool usePassword = m_ui->passwordButton->isChecked();
|
||||||
|
currentConfig().authentication = usePassword
|
||||||
|
? MaemoDeviceConfigurations::DeviceConfig::Password
|
||||||
|
: MaemoDeviceConfigurations::DeviceConfig::Key;
|
||||||
|
m_ui->pwdLineEdit->setEnabled(usePassword);
|
||||||
|
m_ui->passwordLabel->setEnabled(usePassword);
|
||||||
|
m_ui->keyFileLineEdit->setEnabled(!usePassword);
|
||||||
|
m_ui->keyLabel->setEnabled(!usePassword);
|
||||||
|
}
|
||||||
|
|
||||||
void MaemoSettingsWidget::hostNameEditingFinished()
|
void MaemoSettingsWidget::hostNameEditingFinished()
|
||||||
{
|
{
|
||||||
currentConfig().host = m_ui->hostLineEdit->text();
|
currentConfig().host = m_ui->hostLineEdit->text();
|
||||||
@@ -346,6 +358,11 @@ void MaemoSettingsWidget::passwordEditingFinished()
|
|||||||
currentConfig().pwd = m_ui->pwdLineEdit->text();
|
currentConfig().pwd = m_ui->pwdLineEdit->text();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MaemoSettingsWidget::keyFileEditingFinished()
|
||||||
|
{
|
||||||
|
currentConfig().keyFile = m_ui->keyFileLineEdit->text();
|
||||||
|
}
|
||||||
|
|
||||||
void MaemoSettingsWidget::selectionChanged()
|
void MaemoSettingsWidget::selectionChanged()
|
||||||
{
|
{
|
||||||
const QList<QListWidgetItem *> &selectedItems =
|
const QList<QListWidgetItem *> &selectedItems =
|
||||||
|
@@ -42,13 +42,6 @@
|
|||||||
<item row="0" column="1">
|
<item row="0" column="1">
|
||||||
<widget class="QLineEdit" name="nameLineEdit"/>
|
<widget class="QLineEdit" name="nameLineEdit"/>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_2">
|
|
||||||
<property name="text">
|
|
||||||
<string>Device type:</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
<item row="1" column="1">
|
||||||
<widget class="QWidget" name="widget_2" native="true">
|
<widget class="QWidget" name="widget_2" native="true">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
@@ -75,60 +68,114 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0">
|
<item row="3" column="0">
|
||||||
<widget class="QLabel" name="label_3">
|
<widget class="QLabel" name="label_3">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Host Name:</string>
|
<string>Host Name:</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="1">
|
<item row="3" column="1">
|
||||||
<widget class="QLineEdit" name="hostLineEdit"/>
|
<widget class="QLineEdit" name="hostLineEdit"/>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="0">
|
<item row="4" column="0">
|
||||||
<widget class="QLabel" name="label_4">
|
<widget class="QLabel" name="label_4">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Port:</string>
|
<string>Port:</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="1">
|
<item row="4" column="1">
|
||||||
<widget class="QLineEdit" name="portLineEdit"/>
|
<widget class="QLineEdit" name="portLineEdit"/>
|
||||||
</item>
|
</item>
|
||||||
<item row="4" column="0">
|
<item row="5" column="0">
|
||||||
<widget class="QLabel" name="label_5">
|
<widget class="QLabel" name="label_5">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Connection Timeout:</string>
|
<string>Connection Timeout:</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="4" column="1">
|
<item row="5" column="1">
|
||||||
<widget class="QLineEdit" name="timeoutLineEdit"/>
|
<widget class="QLineEdit" name="timeoutLineEdit"/>
|
||||||
</item>
|
</item>
|
||||||
<item row="5" column="0">
|
<item row="6" column="0">
|
||||||
<widget class="QLabel" name="label_6">
|
<widget class="QLabel" name="label_6">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>User Name:</string>
|
<string>User Name:</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="5" column="1">
|
<item row="6" column="1">
|
||||||
<widget class="QLineEdit" name="userLineEdit"/>
|
<widget class="QLineEdit" name="userLineEdit"/>
|
||||||
</item>
|
</item>
|
||||||
<item row="6" column="0">
|
<item row="7" column="0">
|
||||||
<widget class="QLabel" name="label_7">
|
<widget class="QLabel" name="passwordLabel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Password:</string>
|
<string>Password:</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="6" column="1">
|
<item row="7" column="1">
|
||||||
<widget class="QLineEdit" name="pwdLineEdit">
|
<widget class="QLineEdit" name="pwdLineEdit">
|
||||||
<property name="echoMode">
|
<property name="echoMode">
|
||||||
<enum>QLineEdit::Password</enum>
|
<enum>QLineEdit::Password</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Device type:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="label_8">
|
||||||
|
<property name="text">
|
||||||
|
<string>Authentication type:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="1">
|
||||||
|
<widget class="QWidget" name="widget_3" native="true">
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<widget class="QRadioButton" name="passwordButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Password</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QRadioButton" name="keyButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Key</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="0">
|
||||||
|
<widget class="QLabel" name="keyLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string>Private key file:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="1">
|
||||||
|
<widget class="QLineEdit" name="keyFileLineEdit">
|
||||||
|
<property name="echoMode">
|
||||||
|
<enum>QLineEdit::Normal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@@ -180,8 +227,8 @@
|
|||||||
<slot>configNameEditingFinished()</slot>
|
<slot>configNameEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>221</x>
|
<x>372</x>
|
||||||
<y>166</y>
|
<y>146</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>514</x>
|
<x>514</x>
|
||||||
@@ -196,8 +243,8 @@
|
|||||||
<slot>deviceTypeChanged()</slot>
|
<slot>deviceTypeChanged()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>164</x>
|
<x>269</x>
|
||||||
<y>197</y>
|
<y>170</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>511</x>
|
<x>511</x>
|
||||||
@@ -212,8 +259,8 @@
|
|||||||
<slot>hostNameEditingFinished()</slot>
|
<slot>hostNameEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>289</x>
|
<x>397</x>
|
||||||
<y>222</y>
|
<y>219</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>424</x>
|
<x>424</x>
|
||||||
@@ -228,8 +275,8 @@
|
|||||||
<slot>portEditingFinished()</slot>
|
<slot>portEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>320</x>
|
<x>397</x>
|
||||||
<y>248</y>
|
<y>243</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>514</x>
|
<x>514</x>
|
||||||
@@ -244,8 +291,8 @@
|
|||||||
<slot>timeoutEditingFinished()</slot>
|
<slot>timeoutEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>371</x>
|
<x>397</x>
|
||||||
<y>276</y>
|
<y>268</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>425</x>
|
<x>425</x>
|
||||||
@@ -260,8 +307,8 @@
|
|||||||
<slot>userNameEditingFinished()</slot>
|
<slot>userNameEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>340</x>
|
<x>397</x>
|
||||||
<y>302</y>
|
<y>293</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>422</x>
|
<x>422</x>
|
||||||
@@ -276,8 +323,8 @@
|
|||||||
<slot>passwordEditingFinished()</slot>
|
<slot>passwordEditingFinished()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>243</x>
|
<x>394</x>
|
||||||
<y>333</y>
|
<y>317</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>423</x>
|
<x>423</x>
|
||||||
@@ -292,8 +339,8 @@
|
|||||||
<slot>deviceTypeChanged()</slot>
|
<slot>deviceTypeChanged()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>291</x>
|
<x>388</x>
|
||||||
<y>198</y>
|
<y>170</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>426</x>
|
<x>426</x>
|
||||||
@@ -349,6 +396,38 @@
|
|||||||
</hint>
|
</hint>
|
||||||
</hints>
|
</hints>
|
||||||
</connection>
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>passwordButton</sender>
|
||||||
|
<signal>toggled(bool)</signal>
|
||||||
|
<receiver>maemoSettingsWidget</receiver>
|
||||||
|
<slot>authenticationTypeChanged()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>196</x>
|
||||||
|
<y>187</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>513</x>
|
||||||
|
<y>240</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>keyFileLineEdit</sender>
|
||||||
|
<signal>editingFinished()</signal>
|
||||||
|
<receiver>maemoSettingsWidget</receiver>
|
||||||
|
<slot>keyFileChanged()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>208</x>
|
||||||
|
<y>332</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>424</x>
|
||||||
|
<y>41</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
</connections>
|
</connections>
|
||||||
<slots>
|
<slots>
|
||||||
<slot>configNameEditingFinished()</slot>
|
<slot>configNameEditingFinished()</slot>
|
||||||
@@ -361,5 +440,7 @@
|
|||||||
<slot>addConfig()</slot>
|
<slot>addConfig()</slot>
|
||||||
<slot>selectionChanged()</slot>
|
<slot>selectionChanged()</slot>
|
||||||
<slot>deleteConfig()</slot>
|
<slot>deleteConfig()</slot>
|
||||||
|
<slot>authenticationTypeChanged()</slot>
|
||||||
|
<slot>keyFileChanged()</slot>
|
||||||
</slots>
|
</slots>
|
||||||
</ui>
|
</ui>
|
||||||
|
Reference in New Issue
Block a user