diff options
author | Olivier Goffart <ogoffart@woboq.com> | 2019-12-03 20:24:38 +0100 |
---|---|---|
committer | Olivier Goffart <ogoffart@woboq.com> | 2020-01-17 11:31:35 +0100 |
commit | c6899f16389458766904d8d913054f09076e06dd (patch) | |
tree | e24f942a01720775391ae04557e24a35839f7361 /src/quick/scenegraph | |
parent | 9e674be4fb8c369873a009f58e3152a12d2c4cce (diff) |
Replace QVariant::type with QVariant::userType
as type is going to be deprecated.
This change was done automatically with the help of clazy.
In addition, ColumnRoleMetadata was changed to take an int instead
of a QVariant::Type
Change-Id: Ibc02d7b52e7d931a56c19fdebc4788b5e6df2a39
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/quick/scenegraph')
-rw-r--r-- | src/quick/scenegraph/qsgrhishadereffectnode.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/quick/scenegraph/qsgrhishadereffectnode.cpp b/src/quick/scenegraph/qsgrhishadereffectnode.cpp index 6f6544548c..e86dae7c09 100644 --- a/src/quick/scenegraph/qsgrhishadereffectnode.cpp +++ b/src/quick/scenegraph/qsgrhishadereffectnode.cpp @@ -136,7 +136,7 @@ void QSGRhiShaderLinker::linkTextureSubRects() // texture binding point. for (Constant &c : m_constants) { if (c.specialType == QSGShaderEffectNode::VariableData::SubRect) { - if (c.value.type() == QVariant::ByteArray) { + if (c.value.userType() == QMetaType::QByteArray) { const QByteArray name = c.value.toByteArray(); if (!m_samplerNameMap.contains(name)) qWarning("ShaderEffect: qt_SubRect_%s refers to unknown source texture", name.constData()); @@ -270,7 +270,7 @@ bool QSGRhiShaderEffectMaterialShader::updateUniformData(RenderState &state, QSG memcpy(dst, f, sizeof(f)); } else if (c.specialType == QSGShaderEffectNode::VariableData::None) { changed = true; - switch (int(c.value.type())) { + switch (int(c.value.userType())) { case QMetaType::QColor: { const QColor v = qsg_premultiply_color(qvariant_cast<QColor>(c.value)); const float f[4] = { float(v.redF()), float(v.greenF()), float(v.blueF()), float(v.alphaF()) }; |