diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2010-02-08 13:04:32 (GMT) |
---|---|---|
committer | Alan Alpert <alan.alpert@nokia.com> | 2010-02-08 14:26:58 (GMT) |
commit | 3e8e1b369752d8a0b42f088f577f3d33eb29f8a9 (patch) | |
tree | c6cd3a3ef87c0dedbe66c22627179bfbb9f67747 /src/gui/widgets | |
parent | 322fb5291f91ab389300ec5e28155bf881bcd518 (diff) | |
download | Qt-3e8e1b369752d8a0b42f088f577f3d33eb29f8a9.zip Qt-3e8e1b369752d8a0b42f088f577f3d33eb29f8a9.tar.gz Qt-3e8e1b369752d8a0b42f088f577f3d33eb29f8a9.tar.bz2 |
Add empty constructor for validators.
Needed to use them in QML. Also adds Q_ENUMS macro for an enum used by
QDoubleValidator.
Reviewed-by: trustme
Diffstat (limited to 'src/gui/widgets')
-rw-r--r-- | src/gui/widgets/qvalidator.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/widgets/qvalidator.h b/src/gui/widgets/qvalidator.h index e996a01..63734ca 100644 --- a/src/gui/widgets/qvalidator.h +++ b/src/gui/widgets/qvalidator.h @@ -137,10 +137,11 @@ class Q_GUI_EXPORT QDoubleValidator : public QValidator Q_PROPERTY(double bottom READ bottom WRITE setBottom) Q_PROPERTY(double top READ top WRITE setTop) Q_PROPERTY(int decimals READ decimals WRITE setDecimals) + Q_ENUMS(Notation) Q_PROPERTY(Notation notation READ notation WRITE setNotation) public: - explicit QDoubleValidator(QObject * parent); + explicit QDoubleValidator(QObject * parent = 0); QDoubleValidator(double bottom, double top, int decimals, QObject * parent); ~QDoubleValidator(); @@ -184,7 +185,7 @@ class Q_GUI_EXPORT QRegExpValidator : public QValidator Q_PROPERTY(QRegExp regExp READ regExp WRITE setRegExp) public: - explicit QRegExpValidator(QObject *parent); + explicit QRegExpValidator(QObject *parent = 0); QRegExpValidator(const QRegExp& rx, QObject *parent); ~QRegExpValidator(); |