aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlimport_p.h
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2019-12-29 20:15:19 +0100
committerUlf Hermann <ulf.hermann@qt.io>2020-01-02 09:58:14 +0100
commit024186e7d428bcd8823cf77bd51682669d73533d (patch)
tree5806ef219de191d0d001104bc793bbfc3d48765c /src/qml/qml/qqmlimport_p.h
parent289c0fdc2cafd79e3178a9cd3cfc6c5bd53c8336 (diff)
Defer loading of local qmldir files when intercepted to remote ones
The qqmltypeloader test checks this case. As long as the types are actually loaded by the plugin it worked as we didn't register the module before. When the types are loaded by static type registrations in QtQuick we need to detect whether we still need to wait for a remote qmldir file to appear in order to load color providers etc. Change-Id: I7aa10903c6c23d1c9be01ee7ddafbdc696975407 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlimport_p.h')
-rw-r--r--src/qml/qml/qqmlimport_p.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/qml/qml/qqmlimport_p.h b/src/qml/qml/qqmlimport_p.h
index 7cf1ae61b9..1f44b22deb 100644
--- a/src/qml/qml/qqmlimport_p.h
+++ b/src/qml/qml/qqmlimport_p.h
@@ -163,9 +163,15 @@ public:
const QString &uri, const QString &prefix,
const QString &qmldirIdentifier, const QString &qmldirUrl, QList<QQmlError> *errors);
- bool locateQmldir(QQmlImportDatabase *,
- const QString &uri, int vmaj, int vmin,
- QString *qmldirFilePath, QString *url);
+ enum LocalQmldirResult {
+ QmldirFound,
+ QmldirNotFound,
+ QmldirInterceptedToRemote
+ };
+
+ LocalQmldirResult locateLocalQmldir(
+ QQmlImportDatabase *, const QString &uri, int vmaj, int vmin,
+ QString *qmldirFilePath, QString *url);
void populateCache(QQmlTypeNameCache *cache) const;