on xenial help sign in
Animate height of the combo
f346a42Albert Astals
qml/Dash/Previews/PreviewActionCombo.qml+7−2
@@ -48,15 +48,20 @@ Item {
48 objectName: "buttonColumn"
48 objectName: "buttonColumn"
49 spacing: units.gu(1)
49 spacing: units.gu(1)
50 width: maxWidth
50 width: maxWidth
51+ height: moreButton.expanded ? implicitHeight : 0
52+ clip: true
53+ Behavior on height {
54+ UbuntuNumberAnimation {
55+ duration: UbuntuAnimation.SnapDuration
56+ }
57+ }
51
58
52 Repeater {
59 Repeater {
53 id: actionRepeater
60 id: actionRepeater
54
61
55 delegate: PreviewActionButton {
62 delegate: PreviewActionButton {
56 data: modelData
63 data: modelData
57− height: moreButton.expanded ? implicitHeight : 0
58 width: implicitWidth < parent.width ? parent.width : implicitWidth
64 width: implicitWidth < parent.width ? parent.width : implicitWidth
59− visible: height > 0
60 Component.onCompleted: {
65 Component.onCompleted: {
61 column.maxWidth = Math.max(column.maxWidth, implicitWidth);
66 column.maxWidth = Math.max(column.maxWidth, implicitWidth);
62 }
67 }