Fix height and scrolling of add printer menus

This fixes the irritating scrolling behaviour of the local printer menu, as well as the disappearing items (former issue which had a workaround) and makes it use a styled scroll bar.

Contributes to issue CURA-8686.
This commit is contained in:
Ghostkeeper 2022-01-19 16:26:48 +01:00
parent f94b7ce753
commit fa2fbb99c7
No known key found for this signature in database
GPG key ID: D2A8871EE34EC59A
3 changed files with 68 additions and 102 deletions

View file

@ -1,4 +1,4 @@
// Copyright (c) 2019 Ultimaker B.V.
// Copyright (c) 2022 Ultimaker B.V.
// Cura is released under the terms of the LGPLv3 or higher.
import QtQuick 2.10
@ -61,7 +61,7 @@ Item
anchors.left: header.left
anchors.right: header.right
// Add 2x lining, because it needs a bit of space on the top and the bottom.
height: contentLoader.item.height + 2 * UM.Theme.getSize("thick_lining").height
height: contentLoader.item ? contentLoader.item.height + 2 * UM.Theme.getSize("thick_lining").height : 0
border.width: UM.Theme.getSize("default_lining").width
border.color: UM.Theme.getColor("lining")