diff options
author | Laszlo Agocs <laszlo.agocs@theqtcompany.com> | 2016-03-08 16:26:38 +0100 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@theqtcompany.com> | 2016-03-09 11:28:30 +0000 |
commit | daa0e2e6b1d9efce6569203ee4889d4707a9abd0 (patch) | |
tree | 0158ac160a090b94c5d725f82d1f7947210148a3 /tests/auto/quick/geometry | |
parent | 75423185e4b03fabfeeee403f3bd9a6063078ee6 (diff) |
Fix shadowing and rvalue warnings
The tests attempt to initialize the struct members directly is invalid
in any case. The static create() functions are mandatory since new members
may be added (via the reserved bits) at any time.
Also expand the Attribute struct spec to keep VS2012 happy (this can be
reverted later once it's gone from CI).
Change-Id: Ibec1fdb8e2787c3665ec397b6adb906210d570e4
Reviewed-by: Andy Nichols <andy.nichols@theqtcompany.com>
Diffstat (limited to 'tests/auto/quick/geometry')
-rw-r--r-- | tests/auto/quick/geometry/tst_geometry.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/auto/quick/geometry/tst_geometry.cpp b/tests/auto/quick/geometry/tst_geometry.cpp index 8755e3a1d7..7988b6b515 100644 --- a/tests/auto/quick/geometry/tst_geometry.cpp +++ b/tests/auto/quick/geometry/tst_geometry.cpp @@ -126,9 +126,9 @@ void GeometryTest::testCustomGeometry() }; static QSGGeometry::Attribute attributes[] = { - { 0, 2, GL_FLOAT, 0, 0}, - { 1, 4, GL_UNSIGNED_BYTE, 0, 0}, - { 2, 4, GL_FLOAT, 0, 0}, + QSGGeometry::Attribute::create(0, 2, GL_FLOAT, false), + QSGGeometry::Attribute::create(1, 4, GL_UNSIGNED_BYTE, false), + QSGGeometry::Attribute::create(2, 4, GL_FLOAT, false) }; static QSGGeometry::AttributeSet set = { 4, 6 * sizeof(float) + 4 * sizeof(unsigned char), attributes }; |