diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-10-02 13:11:51 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-10-02 13:21:27 +0300 |
commit | d1f6c2e7bb59e12f381bffdbaf8274936f404b7e (patch) | |
tree | 797bf49c87aa1b336f7f9c8bf602465f89671c7a /source/blender/editors | |
parent | 34228d138b79e9ad6cdbded4bc5df1eefb1aad1c (diff) |
Fix userpref.blend using version from startup.blend
Version patching userpref.blend wasn't using the correct version,
causing settings not to be properly updated.
This seems the likely cause of T70196 and similar bugs.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/include/UI_interface.h | 2 | ||||
-rw-r--r-- | source/blender/editors/interface/interface.c | 4 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_intern.h | 2 | ||||
-rw-r--r-- | source/blender/editors/interface/resources.c | 4 |
4 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h index 5fcde98f200..972c741f061 100644 --- a/source/blender/editors/include/UI_interface.h +++ b/source/blender/editors/include/UI_interface.h @@ -1752,7 +1752,7 @@ void UI_popup_handlers_remove_all(struct bContext *C, struct ListBase *handlers) * be used to reinitialize some internal state if user preferences change. */ void UI_init(void); -void UI_init_userdef(struct Main *bmain); +void UI_init_userdef(void); void UI_reinit_font(void); void UI_exit(void); diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c index 25354c30c62..d93d80bb4ef 100644 --- a/source/blender/editors/interface/interface.c +++ b/source/blender/editors/interface/interface.c @@ -7059,10 +7059,10 @@ void UI_init(void) } /* after reading userdef file */ -void UI_init_userdef(Main *bmain) +void UI_init_userdef(void) { /* fix saved themes */ - init_userdef_do_versions(bmain); + init_userdef_do_versions(); uiStyleInit(); BLO_sanitize_experimental_features_userpref_blend(&U); diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h index 60d60102736..91a71b0ca28 100644 --- a/source/blender/editors/interface/interface_intern.h +++ b/source/blender/editors/interface/interface_intern.h @@ -996,7 +996,7 @@ void icon_draw_rect_input( float x, float y, int w, int h, float alpha, short event_type, short event_value); /* resources.c */ -void init_userdef_do_versions(struct Main *bmain); +void init_userdef_do_versions(void); void ui_resources_init(void); void ui_resources_free(void); diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c index 76ad3981586..1601d9914a3 100644 --- a/source/blender/editors/interface/resources.c +++ b/source/blender/editors/interface/resources.c @@ -1501,9 +1501,9 @@ void UI_make_axis_color(const uchar src_col[3], uchar dst_col[3], const char axi } /* patching UserDef struct and Themes */ -void init_userdef_do_versions(Main *bmain) +void init_userdef_do_versions(void) { - BLO_version_defaults_userpref_blend(bmain, &U); + BLO_version_defaults_userpref_blend(&U); if (STREQ(U.tempdir, "/")) { BKE_tempdir_system_init(U.tempdir); |