From 4bf5f4bd948825c4e9c031adfdffaf1a7166470a Mon Sep 17 00:00:00 2001 From: Christian Kamm <christian.d.kamm@nokia.com> Date: Thu, 23 Jun 2011 13:32:00 +0200 Subject: [PATCH] QmlJS: Respect the REVISION property for methods and properties. Task-number: QTCREATORBUG-3907 Change-Id: Ic2c1f8cafe381e5216ae7ad73502ca0fae20dda0 Reviewed-on: http://codereview.qt.nokia.com/656 Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com> --- src/libs/qmljs/qmljsinterpreter.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/libs/qmljs/qmljsinterpreter.cpp b/src/libs/qmljs/qmljsinterpreter.cpp index be500a0ae5c..4fcfc49247f 100644 --- a/src/libs/qmljs/qmljsinterpreter.cpp +++ b/src/libs/qmljs/qmljsinterpreter.cpp @@ -194,7 +194,10 @@ void QmlObjectValue::processMembers(MemberProcessor *processor) const // process the meta methods for (int index = 0; index < _metaObject->methodCount(); ++index) { - FakeMetaMethod method = _metaObject->method(index); + const FakeMetaMethod method = _metaObject->method(index); + if (_componentVersion.isValid() && _componentVersion.minorVersion() < method.revision()) + continue; + QString methodName; const Value *signature = findOrCreateSignature(index, method, &methodName); @@ -217,7 +220,9 @@ void QmlObjectValue::processMembers(MemberProcessor *processor) const // process the meta properties for (int index = 0; index < _metaObject->propertyCount(); ++index) { - FakeMetaProperty prop = _metaObject->property(index); + const FakeMetaProperty prop = _metaObject->property(index); + if (_componentVersion.isValid() && _componentVersion.minorVersion() < prop.revision()) + continue; const QString propertyName = prop.name(); processor->processProperty(propertyName, propertyValue(prop)); -- GitLab