diff options
author | Bea Lam <bea.lam@nokia.com> | 2010-02-03 00:01:13 (GMT) |
---|---|---|
committer | Bea Lam <bea.lam@nokia.com> | 2010-02-03 00:04:03 (GMT) |
commit | 17d0ed5af4922645a268b6550742fb521d459c8e (patch) | |
tree | 43f4077630bd896da88715dec894392c63ac666b /tests/auto/declarative/qmlecmascript/data | |
parent | 35a211cd95e0d09ef0b547b57f01f0a9ff41da2f (diff) | |
download | Qt-17d0ed5af4922645a268b6550742fb521d459c8e.zip Qt-17d0ed5af4922645a268b6550742fb521d459c8e.tar.gz Qt-17d0ed5af4922645a268b6550742fb521d459c8e.tar.bz2 |
Disallow ids that start with uppercase letters and update docs and
examples accordingly.
Task-number: QT-2786
Diffstat (limited to 'tests/auto/declarative/qmlecmascript/data')
14 files changed, 48 insertions, 53 deletions
diff --git a/tests/auto/declarative/qmlecmascript/data/aliasPropertyAndBinding.qml b/tests/auto/declarative/qmlecmascript/data/aliasPropertyAndBinding.qml index 7fdd8ca..5c3ea1f 100644 --- a/tests/auto/declarative/qmlecmascript/data/aliasPropertyAndBinding.qml +++ b/tests/auto/declarative/qmlecmascript/data/aliasPropertyAndBinding.qml @@ -2,11 +2,11 @@ import Qt 4.6 import Qt.test 1.0 MyQmlObject { - property alias c1: MyObject.c1 + property alias c1: myObject.c1 property int c2: 3 property int c3: c2 objectProperty: QtObject { - id: MyObject + id: myObject property int c1 } } diff --git a/tests/auto/declarative/qmlecmascript/data/attachedProperty.qml b/tests/auto/declarative/qmlecmascript/data/attachedProperty.qml index c5088e3..061eda0 100644 --- a/tests/auto/declarative/qmlecmascript/data/attachedProperty.qml +++ b/tests/auto/declarative/qmlecmascript/data/attachedProperty.qml @@ -2,10 +2,10 @@ import Qt.test 1.0 import Qt.test 1.0 as Namespace MyQmlObject { - id: Me + id: me property int a: MyQmlObject.value property int b: Namespace.MyQmlObject.value - property int c: Me.Namespace.MyQmlObject.value - property int d: Me.Namespace.MyQmlObject.value + property int c: me.Namespace.MyQmlObject.value + property int d: me.Namespace.MyQmlObject.value } diff --git a/tests/auto/declarative/qmlecmascript/data/bindingLoop.qml b/tests/auto/declarative/qmlecmascript/data/bindingLoop.qml index 8b22dd1..80545cf 100644 --- a/tests/auto/declarative/qmlecmascript/data/bindingLoop.qml +++ b/tests/auto/declarative/qmlecmascript/data/bindingLoop.qml @@ -3,12 +3,12 @@ import Qt.test 1.0 MyQmlContainer { children : [ MyQmlObject { - id: Object1 - stringProperty: "hello" + Object2.stringProperty + id: object1 + stringProperty: "hello" + object2.stringProperty }, MyQmlObject { - id: Object2 - stringProperty: "hello" + Object1.stringProperty + id: object2 + stringProperty: "hello" + object1.stringProperty } ] } diff --git a/tests/auto/declarative/qmlecmascript/data/constantsOverrideBindings.2.qml b/tests/auto/declarative/qmlecmascript/data/constantsOverrideBindings.2.qml index d205526..207a06b 100644 --- a/tests/auto/declarative/qmlecmascript/data/constantsOverrideBindings.2.qml +++ b/tests/auto/declarative/qmlecmascript/data/constantsOverrideBindings.2.qml @@ -1,11 +1,11 @@ import Qt.test 1.0 MyQmlObject { - property alias c1: MyConstants.c1 - property alias c2: MyConstants.c2 + property alias c1: myConstants.c1 + property alias c2: myConstants.c2 objectProperty: ConstantsOverrideBindings { - id: MyConstants + id: myConstants c2: 10 } } diff --git a/tests/auto/declarative/qmlecmascript/data/dynamicCreation.helper.qml b/tests/auto/declarative/qmlecmascript/data/dynamicCreation.helper.qml deleted file mode 100644 index b26d6e1..0000000 --- a/tests/auto/declarative/qmlecmascript/data/dynamicCreation.helper.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt.test 1.0 - -MyQmlObject{ - objectName: "objectTwo" -} diff --git a/tests/auto/declarative/qmlecmascript/data/extendedObjectPropertyLookup.qml b/tests/auto/declarative/qmlecmascript/data/extendedObjectPropertyLookup.qml index ab379c1..9a82ad1 100644 --- a/tests/auto/declarative/qmlecmascript/data/extendedObjectPropertyLookup.qml +++ b/tests/auto/declarative/qmlecmascript/data/extendedObjectPropertyLookup.qml @@ -3,6 +3,6 @@ import Qt 4.6 QtObject { property MyExtendedObject a; - a: MyExtendedObject { id: Root } - property int b: Math.max(Root.extendedProperty, 0) + a: MyExtendedObject { id: root } + property int b: Math.max(root.extendedProperty, 0) } diff --git a/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.1.qml b/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.1.qml index b377b94..2db0fc6 100644 --- a/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.1.qml +++ b/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.1.qml @@ -2,12 +2,12 @@ import Qt.test 1.0 import Qt 4.6 MyQmlObject { - objectProperty: if(1) OtherObject + objectProperty: if(1) otherObject property var obj obj: QtObject { - id: OtherObject + id: otherObject } } diff --git a/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.qml b/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.qml index 40cacf6..f66428d 100644 --- a/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.qml +++ b/tests/auto/declarative/qmlecmascript/data/idShortcutInvalidates.qml @@ -2,11 +2,11 @@ import Qt.test 1.0 import Qt 4.6 MyQmlObject { - objectProperty: OtherObject + objectProperty: otherObject property var obj obj: QtObject { - id: OtherObject + id: otherObject } } diff --git a/tests/auto/declarative/qmlecmascript/data/methods.1.qml b/tests/auto/declarative/qmlecmascript/data/methods.1.qml index 42ed9a5..0bbee16 100644 --- a/tests/auto/declarative/qmlecmascript/data/methods.1.qml +++ b/tests/auto/declarative/qmlecmascript/data/methods.1.qml @@ -1,6 +1,6 @@ import Qt.test 1.0 MyQmlObject { - id: MyObject - onBasicSignal: MyObject.methodNoArgs() + id: myObject + onBasicSignal: myObject.methodNoArgs() } diff --git a/tests/auto/declarative/qmlecmascript/data/methods.2.qml b/tests/auto/declarative/qmlecmascript/data/methods.2.qml index 70911f7..9f0c6b1 100644 --- a/tests/auto/declarative/qmlecmascript/data/methods.2.qml +++ b/tests/auto/declarative/qmlecmascript/data/methods.2.qml @@ -1,6 +1,6 @@ import Qt.test 1.0 MyQmlObject { - id: MyObject - onBasicSignal: MyObject.method(163) + id: myObject + onBasicSignal: myObject.method(163) } diff --git a/tests/auto/declarative/qmlecmascript/data/objectsCompareAsEqual.qml b/tests/auto/declarative/qmlecmascript/data/objectsCompareAsEqual.qml index 2526576..18e488a 100644 --- a/tests/auto/declarative/qmlecmascript/data/objectsCompareAsEqual.qml +++ b/tests/auto/declarative/qmlecmascript/data/objectsCompareAsEqual.qml @@ -1,15 +1,15 @@ import Qt 4.6 Item { - id: Root + id: root - property var item: Child - Item { id: Child } + property var item: child + Item { id: child } - property bool test1: Child == Child - property bool test2: Child.parent == Root - property bool test3: Root != Child - property bool test4: item == Child - property bool test5: item != Root + property bool test1: child == child + property bool test2: child.parent == root + property bool test3: root != child + property bool test4: item == child + property bool test5: item != root } diff --git a/tests/auto/declarative/qmlecmascript/data/outerBindingOverridesInnerBinding.qml b/tests/auto/declarative/qmlecmascript/data/outerBindingOverridesInnerBinding.qml index 49ada1f..0a933e8 100644 --- a/tests/auto/declarative/qmlecmascript/data/outerBindingOverridesInnerBinding.qml +++ b/tests/auto/declarative/qmlecmascript/data/outerBindingOverridesInnerBinding.qml @@ -1,12 +1,12 @@ import Qt.test 1.0 MyQmlObject { - property alias c1: MyConstants.c1 - property alias c2: MyConstants.c2 + property alias c1: myConstants.c1 + property alias c2: myConstants.c2 property int c3: 0 objectProperty: ConstantsOverrideBindings { - id: MyConstants + id: myConstants c2: c3 } diff --git a/tests/auto/declarative/qmlecmascript/data/scope.qml b/tests/auto/declarative/qmlecmascript/data/scope.qml index 80222c8..cccd3d3 100644 --- a/tests/auto/declarative/qmlecmascript/data/scope.qml +++ b/tests/auto/declarative/qmlecmascript/data/scope.qml @@ -1,7 +1,7 @@ import Qt 4.6 Item { - id: Root + id: root property int a: 1 property int binding: a @@ -16,7 +16,7 @@ Item { } Item { - id: NestedObject + id: nestedObject Script { function myNestedFunction() { @@ -32,17 +32,17 @@ Item { } ScopeObject { - id: CompObject + id: compObject } - property alias test1: Root.binding - property alias test2: NestedObject.binding - property alias test3: Root.binding2 - property alias test4: NestedObject.binding2 - property alias test5: Root.binding3 - property alias test6: NestedObject.binding3 - property alias test7: Root.binding4 - property alias test8: NestedObject.binding4 - property alias test9: CompObject.binding - property alias test10: CompObject.binding2 + property alias test1: root.binding + property alias test2: nestedObject.binding + property alias test3: root.binding2 + property alias test4: nestedObject.binding2 + property alias test5: root.binding3 + property alias test6: nestedObject.binding3 + property alias test7: root.binding4 + property alias test8: nestedObject.binding4 + property alias test9: compObject.binding + property alias test10: compObject.binding2 } diff --git a/tests/auto/declarative/qmlecmascript/data/signalParameterTypes.qml b/tests/auto/declarative/qmlecmascript/data/signalParameterTypes.qml index 42d26a1..6fc8b02 100644 --- a/tests/auto/declarative/qmlecmascript/data/signalParameterTypes.qml +++ b/tests/auto/declarative/qmlecmascript/data/signalParameterTypes.qml @@ -2,7 +2,7 @@ import Qt.test 1.0 MyQmlObject { - id: Root + id: root property int intProperty property real realProperty property color colorProperty @@ -12,5 +12,5 @@ MyQmlObject onMySignal: { intProperty = a; realProperty = b; colorProperty = c; variantProperty = d; } - onBasicSignal: Root.mySignal(10, 19.2, Qt.rgba(1, 1, 0, 1), Qt.rgba(1, 0, 1, 1)) + onBasicSignal: root.mySignal(10, 19.2, Qt.rgba(1, 1, 0, 1), Qt.rgba(1, 0, 1, 1)) } |