This reverts commit 28f4d8513db7efce17bfd8b80fa7c8b237fd1c18.
The original revert was to revert an accidental merge from master to 4.7. This now reverts the revert on Master, so that we still have those changes on Master.
The issue will happen only if the machine_extruder_count is a formula.
In this case, the project loading will not work properly if "Create new" printer is selected,
as the settings of all extruders but the first one will not be applied.
Workaround in this case will be to load the project again and select to update the existing
printer, in which case all settings will load properly.
CURA-7646
If it failed to create a global stack, the extruder_stack_dict variable would not be defined, and Cura crashes. It may fail to create a stack because of an indexerror in a malformed project file.
Fixes Sentry issue CURA-137.
With the caveat that the qtQuickControls had to be updated to 2.3, due to a qt bug in 1.x that did
not update the dropdown popup list according to the ListModel.
This leads to a different look in the dropdowns and in the buttons of the open project dialog,
compaired to the rest of the application.
CURA-7609
A ComboBox was added under the "Update existing" combobox which will display all the available
printers that are of the same type with the printer in the project file. With this feature, the
user will be able to select any same-type preexisting printer in Cura to be updated, instead of
always create a new one when the project file's printer is not in Cura.
CURA-7609
By using "pass" when the IndexError occured while reading the quality changes, empty quality
changes containers were added to the registry. These empty quality changes were then used as
"global" quality_changes, since the container registry was simply picking the first quality
changes instance container that had an empty extruder stack. Therefore, the correct global
quality changes (that actually had the global settings that were changed, like the support)
was just ignored in the whole process.
CURA-7549
The pre-read takes a while since it shows a dialogue. The user has all the time to delete the file or rename it in the meanwhile.
Fixes Sentry issue CURA-SG.
I looked into changing that position into an integer and perhaps the dictionary into a list, but this dictionary is passed around throughout all of the functions so that would be quite a refactor.
Done during Turbo Testing and Tooling to reduce the number of warnings in our log.
Otherwise it would crash with a BadZipFile error. We should be robust against that. This will trigger a generic message that we couldn't read that file to the user, and put more information in the log.
Fixes Sentry issue CURA-NH.