diff options
author | Lars Knoll <lars.knoll@digia.com> | 2013-12-16 09:16:57 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-01-09 07:47:06 +0100 |
commit | 459c9a2a8840995436e610459216957bc7ebd914 (patch) | |
tree | ef28df2fdbc62bf551088d13850492d2c6a771b1 /src/quick | |
parent | 5cf95512af83fc6a0f70d3493be571accaf50d84 (diff) |
Rework array handling for JS objects
Split up ArrayData into two classes, one for regular
arrays, one for sparse arrays and cleanly separate
the two cases. Only create array data on demand.
Change-Id: I9ca8d0b53592174f213ba0f20caf93e77dba690a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/quick')
-rw-r--r-- | src/quick/items/context2d/qquickcontext2d.cpp | 2 | ||||
-rw-r--r-- | src/quick/util/qquickglobal.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/quick/items/context2d/qquickcontext2d.cpp b/src/quick/items/context2d/qquickcontext2d.cpp index b6d4f1073c..c8741335dd 100644 --- a/src/quick/items/context2d/qquickcontext2d.cpp +++ b/src/quick/items/context2d/qquickcontext2d.cpp @@ -871,7 +871,7 @@ struct QQuickJSContext2DPixelData : public QV4::Object : QV4::Object(engine) { setVTable(&static_vtbl); - flags &= ~SimpleArray; + setArrayType(QV4::ArrayData::Custom); } static void destroy(QV4::Managed *that) { diff --git a/src/quick/util/qquickglobal.cpp b/src/quick/util/qquickglobal.cpp index 152d1f34c9..5ae74c2fec 100644 --- a/src/quick/util/qquickglobal.cpp +++ b/src/quick/util/qquickglobal.cpp @@ -398,7 +398,7 @@ public: if (!array) return QMatrix4x4(); - if (array->arrayLength() != 16) + if (array->getLength() != 16) return QMatrix4x4(); float matVals[16]; |