diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-30 12:27:05 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-30 15:24:36 +0200 |
commit | 015017884737eba31a5b0bc41032d0abbc3311b9 (patch) | |
tree | 58fcaf9f84311a22d915cfc7adee6b19849418b8 /src/quick/items/qquickshadereffect.cpp | |
parent | e9f35ec19b18ffdac76527a1bc0476d70522a75f (diff) |
Use QQmlContext::resolvedUrl in places where it was not added
Fixes: QTBUG-85063
Change-Id: Id96fe228a840de0f4760474db8bd9b1031640b50
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/quick/items/qquickshadereffect.cpp')
-rw-r--r-- | src/quick/items/qquickshadereffect.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/quick/items/qquickshadereffect.cpp b/src/quick/items/qquickshadereffect.cpp index df900d1f5e..7210a02e1c 100644 --- a/src/quick/items/qquickshadereffect.cpp +++ b/src/quick/items/qquickshadereffect.cpp @@ -45,7 +45,6 @@ #include <private/qquickwindow_p.h> #include <private/qquickitem_p.h> #include "qquickshadereffectmesh_p.h" -#include <QQmlAbstractUrlInterceptor> QT_BEGIN_NAMESPACE @@ -1209,9 +1208,8 @@ bool QQuickShaderEffectImpl::updateShader(Shader shaderType, const QUrl &src) const QSGGuiThreadShaderEffectManager::ShaderInfo::Type typeHint = shaderType == Vertex ? QSGGuiThreadShaderEffectManager::ShaderInfo::TypeVertex : QSGGuiThreadShaderEffectManager::ShaderInfo::TypeFragment; - QUrl loadUrl = src; - if (const QQmlEngine *engine = qmlEngine(m_item)) - loadUrl = engine->interceptUrl(loadUrl, QQmlAbstractUrlInterceptor::UrlString); + const QQmlContext *context = qmlContext(m_item); + const QUrl loadUrl = context ? context->resolvedUrl(src) : src; // Figure out what input parameters and variables are used in the // shader. This is where the data is pulled in from the file. // (however, if there is compilation involved, that happens at a |