mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 13:59:02 +08:00
Hide refresh button if there are no offline printers
It's not considered a big use case when the user has already added some printers but would want to add more while syncing materials to those printers. Contributes to issue CURA-8609.
This commit is contained in:
parent
9ffbaa772f
commit
56eb694745
@ -266,7 +266,8 @@ Window
|
||||
footer: Item
|
||||
{
|
||||
width: printerListScrollView.width
|
||||
height: UM.Theme.getSize("card").height + UM.Theme.getSize("default_margin").height
|
||||
height: visible ? UM.Theme.getSize("card").height + UM.Theme.getSize("default_margin").height : 0
|
||||
visible: includeOfflinePrinterList.count - cloudPrinterList.count > 0
|
||||
Rectangle
|
||||
{
|
||||
border.color: UM.Theme.getColor("lining")
|
||||
@ -533,6 +534,13 @@ Window
|
||||
filterConnectionType: 3 //Only show cloud connections.
|
||||
filterOnlineOnly: true //Only show printers that are online.
|
||||
}
|
||||
Cura.GlobalStacksModel
|
||||
{
|
||||
//In order to show a refresh button only when there are offline cloud printers, we need to know if there are any offline printers.
|
||||
//A global stacks model without the filter for online-only printers allows this.
|
||||
id: includeOfflinePrinterList
|
||||
filterConnectionType: 3 //Still only show cloud connections.
|
||||
}
|
||||
|
||||
FileDialog
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user