mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-19 04:37:51 -06:00
Upgrade quality profile names
These files have been renamed. Contributes to issue CURA-5177.
This commit is contained in:
parent
049bab1341
commit
50b4bac672
1 changed files with 9 additions and 0 deletions
|
@ -53,6 +53,11 @@ _EXTRUDER_TO_POSITION = {
|
|||
"vertex_k8400_dual_2nd": 1
|
||||
}
|
||||
|
||||
_RENAMED_QUALITY_PROFILES = {
|
||||
"low": "fast",
|
||||
"um2_low": "um2_fast"
|
||||
}
|
||||
|
||||
## Upgrades configurations from the state they were in at version 3.2 to the
|
||||
# state they should be in at version 3.3.
|
||||
class VersionUpgrade32to33(VersionUpgrade):
|
||||
|
@ -94,6 +99,10 @@ class VersionUpgrade32to33(VersionUpgrade):
|
|||
#Update version number.
|
||||
parser["general"]["version"] = "4"
|
||||
|
||||
#Update the name of the quality profile.
|
||||
if parser["containers"]["2"] in _RENAMED_QUALITY_PROFILES:
|
||||
parser["containers"]["2"] = _RENAMED_QUALITY_PROFILES[parser["containers"]["2"]]
|
||||
|
||||
result = io.StringIO()
|
||||
parser.write(result)
|
||||
return [filename], [result.getvalue()]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue