@@ -2,7 +2,7 @@ AbstractButton {
3 property var components;
3 property var components;
4 property var cardData;
4 property var cardData;
5− property var artShapeBorderSource: undefined;
5+ property string artShapeStyle: "inset";
6 property real fontScale: 1.0;
6 property real fontScale: 1.0;
7 property var scopeStyle: null;
7 property var scopeStyle: null;
8 property int titleAlignment: Text.AlignLeft;
8 property int titleAlignment: Text.AlignLeft;
@@ -31,7 +31,7 @@ top: parent.top;
31 wrapMode: Text.Wrap;
31 wrapMode: Text.Wrap;
32 maximumLineCount: 2;
32 maximumLineCount: 2;
33 font.pixelSize: Math.round(FontUtils.sizeToPixels(fontSize) * fontScale);
33 font.pixelSize: Math.round(FontUtils.sizeToPixels(fontSize) * fontScale);
34− color: root.scopeStyle ? root.scopeStyle.foreground : Theme.palette.normal.baseText;
34+ color: root.scopeStyle ? root.scopeStyle.foreground : theme.palette.normal.baseText;
35 visible: showHeader ;
35 visible: showHeader ;
36 width: undefined;
36 width: undefined;
37 text: root.title;
37 text: root.title;
@@ -52,7 +52,7 @@ top: titleLabel.bottom;
52 maximumLineCount: 1;
52 maximumLineCount: 1;
53 fontSize: "x-small";
53 fontSize: "x-small";
54 font.pixelSize: Math.round(FontUtils.sizeToPixels(fontSize) * fontScale);
54 font.pixelSize: Math.round(FontUtils.sizeToPixels(fontSize) * fontScale);
55− color: root.scopeStyle ? root.scopeStyle.foreground : Theme.palette.normal.baseText;
55+ color: root.scopeStyle ? root.scopeStyle.foreground : theme.palette.normal.baseText;
56 visible: titleLabel.visible && titleLabel.text;
56 visible: titleLabel.visible && titleLabel.text;
57 text: cardData && cardData["subtitle"] || "";
57 text: cardData && cardData["subtitle"] || "";
58 font.weight: Font.Light;
58 font.weight: Font.Light;
@@ -74,7 +74,7 @@ CardAudioProgress {
74 width: height;
74 width: height;
75 height: (root.fixedHeaderHeight > 0 ? root.fixedHeaderHeight : headerHeight) + 2 * units.gu(1);
75 height: (root.fixedHeaderHeight > 0 ? root.fixedHeaderHeight : headerHeight) + 2 * units.gu(1);
76 readonly property url source: (cardData["quickPreviewData"] && cardData["quickPreviewData"]["uri"]) || "";
76 readonly property url source: (cardData["quickPreviewData"] && cardData["quickPreviewData"]["uri"]) || "";
77− UbuntuShape {
77+ UbuntuShape {
78 anchors.fill: parent;
78 anchors.fill: parent;
79 visible: parent.pressed;
79 visible: parent.pressed;
80 radius: "medium";
80 radius: "medium";
@@ -84,17 +84,17 @@ CardAudioProgress {
84 anchors.fill: parent;
84 anchors.fill: parent;
85 anchors.margins: parent.height > units.gu(5) ? units.gu(2) : units.gu(0);
85 anchors.margins: parent.height > units.gu(5) ? units.gu(2) : units.gu(0);
86 opacity: 0.9;
86 opacity: 0.9;
87− name: DashAudioPlayer.isCurrentSource(parent.source) && DashAudioPlayer.playing ? "media-playback-pause" : "media-playback-start";
87+ name: DashAudioPlayer.playing && AudioUrlComparer.compare(parent.source, DashAudioPlayer.currentSource) ? "media-playback-pause" : "media-playback-start";
89 onClicked: {
89 onClicked: {
90− if (DashAudioPlayer.isCurrentSource(source)) {
90+ if (AudioUrlComparer.compare(source, DashAudioPlayer.currentSource)) {
91 if (DashAudioPlayer.playing) {
91 if (DashAudioPlayer.playing) {
92 DashAudioPlayer.pause();
92 DashAudioPlayer.pause();
94 DashAudioPlayer.play();
94 DashAudioPlayer.play();
97− var playlist = (cardData["quickPreviewData"] && cardData["quickPreviewData"]["playlist"]) || null;
97+ var playlist = (cardData["quickPreviewData"] && cardData["quickPreviewData"]["playlist"]) || null;
98 DashAudioPlayer.playSource(source, playlist);
98 DashAudioPlayer.playSource(source, playlist);
@@ -105,7 +105,7 @@ CardAudioProgress {
105 id: touchdown;
105 id: touchdown;
106 objectName: "touchdown";
106 objectName: "touchdown";
107 anchors { fill: root }
107 anchors { fill: root }
108− visible: root.pressed;
108+ visible: root.artShapeStyle != "shadow" && root.artShapeStyle != "icon" && root.pressed;
109 radius: "medium";
109 radius: "medium";
110 borderSource: "radius_pressed.sci"
110 borderSource: "radius_pressed.sci"