aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlvaluetypewrapper_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/qml/qml/qqmlvaluetypewrapper_p.h')
-rw-r--r--src/qml/qml/qqmlvaluetypewrapper_p.h23
1 files changed, 13 insertions, 10 deletions
diff --git a/src/qml/qml/qqmlvaluetypewrapper_p.h b/src/qml/qml/qqmlvaluetypewrapper_p.h
index 60079aa623..0a6d073478 100644
--- a/src/qml/qml/qqmlvaluetypewrapper_p.h
+++ b/src/qml/qml/qqmlvaluetypewrapper_p.h
@@ -70,15 +70,6 @@ struct QQmlValueTypeWrapper : Object {
void init() { Object::init(); }
void destroy();
- QQmlPropertyCache *propertyCache() const { return m_propertyCache; }
- void setPropertyCache(QQmlPropertyCache *c) {
- if (c)
- c->addref();
- if (m_propertyCache)
- m_propertyCache->release();
- m_propertyCache = c;
- }
-
void setValueType(QQmlValueType *valueType)
{
Q_ASSERT(valueType != nullptr);
@@ -101,13 +92,23 @@ struct QQmlValueTypeWrapper : Object {
return m_gadgetPtr;
}
+ void setMetaObject(const QMetaObject *metaObject)
+ {
+ m_metaObject = metaObject;
+ }
+ const QMetaObject *metaObject() const
+ {
+ return m_metaObject;
+ }
+
+
void setValue(const QVariant &value) const;
QVariant toVariant() const;
private:
mutable void *m_gadgetPtr;
QQmlValueType *m_valueType;
- QQmlPropertyCache *m_propertyCache;
+ const QMetaObject *m_metaObject;
};
}
@@ -129,6 +130,8 @@ public:
int typeId() const;
bool write(QObject *target, int propertyIndex) const;
+ QQmlPropertyData dataForPropertyKey(PropertyKey id) const;
+
static ReturnedValue virtualGet(const Managed *m, PropertyKey id, const Value *receiver, bool *hasProperty);
static bool virtualPut(Managed *m, PropertyKey id, const Value &value, Value *receiver);
static bool virtualIsEqualTo(Managed *m, Managed *other);