From d10325b34e012fb4f7ed1dcb884ec2d6bb4fcc81 Mon Sep 17 00:00:00 2001 From: Sean Harmer Date: Fri, 15 Aug 2014 09:59:20 +0100 Subject: [PATCH] Use new custom parser private api and switch to 5.4 branch Change-Id: Ie47ce5da4abe9027ca192fbc5c096df49e0eaff5 Reviewed-by: Paul Lemire --- .../items/shaderpropertyparser.cpp | 16 ++++++---------- .../quick3drenderer/items/shaderpropertyparser.h | 6 +++++- sync.profile | 6 +++--- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/quick3d/quick3drenderer/items/shaderpropertyparser.cpp b/src/quick3d/quick3drenderer/items/shaderpropertyparser.cpp index 9c7898079..d00f36925 100644 --- a/src/quick3d/quick3drenderer/items/shaderpropertyparser.cpp +++ b/src/quick3d/quick3drenderer/items/shaderpropertyparser.cpp @@ -54,14 +54,12 @@ ShaderPropertyParser::ShaderPropertyParser() { } -QByteArray ShaderPropertyParser::compile(const QV4::CompiledData::QmlUnit *qmlUnit, const QList &bindings) +void ShaderPropertyParser::verifyBindings(const QV4::CompiledData::Unit *qmlUnit, + const QList &bindings) { - QByteArray data; - - // TO DO : Complete below when a proper Uniform API is defined - + // TODO: Complete below when a proper Uniform API is defined Q_FOREACH (const QV4::CompiledData::Binding *binding, bindings) { - QString propertyName = qmlUnit->header.stringAt(binding->propertyNameIndex); + QString propertyName = qmlUnit->stringAt(binding->propertyNameIndex); qDebug() << Q_FUNC_INFO << "propertyName " << propertyName; if (binding->type == QV4::CompiledData::Binding::Type_Object) { @@ -86,13 +84,11 @@ QByteArray ShaderPropertyParser::compile(const QV4::CompiledData::QmlUnit *qmlUn qDebug() << Q_FUNC_INFO << "Script property"; } } - - return data; } -void ShaderPropertyParser::setCustomData(QObject *, const QByteArray &, QQmlCompiledData *) +void ShaderPropertyParser::applyBindings(QObject *, QQmlCompiledData *, const QList &) { - + // TODO: Implement me } } // Quick diff --git a/src/quick3d/quick3drenderer/items/shaderpropertyparser.h b/src/quick3d/quick3drenderer/items/shaderpropertyparser.h index 69c62c106..442ac0a02 100644 --- a/src/quick3d/quick3drenderer/items/shaderpropertyparser.h +++ b/src/quick3d/quick3drenderer/items/shaderpropertyparser.h @@ -44,6 +44,7 @@ #include #include +#include QT_BEGIN_NAMESPACE @@ -58,8 +59,11 @@ class QT3DQUICKRENDERERSHARED_EXPORT ShaderPropertyParser : public QQmlCustomPar public: ShaderPropertyParser(); - QByteArray compile(const QV4::CompiledData::QmlUnit *qmlUnit, const QList &bindings); + QByteArray compile(const QV4::CompiledData::Unit *qmlUnit, const QList &bindings); void setCustomData(QObject *, const QByteArray &, QQmlCompiledData *); + + void verifyBindings(const QV4::CompiledData::Unit *, const QList &) Q_DECL_OVERRIDE; + void applyBindings(QObject *, QQmlCompiledData *, const QList &) Q_DECL_OVERRIDE; }; } // Quick diff --git a/sync.profile b/sync.profile index 1cf5bbb76..aeee97f95 100644 --- a/sync.profile +++ b/sync.profile @@ -22,7 +22,7 @@ $publicclassregexp = "Qt3D::.+"; # - any git symbolic ref resolvable from the module's repository (e.g. "refs/heads/master" to track master branch) # %dependencies = ( - "qtbase" => "refs/heads/dev", - "qtxmlpatterns" => "refs/heads/dev", - "qtdeclarative" => "refs/heads/dev", + "qtbase" => "refs/heads/5.4", + "qtxmlpatterns" => "refs/heads/5.4", + "qtdeclarative" => "refs/heads/5.4", );