diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2021-06-28 11:04:40 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2021-06-29 11:23:22 +0200 |
commit | dbca762f45d3249974652cccb5d6421440f852ae (patch) | |
tree | 3902396c69c87a9c2a5b8b9abbf90fb51a998915 /src/qml/qml/qqmlengine.cpp | |
parent | 6c01e17a30531fcaeb44459978d6ba8a56aa225a (diff) |
QtQml: Move locateLocalQmldir and make it a template
It conceptually belongs into QQmlImportDatabase because it messes with
the qmldir cache.
This way, if we reject a qmldir file for whatever reason, we can still
check for further matching qmldir files in other places. We might, for
example determine that we need to load a plugin, but we have been given
a qmldir file in the resource file system. In that case, we want to
check for other instances of the same module in the host file system.
Pick-to: 6.2
Change-Id: I8fe4a0f188f3732b9d10d017a94562e8bd1fb242
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlengine.cpp')
-rw-r--r-- | src/qml/qml/qqmlengine.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp index 0cf705f7bb..86f27ed3d5 100644 --- a/src/qml/qml/qqmlengine.cpp +++ b/src/qml/qml/qqmlengine.cpp @@ -1081,6 +1081,15 @@ QUrl QQmlEngine::interceptUrl(const QUrl &url, QQmlAbstractUrlInterceptor::DataT return result; } +/*! + Returns the list of currently active URL interceptors. + */ +QList<QQmlAbstractUrlInterceptor *> QQmlEngine::urlInterceptors() const +{ + Q_D(const QQmlEngine); + return d->urlInterceptors; +} + void QQmlEnginePrivate::registerFinalizeCallback(QObject *obj, int index) { if (activeObjectCreator) { |