forked from Shinonome/dots-hyprland
fix item list size calculation to fit all items in list
This commit is contained in:
@@ -116,7 +116,7 @@ ComboBox {
|
|||||||
popup: Popup {
|
popup: Popup {
|
||||||
y: root.height + 4
|
y: root.height + 4
|
||||||
width: root.width
|
width: root.width
|
||||||
implicitHeight: Math.min(contentItem.implicitHeight, 300)
|
height: Math.min(listView.contentHeight + topPadding + bottomPadding, 300)
|
||||||
padding: 8
|
padding: 8
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
@@ -125,6 +125,7 @@ ComboBox {
|
|||||||
}
|
}
|
||||||
|
|
||||||
contentItem: ListView {
|
contentItem: ListView {
|
||||||
|
id: listView
|
||||||
clip: true
|
clip: true
|
||||||
implicitHeight: contentHeight
|
implicitHeight: contentHeight
|
||||||
model: root.popup.visible ? root.delegateModel : null
|
model: root.popup.visible ? root.delegateModel : null
|
||||||
|
|||||||
Reference in New Issue
Block a user