mirror of https://github.com/cutefishos/calamares
UI for users viewmodule.
parent
c655c99f67
commit
fb32432548
@ -0,0 +1,15 @@
|
|||||||
|
include_directories( ${PROJECT_BINARY_DIR}/src/libcalamaresui )
|
||||||
|
calamares_add_plugin( users
|
||||||
|
TYPE viewmodule
|
||||||
|
EXPORT_MACRO PLUGINDLLEXPORT_PRO
|
||||||
|
CONFIG_FILE module.conf
|
||||||
|
SOURCES
|
||||||
|
# CreateUserJob.cpp
|
||||||
|
UsersViewStep.cpp
|
||||||
|
UsersPage.cpp
|
||||||
|
UI
|
||||||
|
page_usersetup.ui
|
||||||
|
LINK_LIBRARIES
|
||||||
|
calamaresui
|
||||||
|
SHARED_LIB
|
||||||
|
)
|
@ -0,0 +1,207 @@
|
|||||||
|
/* === This file is part of Calamares - <http://github.com/calamares> ===
|
||||||
|
*
|
||||||
|
* Copyright 2014, Teo Mrnjavac <teo@kde.org>
|
||||||
|
*
|
||||||
|
* Portions from the Manjaro Installation Framework
|
||||||
|
* by Roland Singer <roland@manjaro.org>
|
||||||
|
* Copyright (C) 2007 Free Software Foundation, Inc.
|
||||||
|
*
|
||||||
|
* Calamares is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* Calamares is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "UsersPage.h"
|
||||||
|
#include "ui_page_usersetup.h"
|
||||||
|
|
||||||
|
#include <QBoxLayout>
|
||||||
|
#include <QLabel>
|
||||||
|
#include <QLineEdit>
|
||||||
|
#include <QRegExp>
|
||||||
|
#include <QRegExpValidator>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
UsersPage::UsersPage( QWidget* parent )
|
||||||
|
: QWidget( parent )
|
||||||
|
, ui( new Ui::Page_UserSetup )
|
||||||
|
, m_readyUsername( false )
|
||||||
|
, m_readyHostname( false )
|
||||||
|
, m_readyPassword( false )
|
||||||
|
, m_readyRootPassword( false )
|
||||||
|
{
|
||||||
|
ui->setupUi( this );
|
||||||
|
|
||||||
|
// Connect signals and slots
|
||||||
|
connect( ui->textBoxUsername, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onUsernameTextChanged );
|
||||||
|
connect( ui->textBoxHostname, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onHostnameTextChanged );
|
||||||
|
connect( ui->textBoxUserPassword, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onPasswordTextChanged );
|
||||||
|
connect( ui->textBoxUserVerifiedPassword, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onPasswordTextChanged );
|
||||||
|
connect( ui->textBoxRootPassword, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onRootPasswordTextChanged );
|
||||||
|
connect( ui->textBoxVerifiedRootPassword, &QLineEdit::textChanged,
|
||||||
|
this, &UsersPage::onRootPasswordTextChanged );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
UsersPage::~UsersPage()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
UsersPage::isReady()
|
||||||
|
{
|
||||||
|
return m_readyHostname && m_readyPassword && m_readyRootPassword && m_readyUsername;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersPage::onUsernameTextChanged( const QString& textRef )
|
||||||
|
{
|
||||||
|
QString text = textRef;
|
||||||
|
QRegExp rx( "^[a-z][-a-z0-9_]*\\$" );
|
||||||
|
QRegExpValidator val( rx );
|
||||||
|
int pos = -1;
|
||||||
|
|
||||||
|
if ( text.isEmpty() )
|
||||||
|
{
|
||||||
|
ui->labelUsernameError->clear();
|
||||||
|
ui->labelUsername->clear();
|
||||||
|
m_readyUsername = false;
|
||||||
|
}
|
||||||
|
else if ( val.validate( text, pos ) == QValidator::Invalid )
|
||||||
|
{
|
||||||
|
ui->labelUsername->setPixmap( QPixmap( ":/images/invalid.png" ) );
|
||||||
|
--pos;
|
||||||
|
|
||||||
|
if ( pos >= 0 && pos < text.size() )
|
||||||
|
ui->labelUsernameError->setText(
|
||||||
|
tr( "Your username contains an invalid character '%1'" )
|
||||||
|
.arg( text.at( pos ) ) );
|
||||||
|
else
|
||||||
|
ui->labelUsernameError->setText(
|
||||||
|
tr( "Your username contains invalid characters!" ) );
|
||||||
|
|
||||||
|
m_readyUsername = false;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
ui->labelUsername->setPixmap( QPixmap( ":/images/valid.png" ) );
|
||||||
|
ui->labelUsernameError->clear();
|
||||||
|
m_readyUsername = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
emit checkReady( isReady() );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersPage::onHostnameTextChanged( const QString& textRef )
|
||||||
|
{
|
||||||
|
QString text = textRef;
|
||||||
|
QRegExp rx( "^[a-zA-Z][-a-zA-Z0-9_]*\\$" );
|
||||||
|
QRegExpValidator val( rx );
|
||||||
|
int pos = -1;
|
||||||
|
|
||||||
|
if ( text.isEmpty() )
|
||||||
|
{
|
||||||
|
ui->labelHostnameError->clear();
|
||||||
|
ui->labelHostname->clear();
|
||||||
|
m_readyHostname= false;
|
||||||
|
}
|
||||||
|
else if ( val.validate( text, pos ) == QValidator::Invalid )
|
||||||
|
{
|
||||||
|
ui->labelHostname->setPixmap( QPixmap( ":/images/invalid.png" ) );
|
||||||
|
--pos;
|
||||||
|
|
||||||
|
if ( pos >= 0 && pos < text.size() )
|
||||||
|
ui->labelHostnameError->setText(
|
||||||
|
tr( "Your username contains an invalid character '%1'" )
|
||||||
|
.arg( text.at( pos ) ) );
|
||||||
|
else
|
||||||
|
ui->labelHostnameError->setText(
|
||||||
|
tr( "Your username contains invalid characters!" ) );
|
||||||
|
|
||||||
|
m_readyHostname = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ui->labelHostname->setPixmap( QPixmap( ":/images/valid.png" ) );
|
||||||
|
ui->labelHostnameError->clear();
|
||||||
|
m_readyHostname = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
emit checkReady( isReady() );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersPage::onPasswordTextChanged( const QString& )
|
||||||
|
{
|
||||||
|
QString pw1 = ui->textBoxUserPassword->text();
|
||||||
|
QString pw2 = ui->textBoxUserVerifiedPassword->text();
|
||||||
|
|
||||||
|
if ( pw1.isEmpty() && pw2.isEmpty() )
|
||||||
|
{
|
||||||
|
ui->labelUserPasswordError->clear();
|
||||||
|
ui->labelUserPassword->clear();
|
||||||
|
m_readyPassword = false;
|
||||||
|
}
|
||||||
|
else if ( pw1 != pw2 )
|
||||||
|
{
|
||||||
|
ui->labelUserPasswordError->setText( tr( "Your passwords do not match!" ) );
|
||||||
|
ui->labelUserPassword->setPixmap( QPixmap( ":/images/invalid.png" ) );
|
||||||
|
m_readyPassword = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ui->labelUserPasswordError->clear();
|
||||||
|
ui->labelUserPassword->setPixmap( QPixmap( ":/images/valid.png" ) );
|
||||||
|
m_readyPassword = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
emit checkReady( isReady() );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersPage::onRootPasswordTextChanged( const QString& )
|
||||||
|
{
|
||||||
|
QString pw1 = ui->textBoxRootPassword->text();
|
||||||
|
QString pw2 = ui->textBoxVerifiedRootPassword->text();
|
||||||
|
|
||||||
|
if ( pw1.isEmpty() && pw2.isEmpty() )
|
||||||
|
{
|
||||||
|
ui->labelRootPasswordError->clear();
|
||||||
|
ui->labelRootPassword->clear();
|
||||||
|
m_readyRootPassword = false;
|
||||||
|
}
|
||||||
|
else if ( pw1 != pw2 )
|
||||||
|
{
|
||||||
|
ui->labelRootPasswordError->setText( tr( "Your passwords do not match!" ) );
|
||||||
|
ui->labelRootPassword->setPixmap( QPixmap( ":/images/invalid.png" ) );
|
||||||
|
m_readyRootPassword = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ui->labelRootPasswordError->clear();
|
||||||
|
ui->labelRootPassword->setPixmap( QPixmap( ":/images/valid.png" ) );
|
||||||
|
m_readyRootPassword = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
emit checkReady( isReady() );
|
||||||
|
}
|
@ -0,0 +1,59 @@
|
|||||||
|
/* === This file is part of Calamares - <http://github.com/calamares> ===
|
||||||
|
*
|
||||||
|
* Copyright 2014, Teo Mrnjavac <teo@kde.org>
|
||||||
|
*
|
||||||
|
* Portions from the Manjaro Installation Framework
|
||||||
|
* by Roland Singer <roland@manjaro.org>
|
||||||
|
* Copyright (C) 2007 Free Software Foundation, Inc.
|
||||||
|
*
|
||||||
|
* Calamares is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* Calamares is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef USERSPAGE_H
|
||||||
|
#define USERSPAGE_H
|
||||||
|
|
||||||
|
#include <QWidget>
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class Page_UserSetup;
|
||||||
|
}
|
||||||
|
|
||||||
|
class UsersPage : public QWidget
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit UsersPage( QWidget* parent = nullptr );
|
||||||
|
virtual ~UsersPage();
|
||||||
|
|
||||||
|
bool isReady();
|
||||||
|
|
||||||
|
protected slots:
|
||||||
|
void onUsernameTextChanged( const QString& );
|
||||||
|
void onHostnameTextChanged( const QString& );
|
||||||
|
void onPasswordTextChanged( const QString& );
|
||||||
|
void onRootPasswordTextChanged( const QString& );
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void checkReady( bool );
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::Page_UserSetup* ui;
|
||||||
|
bool m_readyUsername;
|
||||||
|
bool m_readyHostname;
|
||||||
|
bool m_readyPassword;
|
||||||
|
bool m_readyRootPassword;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // USERSPAGE_H
|
@ -0,0 +1,92 @@
|
|||||||
|
/* === This file is part of Calamares - <http://github.com/calamares> ===
|
||||||
|
*
|
||||||
|
* Copyright 2014, Teo Mrnjavac <teo@kde.org>
|
||||||
|
*
|
||||||
|
* Calamares is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* Calamares is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "UsersViewStep.h"
|
||||||
|
|
||||||
|
#include "UsersPage.h"
|
||||||
|
|
||||||
|
UsersViewStep::UsersViewStep( QObject* parent )
|
||||||
|
: Calamares::ViewStep( parent )
|
||||||
|
, m_widget( new UsersPage() )
|
||||||
|
{
|
||||||
|
emit nextStatusChanged( true );
|
||||||
|
connect( m_widget, &UsersPage::checkReady,
|
||||||
|
this, &UsersViewStep::nextStatusChanged );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
UsersViewStep::~UsersViewStep()
|
||||||
|
{
|
||||||
|
if ( m_widget && m_widget->parent() == nullptr )
|
||||||
|
m_widget->deleteLater();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
QString
|
||||||
|
UsersViewStep::prettyName() const
|
||||||
|
{
|
||||||
|
return tr( "Users" );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
QWidget*
|
||||||
|
UsersViewStep::widget()
|
||||||
|
{
|
||||||
|
return m_widget;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersViewStep::next()
|
||||||
|
{
|
||||||
|
emit done();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
UsersViewStep::back()
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
UsersViewStep::isNextEnabled() const
|
||||||
|
{
|
||||||
|
return m_widget->isReady();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
UsersViewStep::isAtBeginning() const
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
UsersViewStep::isAtEnd() const
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
QList< Calamares::job_ptr >
|
||||||
|
UsersViewStep::jobs() const
|
||||||
|
{
|
||||||
|
return QList< Calamares::job_ptr >();
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,58 @@
|
|||||||
|
/* === This file is part of Calamares - <http://github.com/calamares> ===
|
||||||
|
*
|
||||||
|
* Copyright 2014, Teo Mrnjavac <teo@kde.org>
|
||||||
|
*
|
||||||
|
* Calamares is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* Calamares is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef USERSPAGEPLUGIN_H
|
||||||
|
#define USERSPAGEPLUGIN_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
#include "viewpages/ViewStep.h"
|
||||||
|
#include "PluginDllMacro.h"
|
||||||
|
|
||||||
|
class UsersPage;
|
||||||
|
|
||||||
|
class PLUGINDLLEXPORT UsersViewStep : public Calamares::ViewStep
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
Q_PLUGIN_METADATA( IID "calamares.ViewModule/1.0" )
|
||||||
|
|
||||||
|
Q_INTERFACES( Calamares::ViewStep )
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit UsersViewStep( QObject* parent = nullptr );
|
||||||
|
virtual ~UsersViewStep();
|
||||||
|
|
||||||
|
QString prettyName() const override;
|
||||||
|
|
||||||
|
QWidget* widget() override;
|
||||||
|
|
||||||
|
void next() override;
|
||||||
|
void back() override;
|
||||||
|
|
||||||
|
bool isNextEnabled() const override;
|
||||||
|
|
||||||
|
bool isAtBeginning() const override;
|
||||||
|
bool isAtEnd() const override;
|
||||||
|
|
||||||
|
QList< Calamares::job_ptr > jobs() const override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
UsersPage* m_widget;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // USERSPAGEPLUGIN_H
|
Binary file not shown.
After Width: | Height: | Size: 7.6 KiB |
Binary file not shown.
After Width: | Height: | Size: 7.1 KiB |
@ -0,0 +1,10 @@
|
|||||||
|
# Module metadata file for users viewmodule
|
||||||
|
# Syntax is YAML 1.2
|
||||||
|
---
|
||||||
|
type: "view" #core or view
|
||||||
|
name: "users" #the module name. must be unique and same as the parent directory
|
||||||
|
interface: "qtplugin" #can be: qtplugin, python, process, ...
|
||||||
|
requires: [] #list of module names that must also be loaded. only applies to
|
||||||
|
#binary plugins! these are actual link-time dependencies, not
|
||||||
|
#conceptual dependencies for the setup procedure
|
||||||
|
load: "libcalamares_viewmodule_users.so"
|
@ -0,0 +1,603 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>Page_UserSetup</class>
|
||||||
|
<widget class="QWidget" name="Page_UserSetup">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>866</width>
|
||||||
|
<height>601</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Form</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_12">
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_8">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="username_label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>What name do you want to use to log in?</string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QGridLayout" name="_29">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="verticalSpacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLineEdit" name="textBoxUsername">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0" colspan="4">
|
||||||
|
<widget class="QLabel" name="username_extra_label_2">
|
||||||
|
<property name="styleSheet">
|
||||||
|
<string>font-weight: normal</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string><small>If more than one person will use this computer, you can set up multiple accounts after installation.</small></string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLabel" name="labelUsername">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="scaledContents">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="2">
|
||||||
|
<widget class="QLabel" name="labelUsernameError">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
|
||||||
|
<horstretch>1</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="Line" name="line_12">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_10">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="password_label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Choose a password to keep your account safe.</string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QGridLayout" name="_31">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="verticalSpacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item row="1" column="0" colspan="5">
|
||||||
|
<widget class="QLabel" name="password_extra_label_3">
|
||||||
|
<property name="styleSheet">
|
||||||
|
<string>font-weight: normal</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string><small>Enter the same password twice, so that it can be checked for typing errors.</small></string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="2">
|
||||||
|
<widget class="QLabel" name="labelUserPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="scaledContents">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="3">
|
||||||
|
<widget class="QLabel" name="labelUserPasswordError">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
|
||||||
|
<horstretch>1</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>100</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLineEdit" name="textBoxUserVerifiedPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="echoMode">
|
||||||
|
<enum>QLineEdit::Password</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLineEdit" name="textBoxUserPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="echoMode">
|
||||||
|
<enum>QLineEdit::Password</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="Line" name="line_14">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_9">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="hostname_label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>What is the name of this computer?</string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QGridLayout" name="_30">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="verticalSpacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLineEdit" name="textBoxHostname">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0" colspan="4">
|
||||||
|
<widget class="QLabel" name="hostname_extra_label_2">
|
||||||
|
<property name="styleSheet">
|
||||||
|
<string>font-weight: normal</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string><small>This name will be used if you make the computer visible to others on a network.</small></string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLabel" name="labelHostname">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="scaledContents">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="2">
|
||||||
|
<widget class="QLabel" name="labelHostnameError">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
|
||||||
|
<horstretch>1</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="Line" name="line_13">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_11">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="root_password_label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Choose a root password.</string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QGridLayout" name="_32">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="verticalSpacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item row="1" column="0" colspan="5">
|
||||||
|
<widget class="QLabel" name="password_extra_label_4">
|
||||||
|
<property name="styleSheet">
|
||||||
|
<string>font-weight: normal</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string><small>Enter the same password twice, so that it can be checked for typing errors.</small></string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="2">
|
||||||
|
<widget class="QLabel" name="labelRootPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>24</width>
|
||||||
|
<height>24</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="scaledContents">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="3">
|
||||||
|
<widget class="QLabel" name="labelRootPasswordError">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
|
||||||
|
<horstretch>1</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>100</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLineEdit" name="textBoxVerifiedRootPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="echoMode">
|
||||||
|
<enum>QLineEdit::Password</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLineEdit" name="textBoxRootPassword">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>200</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="echoMode">
|
||||||
|
<enum>QLineEdit::Password</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="Line" name="line_15">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_7">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="login_label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Login Options:</string>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QWidget" name="widget_7" native="true">
|
||||||
|
<layout class="QGridLayout" name="gridLayout_10">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>2</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>2</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>2</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>2</number>
|
||||||
|
</property>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QRadioButton" name="checkBoxLoginAuto">
|
||||||
|
<property name="text">
|
||||||
|
<string>Log in automatically</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QRadioButton" name="checkBoxLoginNormal">
|
||||||
|
<property name="text">
|
||||||
|
<string>Require my password to log in</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<tabstops>
|
||||||
|
<tabstop>textBoxUsername</tabstop>
|
||||||
|
<tabstop>textBoxUserPassword</tabstop>
|
||||||
|
<tabstop>textBoxUserVerifiedPassword</tabstop>
|
||||||
|
<tabstop>textBoxHostname</tabstop>
|
||||||
|
<tabstop>textBoxRootPassword</tabstop>
|
||||||
|
<tabstop>textBoxVerifiedRootPassword</tabstop>
|
||||||
|
<tabstop>checkBoxLoginNormal</tabstop>
|
||||||
|
<tabstop>checkBoxLoginAuto</tabstop>
|
||||||
|
</tabstops>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
@ -0,0 +1,6 @@
|
|||||||
|
<RCC>
|
||||||
|
<qresource prefix="/">
|
||||||
|
<file>images/invalid.png</file>
|
||||||
|
<file>images/valid.png</file>
|
||||||
|
</qresource>
|
||||||
|
</RCC>
|
Loading…
Reference in New Issue