diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2016-11-15 14:44:21 +0100 |
---|---|---|
committer | Erik Verbruggen <erik.verbruggen@qt.io> | 2016-11-16 09:01:25 +0000 |
commit | 12b7e6bfe5a8fb7666a929090483921c3f99ae8a (patch) | |
tree | 29eee12f334a9ed21c0db19e447018d88cf448a7 /tests/benchmarks | |
parent | 4ef8b7e7a8a93b2921560db8cf021f89409154e5 (diff) |
Fix reading of enum properties from gadgets
QMetaProperty::type() maps an un-registered enum to QMetaType::Int, and
so if a property cache is created for a gadget with enum properties,
then their type will be int and we'll correctly read enum properties as
ints in JavaScript. However if the enum is registered at the time we
create the cache, then the property type will be the specific type and
not QMetaType::Int. The property reading code in QV4::QObjectWrapper can
deal with that, but the property reading code in the gadget value type
wrapper code did not.
[ChangeLog][Qt][Qml] Fix reading of enum properties from gadgets / value
types when the enum was registered with qRegisterMetaType().
Change-Id: I7812b216a276dcc95c36e313507e1a1142250d0b
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Diffstat (limited to 'tests/benchmarks')
0 files changed, 0 insertions, 0 deletions