Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.4.1
-
9483fcd68 (dev), bfea12b88 (6.5)
Description
Not sure if this is a bug, but it is certainly a behavior change from Qt 5.
A pointer to a class can fail to be queued with AutoConnection with following message:
qt.core.qobject.connect: QObject::connect: Cannot queue arguments of type 'MyType*' (Make sure 'MyType*' is registered using qRegisterMetaType().)
If QueuedConnection is used in the connect() statement, then the signal parameters are apparently registered within the connect() statement automatically through QtPrivate::ConnectionTypes<typename SignalType::Arguments>::types();.
Alternatively if the MyType header is included with Q_MOC_INCLUDE or there is a call to qRegisterMetaType for it, it also works with AutoConnection.
Attachments
For Gerrit Dashboard: QTBUG-108537 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
443558,7 | WIP: Add preliminary support for pointers to incomplete types in queued connect | dev | qt/qtbase | Status: NEW | -2 | 0 |
460426,1 | QObject: Handle pointers to incomplete types in auto-connections | 6.4 | qt/qtbase | Status: NEW | +2 | 0 |
460427,1 | QObject: Handle pointers to incomplete types in auto-connections | tqtc/lts-6.2 | qt/tqtc-qtbase | Status: NEW | +2 | 0 |
443488,13 | WIP: Pass QMetaTypesInterfaces instead of ids | dev | qt/qtbase | Status: DEFERRED | -2 | 0 |
460186,3 | QObject: Handle pointers to incomplete types in auto-connections | dev | qt/qtbase | Status: MERGED | +2 | 0 |
460425,2 | QObject: Handle pointers to incomplete types in auto-connections | 6.5 | qt/qtbase | Status: MERGED | +2 | 0 |