The id of a component does not become a new global identifier. i.e. 
"yellowRect" below:

    Component {
        id: yellowRectComponent
        Rectangle {
            id: yellowRect
            width: 100
            height: 100
            color: "yellow"
        }
    }

As you can imagine: if you had 2 loaders that loaded this, what would happen?

So, to fix your example, instead of:

            PropertyChanges {
                target: yellowRect
                color: "gray"
            }

You need:

            PropertyChanges {
                target: loader.item
                color: "gray"
            }

--
Warwick

_______________________________________________
Qt-qml mailing list
Qt-qml@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-qml

Reply via email to