[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
main
Adriaan de Groot 4 years ago
parent 941cc9c48b
commit 9fcf9b5fa8

@ -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 );

Loading…
Cancel
Save