You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Improve manual implementations of up- and downcasting (#1204)
* cxx-qt: use qobject_cast for downcastPtr
* cxx-qt-lib: implement Upcast<QVector<QPoint>> for QPolygon
* cxx-qt-lib: implement Upcast<QVector<QPointF>> for QPolygonF
* cxx-qt-lib: implement Deref for QQmlApplicationEngine
* cxx-qt-lib: remove null-pointer dereference from QStringList's downcast
* cxx-qt-lib: implement Upcast<QCoreApplication> for QGuiApplication
* cxx-qt-lib: implement Upcast<QGuiApplication> for QApplication
* Revert "cxx-qt-lib: implement Upcast<QGuiApplication> for QApplication"
This reverts commit 311ddd9.
* Revert "cxx-qt-lib: implement Upcast<QCoreApplication> for QGuiApplication"
This reverts commit 8e829ef.
* Revert "cxx-qt-lib: implement Deref for QQmlApplicationEngine"
This reverts commit b939a8d.
* cxx-qt: use qobject_cast for downcastPtr
* cxx-qt-lib: implement Upcast<QVector<QPoint>> for QPolygon
* cxx-qt-lib: implement Upcast<QVector<QPointF>> for QPolygonF
* cxx-qt-lib: remove null-pointer dereference from QStringList's downcast
* Improve downcast C++ implementations
Add detection whether to use qobject_cast or dynamic_cast via template
specialization.
Also add additional checks that a static_cast downcast is sane to do
(i.e. at least the size of the types must be the same).
---------
Co-authored-by: Leon Matthes <[email protected]>
0 commit comments