on xenial help sign in
PreviewExpandable should be not expanded on startup
commit9c81d8be3d128eaf85d24ca1fdae092c2182d6d1 authorAlbert Astals Cid <albert.astals@canonical.com> dateTue 23 Jun 2015, 16:28 (11 years ago) parentbeb7168
2 files changed+4−2
qml/Dash/Previews/PreviewWidgetFactory.qml+1−1 tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml+3−1
qml/Dash/Previews/PreviewWidgetFactory.qml+1−1
@@ -35,7 +35,7 @@ Loader {
3535 property var scopeStyle: null
3636
3737 //! Should the widget show in expanded mode (For those that support it)
38− property bool expanded: true
38+ property bool expanded: widgetType !== "expandable"
3939
4040 //! Set to true if the parent preview is displayed.
4141 property bool isCurrentPreview: false
tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml+3−1
@@ -51,9 +51,10 @@ Rectangle {
5151 widgetsModel.append({"type": "text", "widgetId": "text4", "properties": { "text": longText }});
5252 }
5353
54− PreviewExpandable {
54+ PreviewWidgetFactory {
5555 id: previewExpandable
5656 anchors { left: parent.left; right: parent.right }
57+ widgetType: "expandable"
5758 widgetData: root.widgetData
5859 }
5960
@@ -77,6 +78,7 @@ Rectangle {
7778 }
7879
7980 function init() {
81+ checkInitialState();
8082 }
8183
8284 function test_collapsed_by_default() {