@@ -39,6 +39,7 @@ AbstractButton {
3939 height: visible ? units.gu(5) : 0
4040
4141 onClicked: {
42+ departmentListView.updateMaxHeight();
4243 root.showList = !root.showList;
4344 }
4445
@@ -111,7 +112,12 @@ AbstractButton {
111112 right: parent.right
112113 top: root.bottom
113114 }
114− readonly property int maxHeight: (windowHeight - mapToItem(null, root.x, root.y).y) - units.gu(8)
115+ property int maxHeight: -1
116+ Component.onCompleted: updateMaxHeight();
117+ function updateMaxHeight()
118+ {
119+ maxHeight = (windowHeight - mapToItem(null, 0, 0).y) - units.gu(8);
120+ }
115121 property int prevHeight: maxHeight
116122 height: currentItem ? currentItem.height : maxHeight
117123 onHeightChanged: {
@@ -129,6 +135,7 @@ AbstractButton {
129135 if (root.showList) {
130136 if (navigation && navigation.loaded && x == navigationListView.contentX)
131137 {
138+ navigationListView.updateMaxHeight();
132139 return Math.min(implicitHeight, navigationListView.maxHeight);
133140 } else {
134141 return navigationListView.prevHeight;