diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-09-03 00:14:54 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-09-03 00:14:54 (GMT) |
commit | b9c834048d6dc6e04567c1c73212ecb1b9c96664 (patch) | |
tree | 223b1d3d101883dabadadbf68b020808de56399e /src/declarative/qml/qmlcompiler.cpp | |
parent | dc26066be54bed3d508b460db1cc8d8b4b68cc1f (diff) | |
download | Qt-b9c834048d6dc6e04567c1c73212ecb1b9c96664.zip Qt-b9c834048d6dc6e04567c1c73212ecb1b9c96664.tar.gz Qt-b9c834048d6dc6e04567c1c73212ecb1b9c96664.tar.bz2 |
Add QML enum support
Enums are accessed as <Type Name>.<Enum value name>
Currently this is highly unoptimal - enum assignments are not detected
in the compiler, nor are they cached in the script engine.
Diffstat (limited to 'src/declarative/qml/qmlcompiler.cpp')
-rw-r--r-- | src/declarative/qml/qmlcompiler.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/declarative/qml/qmlcompiler.cpp b/src/declarative/qml/qmlcompiler.cpp index c0f7bfd..6519dff 100644 --- a/src/declarative/qml/qmlcompiler.cpp +++ b/src/declarative/qml/qmlcompiler.cpp @@ -642,6 +642,8 @@ void QmlCompiler::compileTree(Object *tree) def.type = QmlInstruction::SetDefault; output->bytecode << def; + output->imports = unit->imports; + if (tree->metatype) static_cast<QMetaObject &>(output->root) = *tree->metaObject(); else |