Details
-
Suggestion
-
Resolution: Fixed
-
P2: Important
-
None
-
4f33440a6 (dev), c94e5c8af (6.5), 53f64f76f (6.4)
Description
In the final example at https://doc.qt.io/qt-6/qqmlengine.html#QML_SINGLETON, the QML_FOREIGN() struct sets QJSEngine::CppOwnership in the create() function.
qt_generate_foreign_qml_types() should have a flag to set QJSEngine::CppOwnership in the generated code.
Attachments
For Gerrit Dashboard: QTBUG-111169 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
460714,3 | Doc: How to combine custom singletons and qt_generate_foreign_qml_types | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
461030,2 | Doc: How to combine custom singletons and qt_generate_foreign_qml_types | 6.4 | qt/qtdeclarative | Status: MERGED | +2 | 0 |
461031,2 | Doc: How to combine custom singletons and qt_generate_foreign_qml_types | 6.5 | qt/qtdeclarative | Status: MERGED | +2 | 0 |