forked from qt-creator/qt-creator
QmlDesigner: Fix attached properties call
Accessible.role for example was not found. Change-Id: Ibd2f47d43705d5d450e572cbb9c786c75f7912b3 Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
This commit is contained in:
committed by
Thomas Hartmann
parent
73bcbdfcef
commit
b00a7f0311
@@ -199,7 +199,8 @@ NodeInstanceMetaObject::~NodeInstanceMetaObject()
|
||||
|
||||
void NodeInstanceMetaObject::createNewProperty(const QString &name)
|
||||
{
|
||||
int id = createProperty(name.toUtf8(), 0);
|
||||
int id = m_type->createProperty(name.toUtf8());
|
||||
copyTypeMetaObject();
|
||||
setValue(id, QVariant());
|
||||
Q_ASSERT(id >= 0);
|
||||
Q_UNUSED(id);
|
||||
@@ -214,13 +215,6 @@ void NodeInstanceMetaObject::createNewProperty(const QString &name)
|
||||
Q_ASSERT(property.isValid());
|
||||
}
|
||||
|
||||
int NodeInstanceMetaObject::createProperty(const char *name, const char *)
|
||||
{
|
||||
int id = m_type->createProperty(name);
|
||||
copyTypeMetaObject();
|
||||
return id;
|
||||
}
|
||||
|
||||
void NodeInstanceMetaObject::setValue(int id, const QVariant &value)
|
||||
{
|
||||
QPair<QVariant, bool> &prop = m_data->getDataRef(id);
|
||||
|
@@ -63,7 +63,6 @@ protected:
|
||||
int metaCall(QMetaObject::Call _c, int _id, void **_a);
|
||||
void notifyPropertyChange(int id);
|
||||
void setValue(int id, const QVariant &value);
|
||||
int createProperty(const char *, const char *);
|
||||
QVariant propertyWriteValue(int, const QVariant &);
|
||||
|
||||
QObject *myObject() const { return QQmlVMEMetaObject::object; }
|
||||
|
Reference in New Issue
Block a user