Hide entire footer when the user started syncing

If they started syncing, most likely the list of printers is just complete and the user won't need this any more.

Contributes to issue CURA-8609.
This commit is contained in:
Ghostkeeper 2021-11-03 11:26:28 +01:00
parent ccfdfe5539
commit 9c684cbc4d
No known key found for this signature in database
GPG Key ID: D2A8871EE34EC59A

View File

@ -385,14 +385,10 @@ Window
{ {
return 0; return 0;
} }
let h = UM.Theme.getSize("card").height + UM.Theme.getSize("default_margin").height; //1 margin between content and footer. let h = UM.Theme.getSize("card").height + printerListTroubleshooting.height + UM.Theme.getSize("default_margin").height * 2; //1 margin between content and footer, 1 for troubleshooting link.
if(printerListTroubleshooting.visible)
{
h += printerListTroubleshooting.height + UM.Theme.getSize("default_margin").height; //Height increases if there's a troubleshooting link.
}
return h; return h;
} }
visible: includeOfflinePrinterList.count - cloudPrinterList.count > 0 visible: includeOfflinePrinterList.count - cloudPrinterList.count > 0 && typeof syncModel !== "undefined" && syncModel.exportUploadStatus === "idle"
Rectangle Rectangle
{ {
anchors.fill: parent anchors.fill: parent
@ -445,7 +441,6 @@ Window
id: printerListTroubleshooting id: printerListTroubleshooting
text: catalog.i18nc("@button", "Troubleshooting") text: catalog.i18nc("@button", "Troubleshooting")
visible: typeof syncModel !== "undefined" && syncModel.exportUploadStatus !== "error"
iconSource: UM.Theme.getIcon("LinkExternal") iconSource: UM.Theme.getIcon("LinkExternal")
onClicked: Qt.openUrlExternally("https://support.ultimaker.com/hc/en-us/articles/360012019239?utm_source=cura&utm_medium=software&utm_campaign=sync-material-wizard-troubleshoot-cloud-printer") onClicked: Qt.openUrlExternally("https://support.ultimaker.com/hc/en-us/articles/360012019239?utm_source=cura&utm_medium=software&utm_campaign=sync-material-wizard-troubleshoot-cloud-printer")
} }