diff options
| author | Topi Reinio <topi.reinio@qt.io> | 2021-05-31 13:30:25 +0200 |
|---|---|---|
| committer | Topi Reinio <topi.reinio@qt.io> | 2021-06-02 10:18:03 +0200 |
| commit | 124fc2ad5edda30e29736365b5a1f6930aa2e1c4 (patch) | |
| tree | b8c5191a37a9ac9df815d69129ae741c2cdba468 /src/qml/jsapi/qjsengine.cpp | |
| parent | 60a833f309d5a9fe97329aeca1d6c7ae5e4ebe93 (diff) | |
Doc: Fix documentation issues
* Comment out \instantiates referring to an internal class
* Remove duplicate module page for Qt QML
* Fix various linking problems
Task-number: QTBUG-91875
Change-Id: I7675f8a253e0b0e0a031d8a3642b3d2786b75149
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'src/qml/jsapi/qjsengine.cpp')
| -rw-r--r-- | src/qml/jsapi/qjsengine.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/qml/jsapi/qjsengine.cpp b/src/qml/jsapi/qjsengine.cpp index 7e8effda45..ed282f5a61 100644 --- a/src/qml/jsapi/qjsengine.cpp +++ b/src/qml/jsapi/qjsengine.cpp @@ -619,7 +619,7 @@ QJSValue QJSEngine::importModule(const QString &fileName) } /*! - Register a QJSValue to serve as a module. After this function is called, + Registers a QJSValue to serve as a module. After this function is called, all modules that import \a moduleName will import the value of \a value instead of loading \a moduleName from the filesystem. @@ -630,14 +630,16 @@ QJSValue QJSEngine::importModule(const QString &fileName) Because this allows modules that do not exist on the filesystem to be imported, scripting applications can use this to provide built-in modules, similar to - Node.js + Node.js. + + Returns \c true on success, \c false otherwise. \note The QJSValue \a value is not called or read until it is used by another module. This means that there is no code to evaluate, so no errors will be seen until another module throws an exception while trying to load this module. \warning Attempting to access a named export from a QJSValue that is not an - object will trigger a \l{Script Exception}{exception}. + object will trigger a \l{Script Exceptions}{exception}. \sa importModule() */ @@ -671,7 +673,7 @@ QJSValue QJSEngine::newObject() The prototype of the created object will be the Symbol prototype object. - \sa newString() + \sa newObject() */ QJSValue QJSEngine::newSymbol(const QString &name) { |
