From fccbc89125852f9d8679f7ae8d201a67619f6066 Mon Sep 17 00:00:00 2001 From: Erik Verbruggen Date: Wed, 16 Nov 2016 14:29:32 +0100 Subject: QML: Add another specialization for QQmlPropertyCache::property QQmlListReference passes a QLatin1String in, which can behandled by the stringCache just fine. So if there is a cache entry, then this will skip toQString conversion. Change-Id: I13afe4f6e63d486b313ac58cbd86fb7f9e1a80f6 Reviewed-by: Simon Hausmann --- src/qml/qml/qqmlpropertycache.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/qml/qml/qqmlpropertycache.cpp') diff --git a/src/qml/qml/qqmlpropertycache.cpp b/src/qml/qml/qqmlpropertycache.cpp index 2610a807b5..a110dccee2 100644 --- a/src/qml/qml/qqmlpropertycache.cpp +++ b/src/qml/qml/qqmlpropertycache.cpp @@ -1096,6 +1096,13 @@ QQmlPropertyCache::property(QJSEngine *engine, QObject *obj, return qQmlPropertyCacheProperty(engine, obj, name, context, local); } +QQmlPropertyData * +QQmlPropertyCache::property(QJSEngine *engine, QObject *obj, const QLatin1String &name, + QQmlContextData *context, QQmlPropertyData &local) +{ + return qQmlPropertyCacheProperty(engine, obj, name, context, local); +} + // these two functions are copied from qmetaobject.cpp static inline const QMetaObjectPrivate *priv(const uint* data) { return reinterpret_cast(data); } -- cgit v1.2.3