@@ -23,6 +23,7 @@ Item {
24 property real progress: 0
24 property real progress: 0
25 property var scope: null
25 property var scope: null
26+ property real scopeScale: 1
27 signal done
28 signal done
@@ -135,6 +136,48 @@ Item {
135 id: middleItems
136 id: middleItems
136 model: scope ? scope.categories : null
137 model: scope ? scope.categories : null
137 delegate: Loader {
138 delegate: Loader {
141+ return parent.height;
143+ return parent.height - topBar.height - units.gu(2)
148+ return parent.width / scopeScale
155+ return (root.width - width) / 2;
161+ bottom: parent.bottom
164+ scale: index == 0 ? scopeScale : 1
166+ opacity: tabBarHolder.currentTab == index ? 1 : 0
167+ Behavior on opacity { UbuntuNumberAnimation { } }
168+ enabled: opacity == 1
174+ objectName: "cardTool"
175+ count: results.count
176+ template: model.renderer
177+ components: model.components
178+ viewWidth: parent.width
138 source: {
181 source: {
139 if (index == 0) return "ScopesOverviewFavourites.qml";
182 if (index == 0) return "ScopesOverviewFavourites.qml";
140 else if (index == 1) return "ScopesOverviewAll.qml";
183 else if (index == 1) return "ScopesOverviewAll.qml";
@@ -143,6 +186,17 @@ Item {
143 return "";
186 return "";
191+ item.model = Qt.binding(function() { return results })
192+ item.cardTool = cardTool;
194+ item.scopeWidth = root.width;
195+ item.scopeHeight = root.height;
196+ } else if (index == 1) {
197+ item.extraHeight = bottomBar.height;
@@ -151,6 +205,7 @@ Item {
151 color: "black"
205 color: "black"
152 height: units.gu(6)
206 height: units.gu(6)
153 width: parent.width
207 width: parent.width
155 if (root.progress < 0.5) {
210 if (root.progress < 0.5) {
156 return parent.height;
211 return parent.height;
@@ -180,7 +235,10 @@ Item {
180 text: i18n.tr("Done")
235 text: i18n.tr("Done")
181 color: parent.pressed ? "black" : "white"
236 color: parent.pressed ? "black" : "white"
183− onClicked: root.done()
238+ onClicked: {
240+ tabBarHolder.currentTab = 0;