on xenial help sign in
asynchronous is only false on the fake card in cardtool

Resolve the code on compile time Approved by: Andrea Cimitan

commit07566ccc7d6a4fd34c09959f80642e8692862c9d authorAlbert Astals Cid <albert.astals@canonical.com> dateThu 10 Mar 2016, 22:38 (11 years ago) parentdf1f238ef7dc10
24 files changed+64−76
plugins/Dash/CardCreator.js+29−18 qml/Dash/CardTool.qml−1 tests/plugins/Dash/cardcreator/1.res+3−4 tests/plugins/Dash/cardcreator/1.res.cardcreator+2−3 tests/plugins/Dash/cardcreator/10.res+1−2 tests/plugins/Dash/cardcreator/10.res.cardcreator+1−2 tests/plugins/Dash/cardcreator/11.res+3−4 tests/plugins/Dash/cardcreator/11.res.cardcreator+3−4 tests/plugins/Dash/cardcreator/2.res+1−2 tests/plugins/Dash/cardcreator/2.res.cardcreator+1−2 tests/plugins/Dash/cardcreator/3.res+2−3 tests/plugins/Dash/cardcreator/3.res.cardcreator+2−3 tests/plugins/Dash/cardcreator/4.res+1−2 tests/plugins/Dash/cardcreator/4.res.cardcreator+1−2 tests/plugins/Dash/cardcreator/5.res+3−4 tests/plugins/Dash/cardcreator/5.res.cardcreator+4−5 tests/plugins/Dash/cardcreator/6.res+1−2 tests/plugins/Dash/cardcreator/6.res.cardcreator+1−2 tests/plugins/Dash/cardcreator/7.res+1−2 tests/plugins/Dash/cardcreator/7.res.cardcreator+2−3 tests/plugins/Dash/cardcreator/8.res+1−2 tests/plugins/Dash/cardcreator/8.res.cardcreator+1−2 tests/plugins/Dash/cardcreator/9.res−1 tests/plugins/Dash/cardcreator/9.res.cardcreator−1
plugins/Dash/CardCreator.js+29−18
@@ -18,12 +18,13 @@
1818
1919// %1 is the template["card-background"]["elements"][0]
2020// %2 is the template["card-background"]["elements"][1]
21−// %3 is the template["card-background"] string
21+// %3 is whether the loader should be asynchronous or not
22+// %4 is the template["card-background"] string
2223var kBackgroundLoaderCode = 'Loader {\n\
2324 id: backgroundLoader; \n\
2425 objectName: "backgroundLoader"; \n\
2526 anchors.fill: parent; \n\
26− asynchronous: root.asynchronous; \n\
27+ asynchronous: %3; \n\
2728 visible: status == Loader.Ready; \n\
2829 sourceComponent: UbuntuShape { \n\
2930 objectName: "background"; \n\
@@ -46,7 +47,7 @@ var kBackgroundLoaderCode = 'Loader {\n\
4647 objectName: "backgroundImage"; \n\
4748 source: { \n\
4849 if (cardData && typeof cardData["background"] === "string") return cardData["background"]; \n\
49− else return %3; \n\
50+ else return %4; \n\
5051 } \n\
5152 } \n\
5253 function getColor(index) { \n\
@@ -63,8 +64,9 @@ var kBackgroundLoaderCode = 'Loader {\n\
6364// %3 is used as image height
6465// %4 is used for artShapeSource.hideSource and inner Loader visible
6566// %5 is used as aspect ratio fallback
66−// %6 is injected as code to artImage
67−// %7 is used as image fallback
67+// %6 is whether the loader should be asynchronous or not
68+// %7 is injected as code to artImage
69+// %8 is used as image fallback
6870var kArtShapeHolderCode = 'Item { \n\
6971 id: artShapeHolder; \n\
7072 height: root.fixedArtShapeSize.height > 0 ? root.fixedArtShapeSize.height : artShapeLoader.height; \n\
@@ -73,9 +75,9 @@ var kArtShapeHolderCode = 'Item { \n\
7375 Loader { \n\
7476 id: artShapeLoader; \n\
7577 objectName: "artShapeLoader"; \n\
76− readonly property string cardArt: cardData && cardData["art"] || %7; \n\
78+ readonly property string cardArt: cardData && cardData["art"] || %8; \n\
7779 active: cardArt != ""; \n\
78− asynchronous: root.asynchronous; \n\
80+ asynchronous: %6; \n\
7981 visible: status == Loader.Ready; \n\
8082 sourceComponent: Item { \n\
8183 id: artShape; \n\
@@ -132,10 +134,10 @@ var kArtShapeHolderCode = 'Item { \n\
132134 id: artImage; \n\
133135 objectName: "artImage"; \n\
134136 source: artShapeLoader.cardArt; \n\
135− asynchronous: root.asynchronous; \n\
137+ asynchronous: %6; \n\
136138 width: %2; \n\
137139 height: %3; \n\
138− %6 \n\
140+ %7 \n\
139141 } \n\
140142 } \n\
141143 } \n\
@@ -187,12 +189,13 @@ var kAudioButtonCode = 'AbstractButton { \n\
187189 } \n\
188190 }';
189191
192+// %1 is whether the loader should be asynchronous or not
190193var kOverlayLoaderCode = 'Loader { \n\
191194 id: overlayLoader; \n\
192195 readonly property real overlayHeight: (fixedHeaderHeight > 0 ? fixedHeaderHeight : headerHeight) + units.gu(2); \n\
193196 anchors.fill: artShapeHolder; \n\
194197 active: artShapeLoader.active && artShapeLoader.item && artShapeLoader.item.image.status === Image.Ready || false; \n\
195− asynchronous: root.asynchronous; \n\
198+ asynchronous: %1; \n\
196199 visible: showHeader && status == Loader.Ready; \n\
197200 sourceComponent: UbuntuShapeOverlay { \n\
198201 id: overlay; \n\
@@ -242,10 +245,11 @@ function kHeaderContainerCodeGenerator() {
242245}
243246
244247// %1 is used as anchors of mascotShapeLoader
248+// %2 is whether the loader should be asynchronous or not
245249var kMascotShapeLoaderCode = 'Loader { \n\
246250 id: mascotShapeLoader; \n\
247251 objectName: "mascotShapeLoader"; \n\
248− asynchronous: root.asynchronous; \n\
252+ asynchronous: %2; \n\
249253 active: mascotImage.status === Image.Ready; \n\
250254 visible: showHeader && active && status == Loader.Ready; \n\
251255 width: units.gu(6); \n\
@@ -414,7 +418,6 @@ function cardString(template, components, isCardTool) {
414418 property int fixedHeaderHeight: -1; \n\
415419 property size fixedArtShapeSize: Qt.size(-1, -1); \n\
416420 readonly property string title: cardData && cardData["title"] || ""; \n\
417− property bool asynchronous: true; \n\
418421 property bool showHeader: true; \n\
419422 implicitWidth: childrenRect.width; \n\
420423 enabled: %1; \n\
@@ -435,6 +438,7 @@ function cardString(template, components, isCardTool) {
435438 var hasHeaderRow = hasMascot && hasTitle;
436439 var hasAttributes = hasTitle && components["attributes"] && components["attributes"]["field"] || false;
437440 var isAudio = template["quick-preview-type"] === "audio";
441+ var asynchronous = isCardTool ? "false" : "true";
438442
439443 if (isAudio) {
440444 // For now we only support audio cards with [optional] art, title, subtitle
@@ -468,7 +472,7 @@ function cardString(template, components, isCardTool) {
468472 backgroundElements1 = '"%1"'.arg(element1);
469473 }
470474 }
471− code += kBackgroundLoaderCode.arg(backgroundElements0).arg(backgroundElements1).arg(templateCardBackground);
475+ code += kBackgroundLoaderCode.arg(backgroundElements0).arg(backgroundElements1).arg(asynchronous).arg(templateCardBackground);
472476 }
473477
474478 if (hasArt) {
@@ -503,17 +507,24 @@ function cardString(template, components, isCardTool) {
503507 var fallbackURICode = '""';
504508 if (fallback !== "") {
505509 // fallbackStatusCode has %6 in it because we want to substitute it for fallbackURICode
506− // which in kArtShapeHolderCode is %7
507− fallbackStatusCode += 'onStatusChanged: if (status === Image.Error) source = %7;';
510+ // which in kArtShapeHolderCode is %8
511+ fallbackStatusCode += 'onStatusChanged: if (status === Image.Error) source = %8;';
508512 fallbackURICode = 'decodeURI("%1")'.arg(fallback);
509513 }
510− code += kArtShapeHolderCode.arg(artAnchors).arg(widthCode).arg(heightCode).arg(isConciergeMode ? "false" : "true").arg(aspectRatio).arg(fallbackStatusCode).arg(fallbackURICode);
514+ code += kArtShapeHolderCode.arg(artAnchors)
515+ .arg(widthCode)
516+ .arg(heightCode)
517+ .arg(isConciergeMode ? "false" : "true")
518+ .arg(aspectRatio)
519+ .arg(asynchronous)
520+ .arg(fallbackStatusCode)
521+ .arg(fallbackURICode);
511522 } else {
512523 code += 'readonly property size artShapeSize: Qt.size(-1, -1);\n'
513524 }
514525
515526 if (headerAsOverlay) {
516− code += kOverlayLoaderCode;
527+ code += kOverlayLoaderCode.arg(asynchronous);
517528 }
518529
519530 var headerVerticalAnchors;
@@ -595,7 +606,7 @@ function cardString(template, components, isCardTool) {
595606 }
596607
597608 if (useMascotShape) {
598− mascotShapeCode = kMascotShapeLoaderCode.arg(mascotAnchors);
609+ mascotShapeCode = kMascotShapeLoaderCode.arg(mascotAnchors).arg(asynchronous);
599610 }
600611
601612 var mascotImageVisible = useMascotShape ? 'false' : 'showHeader';
qml/Dash/CardTool.qml−1
@@ -196,7 +196,6 @@ Item {
196196 sourceComponent: CardCreatorCache.getCardComponent(cardTool.template, cardTool.components, true);
197197 onLoaded: {
198198 item.objectName = "cardToolCard";
199− item.asynchronous = false;
200199 item.width = Qt.binding(function() { return cardTool.cardWidth !== -1 ? cardTool.cardWidth : item.implicitWidth; });
201200 item.height = Qt.binding(function() { return cardTool.cardHeight !== -1 ? cardTool.cardHeight : item.implicitHeight; });
202201 }
tests/plugins/Dash/cardcreator/1.res+3−4
@@ -8,8 +8,7 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
12− property bool showHeader: true;
11+ property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
1514
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || "";
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: true;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: true;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 }
tests/plugins/Dash/cardcreator/1.res.cardcreator+2−3
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || "";
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: false;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: false;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 }
tests/plugins/Dash/cardcreator/10.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/10.res.cardcreator+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/11.res+3−4
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
@@ -62,7 +61,7 @@ Item {
6261 objectName: "artShapeLoader";
6362 readonly property string cardArt: cardData && cardData["art"] || decodeURI("%5C");
6463 active: cardArt != "";
65− asynchronous: root.asynchronous;
64+ asynchronous: true;
6665 visible: status == Loader.Ready;
6766 sourceComponent: Item {
6867 id: artShape;
@@ -119,7 +118,7 @@ Item {
119118 id: artImage;
120119 objectName: "artImage";
121120 source: artShapeLoader.cardArt;
122− asynchronous: root.asynchronous;
121+ asynchronous: true;
123122 width: root.width;
124123 height: width / artShape.aspect;
125124 onStatusChanged: if (status === Image.Error) source = decodeURI("%5C");
tests/plugins/Dash/cardcreator/11.res.cardcreator+3−4
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
@@ -62,7 +61,7 @@ Item {
6261 objectName: "artShapeLoader";
6362 readonly property string cardArt: cardData && cardData["art"] || "";
6463 active: cardArt != "";
65− asynchronous: root.asynchronous;
64+ asynchronous: false;
6665 visible: status == Loader.Ready;
6766 sourceComponent: Item {
6867 id: artShape;
@@ -119,7 +118,7 @@ Item {
119118 id: artImage;
120119 objectName: "artImage";
121120 source: artShapeLoader.cardArt;
122− asynchronous: root.asynchronous;
121+ asynchronous: false;
123122 width: root.width;
124123 height: width / artShape.aspect;
125124 }
tests/plugins/Dash/cardcreator/2.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/2.res.cardcreator+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/3.res+2−3
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || decodeURI("IHAVE%5C%22ESCAPED%5C%22QUOTES%5C%22");
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: true;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: true;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 onStatusChanged: if (status === Image.Error) source = decodeURI("IHAVE%5C%22ESCAPED%5C%22QUOTES%5C%22");
tests/plugins/Dash/cardcreator/3.res.cardcreator+2−3
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || "";
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: false;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: false;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 }
tests/plugins/Dash/cardcreator/4.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -32,7 +31,7 @@ data: [
3231Loader {
3332 id: mascotShapeLoader;
3433 objectName: "mascotShapeLoader";
35− asynchronous: root.asynchronous;
34+ asynchronous: true;
3635 active: mascotImage.status === Image.Ready;
3736 visible: showHeader && active && status == Loader.Ready;
3837 width: units.gu(6);
tests/plugins/Dash/cardcreator/4.res.cardcreator+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -32,7 +31,7 @@ data: [
3231Loader {
3332 id: mascotShapeLoader;
3433 objectName: "mascotShapeLoader";
35− asynchronous: root.asynchronous;
34+ asynchronous: false;
3635 active: mascotImage.status === Image.Ready;
3736 visible: showHeader && active && status == Loader.Ready;
3837 width: units.gu(6);
tests/plugins/Dash/cardcreator/5.res+3−4
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: false;
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || "";
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: true;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: true;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 }
@@ -93,7 +92,7 @@ Loader {
9392 readonly property real overlayHeight: (fixedHeaderHeight > 0 ? fixedHeaderHeight : headerHeight) + units.gu(2);
9493 anchors.fill: artShapeHolder;
9594 active: artShapeLoader.active && artShapeLoader.item && artShapeLoader.item.image.status === Image.Ready || false;
96− asynchronous: root.asynchronous;
95+ asynchronous: true;
9796 visible: showHeader && status == Loader.Ready;
9897 sourceComponent: UbuntuShapeOverlay {
9998 id: overlay;
tests/plugins/Dash/cardcreator/5.res.cardcreator+4−5
@@ -8,8 +8,7 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
12− property bool showHeader: true;
11+ property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: false;
1514
@@ -24,7 +23,7 @@ Item {
2423 objectName: "artShapeLoader";
2524 readonly property string cardArt: cardData && cardData["art"] || "";
2625 active: cardArt != "";
27− asynchronous: root.asynchronous;
26+ asynchronous: false;
2827 visible: status == Loader.Ready;
2928 sourceComponent: Item {
3029 id: artShape;
@@ -81,7 +80,7 @@ Item {
8180 id: artImage;
8281 objectName: "artImage";
8382 source: artShapeLoader.cardArt;
84− asynchronous: root.asynchronous;
83+ asynchronous: false;
8584 width: root.width;
8685 height: width / artShape.aspect;
8786 }
@@ -93,7 +92,7 @@ Loader {
9392 readonly property real overlayHeight: (fixedHeaderHeight > 0 ? fixedHeaderHeight : headerHeight) + units.gu(2);
9493 anchors.fill: artShapeHolder;
9594 active: artShapeLoader.active && artShapeLoader.item && artShapeLoader.item.image.status === Image.Ready || false;
96− asynchronous: root.asynchronous;
95+ asynchronous: false;
9796 visible: showHeader && status == Loader.Ready;
9897 sourceComponent: UbuntuShapeOverlay {
9998 id: overlay;
tests/plugins/Dash/cardcreator/6.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/6.res.cardcreator+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/7.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/7.res.cardcreator+2−3
@@ -8,8 +8,7 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
12− property bool showHeader: true;
11+ property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
1514
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/8.res+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: true;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/8.res.cardcreator+1−2
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
@@ -17,7 +16,7 @@ Loader {
1716 id: backgroundLoader;
1817 objectName: "backgroundLoader";
1918 anchors.fill: parent;
20− asynchronous: root.asynchronous;
19+ asynchronous: false;
2120 visible: status == Loader.Ready;
2221 sourceComponent: UbuntuShape {
2322 objectName: "background";
tests/plugins/Dash/cardcreator/9.res−1
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;
tests/plugins/Dash/cardcreator/9.res.cardcreator−1
@@ -8,7 +8,6 @@ AbstractButton {
88 property int fixedHeaderHeight: -1;
99 property size fixedArtShapeSize: Qt.size(-1, -1);
1010 readonly property string title: cardData && cardData["title"] || "";
11− property bool asynchronous: true;
1211 property bool showHeader: true;
1312 implicitWidth: childrenRect.width;
1413 enabled: true;