@@ -27,21 +27,22 @@ PreviewWidget {
27 height: childrenRect.height
27 height: childrenRect.height
28 width: childrenRect.width
28 width: childrenRect.width
30− readonly property var actions: root.widgetData ? root.widgetData["actions"] : null
32+ readonly property var actions: root.widgetData ? root.widgetData["actions"] : null
33 spacing: units.gu(1)
34 spacing: units.gu(1)
36 id: loader
37 id: loader
37− readonly property bool button: actions && actions.length == 2
38+ readonly property bool button: row.actions && row.actions.length == 2
38− readonly property bool combo: actions && actions.length > 2
39+ readonly property bool combo: row.actions && row.actions.length > 2
39 source: button ? "PreviewActionButton.qml" : (combo ? "PreviewActionCombo.qml" : "")
40 source: button ? "PreviewActionButton.qml" : (combo ? "PreviewActionCombo.qml" : "")
40 onLoaded: {
41 onLoaded: {
41 if (button) {
42 if (button) {
42− item.data = actions[1];
43+ item.data = row.actions[1];
43 } else if (combo) {
44 } else if (combo) {
44− item.model = actions.slice(1);
45+ item.model = row.actions.slice(1);
47 Connections {
48 Connections {
@@ -53,8 +54,8 @@ PreviewWidget {
55 PreviewActionButton {
56 PreviewActionButton {
56− data: visible ? actions[0] : null
57+ data: visible ? row.actions[0] : null
57− visible: actions && actions.length > 0
58+ visible: row.actions && row.actions.length > 0
58 onTriggeredAction: root.triggered(root.widgetId, id, null);
59 onTriggeredAction: root.triggered(root.widgetId, id, null);