20 #include <QPushButton>
33 mAuthNotifyLayout =
new QVBoxLayout;
34 this->setLayout( mAuthNotifyLayout );
36 mAuthNotifyLayout->addWidget( mAuthNotify );
41 connect( leMasterPassCurrent, &QgsPasswordLineEdit::textChanged,
this, &QgsMasterPasswordResetDialog::leMasterPassCurrent_textChanged );
42 connect( leMasterPassNew, &QgsPasswordLineEdit::textChanged,
this, &QgsMasterPasswordResetDialog::leMasterPassNew_textChanged );
51 leMasterPassCurrent->setFocus();
53 bool ok = ( exec() == QDialog::Accepted );
58 *newpass = leMasterPassNew->text();
59 *oldpass = leMasterPassCurrent->text();
60 *keepbackup = chkKeepBackup->isChecked();
67 void QgsMasterPasswordResetDialog::leMasterPassCurrent_textChanged(
const QString &pass )
71 mPassCurOk = !pass.isEmpty();
76 void QgsMasterPasswordResetDialog::leMasterPassNew_textChanged(
const QString &pass )
78 mPassNewOk = !pass.isEmpty();
82 void QgsMasterPasswordResetDialog::validatePasswords()
86 leMasterPassCurrent->setStyleSheet( ss1 );
89 leMasterPassNew->setStyleSheet( ss2 );
90 buttonBox->button( QDialogButtonBox::Ok )->setEnabled( mPassCurOk && mPassNewOk );