mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Rapatriement de la branche 0.2 dans le trunk
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@558 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
33
sources/qetregexpvalidator.cpp
Normal file
33
sources/qetregexpvalidator.cpp
Normal file
@@ -0,0 +1,33 @@
|
||||
#include "qetregexpvalidator.h"
|
||||
|
||||
/**
|
||||
Constructeur
|
||||
@param object QObject parent
|
||||
*/
|
||||
QETRegExpValidator::QETRegExpValidator(QObject *parent) : QRegExpValidator(parent) {
|
||||
}
|
||||
|
||||
/**
|
||||
Constructeur
|
||||
@param regexp Expression reguliere a valider
|
||||
@param object QObject parent
|
||||
*/
|
||||
QETRegExpValidator::QETRegExpValidator(const QRegExp ®exp, QObject *parent) : QRegExpValidator(regexp, parent) {
|
||||
}
|
||||
|
||||
/**
|
||||
Destructeur
|
||||
*/
|
||||
QETRegExpValidator::~QETRegExpValidator() {
|
||||
}
|
||||
|
||||
/**
|
||||
@see QRegExpValidator::validate
|
||||
@see validationFailed()
|
||||
Emet le signal validationFailed si la validation echoue
|
||||
*/
|
||||
QValidator::State QETRegExpValidator::validate(QString &input, int &pos) const {
|
||||
QValidator::State result = QRegExpValidator::validate(input, pos);
|
||||
if (result == QValidator::Invalid) emit(validationFailed());
|
||||
return(result);
|
||||
}
|
||||
Reference in New Issue
Block a user