QmlJS: Cache some commonly used QML specific objects.

This commit is contained in:
Christian Kamm
2010-09-24 14:01:10 +02:00
parent bfd7fd464e
commit 6755edc351
2 changed files with 85 additions and 42 deletions

View File

@@ -649,6 +649,12 @@ public:
// QML objects
const ObjectValue *qmlKeysObject();
const ObjectValue *qmlFontObject();
const ObjectValue *qmlPointObject();
const ObjectValue *qmlSizeObject();
const ObjectValue *qmlRectObject();
const ObjectValue *qmlVector3DObject();
const Value *defaultValueForBuiltinType(const QString &typeName) const;
// global object
@@ -720,6 +726,11 @@ private:
ObjectValue *_mathObject;
ObjectValue *_qtObject;
ObjectValue *_qmlKeysObject;
ObjectValue *_qmlFontObject;
ObjectValue *_qmlPointObject;
ObjectValue *_qmlSizeObject;
ObjectValue *_qmlRectObject;
ObjectValue *_qmlVector3DObject;
NullValue _nullValue;
UndefinedValue _undefinedValue;