aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMaximilian Goldstein <max.goldstein@qt.io>2021-02-08 13:42:44 +0100
committerMaximilian Goldstein <max.goldstein@qt.io>2021-02-08 13:50:45 +0100
commit053626d9db6aa6054df12d0ecb59bcaad8a16253 (patch)
tree95b15d7003e70ae489ecf9d9ec3ece51a5a5d379 /src
parentf0a51eef5696782ec325b20f14cfe353d0a58d20 (diff)
qjsengine: Clarify to/fromScriptValue documentation
Fixes: QTBUG-89956 Change-Id: I96439433b1f172e933c6c56daae639be7e18b931 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/qml/jsapi/qjsengine.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qml/jsapi/qjsengine.cpp b/src/qml/jsapi/qjsengine.cpp
index 37b5306897..94b0628cd7 100644
--- a/src/qml/jsapi/qjsengine.cpp
+++ b/src/qml/jsapi/qjsengine.cpp
@@ -821,6 +821,7 @@ bool QJSEngine::convertV2(const QJSValue &value, int type, void *ptr)
/*! \fn template <typename T> QJSValue QJSEngine::toScriptValue(const T &value)
Creates a QJSValue with the given \a value.
+ This works with any type \c{T} that has a \c{QMetaType}.
\sa fromScriptValue()
*/
@@ -828,6 +829,7 @@ bool QJSEngine::convertV2(const QJSValue &value, int type, void *ptr)
/*! \fn template <typename T> T QJSEngine::fromScriptValue(const QJSValue &value)
Returns the given \a value converted to the template type \c{T}.
+ This works with any type \c{T} that has a \c{QMetaType}.
\sa toScriptValue()
*/