//--------------------------------------------------------------------------- bool TGJVEditFrame::valid( validTypes command ) { MinosParameters::getMinosParameters() ->clearErrorList( ); // clear the error list if ( contest->isReadOnly() ) return true; bool pvalid = validateControls( command ); // do control validation if ( command == cmCheckValid ) // our own command! contactValid(); // re-validate, as we may have changed things pvalid = validateControls( cmValidStatus ); // look at current validity return pvalid; }
void LoginWidget::responseToRejectAttempt(const QString &errorString) { _isAttempingToReject = false; if (errorString.isEmpty()) { close(); } else { validateControls(); setStatus(errorString); } }
LoginWidget::LoginWidget(QWidget *parent) : QWidget(parent), ui(new Ui::LoginWidget) { ui->setupUi(this); setWindowFlags(Qt::Dialog); connect(ui->connectButton, SIGNAL(pressed()), this, SLOT(attemptToAccept())); connect(ui->addressEdit, SIGNAL(textChanged(QString)), this, SLOT(validateControls())); connect(ui->loginEdit, SIGNAL(textChanged(QString)), this, SLOT(validateControls())); connect(ui->passwordEdit, SIGNAL(textChanged(QString)), this, SLOT(validateControls())); connect(this, SIGNAL(acceptAttempt()), this, SLOT(validateControls())); connect(this, SIGNAL(rejectAttempt()), this, SLOT(validateControls())); setStatus(""); _isAttempingToAccept = false; _isAttempingToReject = false; validateControls(); }