~tpeeters/ubuntu-ui-toolkit/toolbarActions-hide

« back to all changes in this revision

Viewing changes to modules/Ubuntu/Components/PageTreeNode.qml

MainView: new API to choose the background colors.

That requires:
- HeaderStyle: removed background.
- MainView: clip the contents when necessary.
- PageTreeNode: new properties 'isLeaf' and 'activeLeafNode'.

Approved by Tim Peeters, PS Jenkins bot.

Show diffs side-by-side

added added

removed removed

Lines of Context:
89
89
     */
90
90
    property Item parentNode: null
91
91
 
 
92
    /*!
 
93
      The leaf node that is active.
 
94
     */
 
95
    property Item activeLeafNode
 
96
    /*!
 
97
      Whether or not this node is a leaf, that is if it has no descendant that are nodes.
 
98
     */
 
99
    property bool isLeaf: true
 
100
 
 
101
    Binding {
 
102
        target: node.parentNode
 
103
        property: "activeLeafNode"
 
104
        value: node.isLeaf ? node : node.activeLeafNode
 
105
        when: node.active
 
106
    }
 
107
 
 
108
    Binding {
 
109
        target: node.parentNode
 
110
        property: "isLeaf"
 
111
        value: false
 
112
    }
 
113
 
92
114
    Item {
93
115
        id: internal
94
116
        function isPageTreeNode(object) {