Only show add machine dialogue if your stack got corrupt, not whole onboarding

We don't need to accept the EULA again or whatever. Just add the printer that got lost.

Contributes to issue CURA-6057.
This commit is contained in:
Ghostkeeper 2019-04-03 15:52:07 +02:00
parent 1207533046
commit 2ccc30b824
No known key found for this signature in database
GPG key ID: 86BEF881AE2CF276
2 changed files with 8 additions and 3 deletions

View file

@ -84,7 +84,7 @@ UM.MainWindow
Cura.Actions.parent = backgroundItem Cura.Actions.parent = backgroundItem
CuraApplication.purgeWindows() CuraApplication.purgeWindows()
if (CuraApplication.needToShowUserAgreement || Cura.MachineManager.activeMachine == null) if (CuraApplication.needToShowUserAgreement)
{ {
welcomeDialog.visible = true welcomeDialog.visible = true
} }
@ -851,6 +851,10 @@ UM.MainWindow
{ {
base.visible = true; base.visible = true;
} }
if(Cura.MachineManager.activeMachine == null)
{
addMachineDialog.open();
}
} }
} }

View file

@ -1,4 +1,4 @@
// Copyright (c) 2018 Ultimaker B.V. // Copyright (c) 2019 Ultimaker B.V.
// Cura is released under the terms of the LGPLv3 or higher. // Cura is released under the terms of the LGPLv3 or higher.
import QtQuick 2.2 import QtQuick 2.2
@ -38,7 +38,8 @@ UM.Dialog
onVisibilityChanged: onVisibilityChanged:
{ {
// Reset selection and machine name // Reset selection and machine name
if (visible) { if (visible)
{
activeCategory = preferredCategory; activeCategory = preferredCategory;
machineList.currentIndex = 0; machineList.currentIndex = 0;
machineName.text = getMachineName(); machineName.text = getMachineName();