mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 14:37:29 -06:00
Make sure the preferences file doesn't always get upgraded
When the setting is equal to the default the setting_version won't get written to the preferences file. In that case the version upgrade system assumes that the setting_version was 0 or 1 and upgrades it. This makes sure that the setting is never equal to the default so that it always gets written. Found while working on CURA-4024.
This commit is contained in:
parent
f0d327c0d0
commit
9bfe18393f
1 changed files with 2 additions and 1 deletions
|
@ -268,7 +268,8 @@ class CuraApplication(QtApplication):
|
|||
ContainerRegistry.getInstance().load()
|
||||
|
||||
# set the setting version for Preferences
|
||||
Preferences.getInstance().addPreference("metadata/setting_version", CuraApplication.SettingVersion)
|
||||
Preferences.getInstance().addPreference("metadata/setting_version", 0)
|
||||
Preferences.getInstance().setValue("metadata/setting_version", self.SettingVersion) #Don't make it equal to the default so that the setting version always gets written to the file.
|
||||
|
||||
Preferences.getInstance().addPreference("cura/active_mode", "simple")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue