diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-05-13 08:59:27 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-05-13 09:29:35 +0300 |
commit | 741f29d499eaaa5c10be218a632f9b6fab67840e (patch) | |
tree | af5ff8dfab8c97b599a1c8af17e4fdbd9fd6480a /source/blender/blenloader | |
parent | 3d923f3eaf998ebd73f6c93eb87a05288b579e22 (diff) |
Preferences: auto-save on exit
Save modified preferences on exit by default,
with the option to disable this.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r-- | source/blender/blenloader/intern/versioning_userdef.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/source/blender/blenloader/intern/versioning_userdef.c b/source/blender/blenloader/intern/versioning_userdef.c index 6ac0e8f2c74..24eac507945 100644 --- a/source/blender/blenloader/intern/versioning_userdef.c +++ b/source/blender/blenloader/intern/versioning_userdef.c @@ -43,7 +43,7 @@ /* Disallow access to global userdef. */ #define U (_error_) -static void do_versions_theme(UserDef *userdef, bTheme *btheme) +static void do_versions_theme(const UserDef *userdef, bTheme *btheme) { #define USER_VERSION_ATLEAST(ver, subver) MAIN_VERSION_ATLEAST(userdef, ver, subver) @@ -580,10 +580,7 @@ void BLO_version_defaults_userpref_blend(Main *bmain, UserDef *userdef) } } - /** - * Include next version bump. - */ - { + if (!USER_VERSION_ATLEAST(280, 62)) { /* (keep this block even if it becomes empty). */ if (userdef->vbotimeout == 0) { userdef->vbocollectrate = 60; @@ -593,6 +590,15 @@ void BLO_version_defaults_userpref_blend(Main *bmain, UserDef *userdef) if (userdef->lookdev_sphere_size == 0) { userdef->lookdev_sphere_size = 150; } + + userdef->pref_flag |= USER_PREF_FLAG_SAVE; + } + + /** + * Include next version bump. + */ + { + /* pass */ } if (userdef->pixelsize == 0.0f) { |