diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2019-06-26 17:41:59 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2019-06-29 16:10:01 +0200 |
commit | a27e7e815175bc9417aaf7377b349109afd235e4 (patch) | |
tree | 134be19ba25aca210711de855d88f4c2d1b73e1f /tests/auto/corelib/kernel/qobject/tst_qobject.cpp | |
parent | 56962604254a31d5d54ea41044a5c251ff27fa0c (diff) |
QObject: deprecate the undocumented userData() feature
... and schedule it for removal in Qt 6.
This appears to have come to some fame on the internet, so better add
a deprecation warning before we remove it in Qt 6.
Change-Id: I42d91d933f47dfd2d8d54c92358e9e46ced6bf21
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests/auto/corelib/kernel/qobject/tst_qobject.cpp')
-rw-r--r-- | tests/auto/corelib/kernel/qobject/tst_qobject.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp index 7c9d8a476a..1778bf24bc 100644 --- a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp +++ b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp @@ -81,7 +81,9 @@ private slots: void senderTest(); void declareInterface(); void qpointerResetBeforeDestroyedSignal(); +#ifndef QT_NO_USERDATA void testUserData(); +#endif void childDeletesItsSibling(); void dynamicProperties(); void floatProperty(); @@ -2338,6 +2340,7 @@ void tst_QObject::declareInterface() } +#ifndef QT_NO_USERDATA class CustomData : public QObjectUserData { public: @@ -2380,6 +2383,7 @@ void tst_QObject::testUserData() QCOMPARE(data->id, id); } } +#endif // QT_NO_USERDATA class DestroyedListener : public QObject { |