diff options
author | Olivier Goffart <ogoffart@woboq.com> | 2014-04-23 15:12:46 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-04-25 06:37:06 +0200 |
commit | 89ecac46075e51c8125a96bb98e99d39f546dacd (patch) | |
tree | 48f2c68bfebc34133fee9de5987292f4aada9d81 /src/sql/kernel/qsqlerror.h | |
parent | c0825cbfc0c568542a9e4c09e23d42eb76a5a706 (diff) |
QSqlError: Mark deprecated functiond with QT_DEPRECATED
And move the default argument from the deprecated constructor to
the new one
Also make sure that the error number is consistent across the
two constructor
Change-Id: I3721266b39ab493f0add35b2d1f892b2f6094992
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/sql/kernel/qsqlerror.h')
-rw-r--r-- | src/sql/kernel/qsqlerror.h | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/sql/kernel/qsqlerror.h b/src/sql/kernel/qsqlerror.h index 4e27ab03ae..679e0f9e3c 100644 --- a/src/sql/kernel/qsqlerror.h +++ b/src/sql/kernel/qsqlerror.h @@ -60,15 +60,13 @@ public: UnknownError }; #if QT_DEPRECATED_SINCE(5, 3) - QSqlError( const QString& driverText = QString(), - const QString& databaseText = QString(), - ErrorType type = NoError, - int number = -1); + QT_DEPRECATED QSqlError(const QString &driverText, const QString &databaseText, + ErrorType type, int number); #endif - QSqlError(const QString &driverText, - const QString &databaseText, - ErrorType type, - const QString &errorCode); + QSqlError(const QString &driverText = QString(), + const QString &databaseText = QString(), + ErrorType type = NoError, + const QString &errorCode = QString()); QSqlError(const QSqlError& other); QSqlError& operator=(const QSqlError& other); bool operator==(const QSqlError& other) const; @@ -79,7 +77,7 @@ public: QString databaseText() const; ErrorType type() const; #if QT_DEPRECATED_SINCE(5, 3) - int number() const; + QT_DEPRECATED int number() const; #endif QString nativeErrorCode() const; QString text() const; |