From 9fcf9b5fa85822cd2951bb6e46d3a6dadbc5ddad Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Fri, 12 Mar 2021 22:27:08 +0100 Subject: [PATCH] [users] Pick up values from Config object on startup - Previously, we 'knew' that the values in Config were empty, so didn't have to set them from the Config when building the (widget) page --- src/modules/users/UsersPage.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/modules/users/UsersPage.cpp b/src/modules/users/UsersPage.cpp index 6ea03f8ef..9aac94779 100644 --- a/src/modules/users/UsersPage.cpp +++ b/src/modules/users/UsersPage.cpp @@ -101,6 +101,7 @@ UsersPage::UsersPage( Config* config, QWidget* parent ) connect( config, &Config::rootPasswordSecondaryChanged, ui->textBoxVerifiedRootPassword, &QLineEdit::setText ); connect( config, &Config::rootPasswordStatusChanged, this, &UsersPage::reportRootPasswordStatus ); + ui->textBoxFullName->setText( config->fullName() ); connect( ui->textBoxFullName, &QLineEdit::textEdited, config, &Config::setFullName ); connect( config, &Config::fullNameChanged, this, &UsersPage::onFullNameTextEdited ); @@ -108,6 +109,7 @@ UsersPage::UsersPage( Config* config, QWidget* parent ) connect( config, &Config::hostNameChanged, ui->textBoxHostName, &QLineEdit::setText ); connect( config, &Config::hostNameStatusChanged, this, &UsersPage::reportHostNameStatus ); + ui->textBoxLoginName->setText( config->loginName() ); connect( ui->textBoxLoginName, &QLineEdit::textEdited, config, &Config::setLoginName ); connect( config, &Config::loginNameChanged, ui->textBoxLoginName, &QLineEdit::setText ); connect( config, &Config::loginNameStatusChanged, this, &UsersPage::reportLoginNameStatus );