on xenial help sign in
Reset VerticalJournal until the cardTool settles
955bba8Albert Astals
qml/Dash/CardVerticalJournal.qml+17
@@ -33,6 +33,23 @@ DashRenderer {
33 // in case the model is non empty
33 // in case the model is non empty
34 readonly property double minHeight: root.model.count >= 1 ? cardVerticalJournal.rowSpacing + 1 : 0
34 readonly property double minHeight: root.model.count >= 1 ? cardVerticalJournal.rowSpacing + 1 : 0
35
35
36+ function clearView() {
37+ cardVerticalJournal.model = null;
38+ cardVerticalJournal.model = root.model;
39+ }
40+
41+ // Clear the view if the cardTool changes its sizes
42+ // means it is still settling. This is
43+ // necessary because the VerticalJournal does
44+ // not support its elements changing height so
45+ // we need to construct all the items with the settled
46+ // size of the cardTool
47+ Connections {
48+ target: cardTool
49+ onArtShapeSizeChanged: root.clearView();
50+ onHeaderHeightChanged: root.clearView();
51+ }
52+
36 ResponsiveVerticalJournal {
53 ResponsiveVerticalJournal {
37 id: cardVerticalJournal
54 id: cardVerticalJournal
38
55