diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2022-08-02 18:20:18 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2022-08-29 13:20:53 +0200 |
commit | cad5c89a0f0ebb24f17171fdbab8355832f0f415 (patch) | |
tree | 1e49190e51018b27296858e5e4248f29b1965617 /src/qml/qml/qqmlcustomparser_p.h | |
parent | d937a53cbcd72304ba1c613ed2d2dc2010542f7e (diff) |
QmlModels: Fix enum resolution in ListElement
There were two problems:
a, We need to allow recursion when querying for enums. Otherwise we
cannot find enums in the same document.
b, when the enum resolution is done in the validation phase, we cannot
query the current document's QQmlType for enums, yet, as it's not
finalized. However, the QQmlPropertyValidator has the
QQmlPropertyCache we're looking for in that case.
c, As a drive-by, fix the excessive conversions between QByteArray and
QString.
Pick-to: 6.4
Fixes: QTBUG-95864
Change-Id: If0d2687986e1483a27ce11373a204235b92a6efd
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlcustomparser_p.h')
-rw-r--r-- | src/qml/qml/qqmlcustomparser_p.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlcustomparser_p.h b/src/qml/qml/qqmlcustomparser_p.h index afb5b810c2..98a9f21ae9 100644 --- a/src/qml/qml/qqmlcustomparser_p.h +++ b/src/qml/qml/qqmlcustomparser_p.h @@ -56,7 +56,7 @@ protected: { error(object->location, description); } void error(const QV4::CompiledData::Location &location, const QString& description); - int evaluateEnum(const QByteArray&, bool *ok) const; + int evaluateEnum(const QString &, bool *ok) const; const QMetaObject *resolveType(const QString&) const; |