aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/doc/snippets
diff options
context:
space:
mode:
authorAndrei Golubev <andrei.golubev@qt.io>2021-11-19 13:04:05 +0100
committerAndrei Golubev <andrei.golubev@qt.io>2022-03-30 11:00:24 +0200
commiteb64978d115445b2aecf280a64b4433c69913322 (patch)
treecc126f54ce8ba84bfad4b7348f78ecae593561f8 /src/qml/doc/snippets
parentfdb45a0e2eb5d1963bd2ee9a7f6ebd49f7dfc9ca (diff)
qmltc: Migrate to new object creation/querying mechanism
Serves two things: a) Provides faster/more correct object creation model (long-term) b) Eliminates (more of) prototype's code generation (short-term) The whole object querying now works implicitly through the std::array<QObject *> that QQmltcObjectCreationBase provides. The creation logic is still rather recursive with regards to QML base types processing - unfortunately, we cannot simplify this part now as qmltc requires deeper introspection into the imported types (this in turn requires fiddling with QQmlJSTypeReader and QDeferredFactory<QQmlJSScope>::create()) Since we now use the new object creation pattern, prototype/codegenerator no longer needs high-level compilation methods. So replace prototype's code accordingly with qmltccompiler bits. We can also de-duplicate enum and property compilation (aliases are not touched for simplification) from prototype. Methods and bindings have to rely on prototype and QmlIR at present, their compilation is moved more-or-less unchanged Task-number: QTBUG-84368 Change-Id: I584ceb8f2e3c9f3f79530b02d1c88a4f6c2d06c9 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/qml/doc/snippets')
-rw-r--r--src/qml/doc/snippets/qmltc/special/HelloWorld.qml.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/doc/snippets/qmltc/special/HelloWorld.qml.cpp b/src/qml/doc/snippets/qmltc/special/HelloWorld.qml.cpp
index 122084f1d8..0e125a1926 100644
--- a/src/qml/doc/snippets/qmltc/special/HelloWorld.qml.cpp
+++ b/src/qml/doc/snippets/qmltc/special/HelloWorld.qml.cpp
@@ -69,7 +69,7 @@ class HelloWorld : public QObject
Q_PROPERTY(QString hello WRITE setHello READ hello BINDABLE bindableHello)
public:
- HelloWorld(QQmlEngine * engine, QObject * parent = nullptr);
+ HelloWorld(QQmlEngine* engine, QObject* parent = nullptr);
Q_SIGNALS:
void created();