diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-11-25 04:45:12 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-11-25 04:51:23 +0400 |
commit | c5944812d69f04b48f982402a4e5518edb398ef0 (patch) | |
tree | 133d5d9ff8c8e5ae73c9d9eee48b537f14c25be5 /source/blender/editors | |
parent | 9c262e5649303eff26e7645079185c250e4420ff (diff) |
User Defaults: Change user defaults based on decission by new UI team - T37518
Currently these changes are not saved in startup.blend to avoid bloating
our repo whenever we want to make minor changes.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/include/UI_interface.h | 1 | ||||
-rw-r--r-- | source/blender/editors/interface/interface.c | 5 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_intern.h | 1 | ||||
-rw-r--r-- | source/blender/editors/interface/resources.c | 20 |
4 files changed, 27 insertions, 0 deletions
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h index 0786f266735..665c4dd743f 100644 --- a/source/blender/editors/include/UI_interface.h +++ b/source/blender/editors/include/UI_interface.h @@ -687,6 +687,7 @@ void UI_remove_popup_handlers_all(struct bContext *C, struct ListBase *handlers) void UI_init(void); void UI_init_userdef(void); +void UI_init_userdef_factory(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 3f48446f029..74d439d817f 100644 --- a/source/blender/editors/interface/interface.c +++ b/source/blender/editors/interface/interface.c @@ -4194,6 +4194,11 @@ void UI_init_userdef(void) uiStyleInit(); } +void UI_init_userdef_factory(void) +{ + init_userdef_factory(); +} + void UI_reinit_font(void) { uiStyleInit(); diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h index 9287385a329..3cee9a79971 100644 --- a/source/blender/editors/interface/interface_intern.h +++ b/source/blender/editors/interface/interface_intern.h @@ -562,6 +562,7 @@ int ui_id_icon_get(struct bContext *C, struct ID *id, const bool big); /* resources.c */ void init_userdef_do_versions(void); +void init_userdef_factory(void); void ui_theme_init_default(void); void ui_style_init_default(void); void ui_resources_init(void); diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c index 55b353b1031..750d219e766 100644 --- a/source/blender/editors/interface/resources.c +++ b/source/blender/editors/interface/resources.c @@ -2246,3 +2246,23 @@ void init_userdef_do_versions(void) // XXX reset_autosave(); } + +/** + * Override values in in-memory startup.blend, avoids resaving for small changes. + */ +void init_userdef_factory(void) +{ + /* defaults from T37518 */ + U.uiflag2 |= USER_REGION_OVERLAP; + + U.uiflag |= USER_AUTOPERSP; + U.uiflag |= USER_ORBIT_SELECTION; + U.uiflag |= USER_ZBUF_CURSOR; + U.uiflag |= USER_QUIT_PROMPT; + U.uiflag |= USER_CONTINUOUS_MOUSE; + + U.ogl_multisamples = USER_MULTISAMPLE_4; + + U.versions = 1; + U.savetime = 2; +} |