diff options
author | Mitch Curtis <mitch.curtis@qt.io> | 2021-04-27 14:20:35 +0200 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-04-27 15:06:18 +0000 |
commit | 7147b54e3eba3089db825b91b74513205974e7df (patch) | |
tree | 4673ed79cf5c011a10daaf4a80ce9dbc00520665 | |
parent | 2574c0cba6a243b90c161b4e91c91cfa15502e98 (diff) |
Document QQmlComponent::createWithInitialProperties() error handling
Unlike create(), it can produce errors that should be checked.
Change-Id: I78f2e58c8666eb45f6e850c43e3e97a448b2758e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit 4f0622f7f553cd841874f0efe65d7f13edeec216)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r-- | src/qml/qml/qqmlcomponent.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlcomponent.cpp b/src/qml/qml/qqmlcomponent.cpp index b44ad83b6e..18273ddcc0 100644 --- a/src/qml/qml/qqmlcomponent.cpp +++ b/src/qml/qml/qqmlcomponent.cpp @@ -839,6 +839,14 @@ QObject *QQmlComponent::create(QQmlContext *context) properties with \a initialProperties. \a context specifies the context where the object instance is to be created. + \omit + TODO: also mention errorString() when QTBUG-93239 is fixed + \endomit + + If any of the \c initialProperties cannot be set, \l isError() will return + \c true, and the \l errors() function can be used to + get detailed information about the error(s). + \sa QQmlComponent::create \since 5.14 */ |