tests/auto/declarative/qdeclarativepathview/data/datamodel.qml
branchGCC_SURGE
changeset 31 5daf16870df6
parent 30 5dc02b23752f
equal deleted inserted replaced
27:93b982ccede2 31:5daf16870df6
       
     1 import Qt 4.7
       
     2 
       
     3 PathView {
       
     4     id: pathview
       
     5     objectName: "pathview"
       
     6     width: 240; height: 320
       
     7     pathItemCount: testObject.pathItemCount
       
     8 
       
     9     function checkProperties() {
       
    10         testObject.error = false;
       
    11         if (testObject.useModel && pathview.model != testData) {
       
    12             console.log("model property incorrect");
       
    13             testObject.error = true;
       
    14         }
       
    15     }
       
    16 
       
    17     model: testObject.useModel ? testData : 0
       
    18 
       
    19     delegate: Component {
       
    20         id: myDelegate
       
    21         Rectangle {
       
    22             id: wrapper
       
    23             objectName: "wrapper"
       
    24             width: 20; height: 20; color: name
       
    25             Text {
       
    26                 objectName: "myText"
       
    27                 text: name
       
    28             }
       
    29         }
       
    30     }
       
    31 
       
    32     path: Path {
       
    33         startX: 120; startY: 20;
       
    34         PathLine { x: 120; y: 300 }
       
    35     }
       
    36 }