Experimental Features: More robust way of sanitizing options

This commit is contained in:
Dalai Felinto 2020-10-02 12:57:23 +02:00
parent cb363953f0
commit 74ea369830
Notes: blender-bot 2023-04-14 09:18:04 +02:00
Referenced by issue #81357, Some Experimental Features are still accessible in 2.90.1; Sculpt vertex colors, etc.
2 changed files with 6 additions and 7 deletions

View File

@ -824,11 +824,8 @@ void BLO_sanitize_experimental_features_userpref_blend(UserDef *userdef)
if (BKE_blender_version_is_alpha()) {
return;
}
userdef->experimental.use_new_particle_system = false;
userdef->experimental.use_new_hair_type = false;
userdef->experimental.use_sculpt_vertex_colors = false;
userdef->experimental.use_tools_missing_icons = false;
userdef->experimental.use_switch_object_operator = false;
MEMSET_STRUCT_AFTER(&userdef->experimental, 0, SANITIZE_AFTER_HERE);
}
#undef USER_LMOUSESELECT

View File

@ -626,13 +626,15 @@ typedef struct UserDef_Experimental {
char use_undo_legacy;
char use_cycles_debug;
char use_image_editor_legacy_drawing;
/* Other options - remember to turn them off on
* BLO_sanitize_experimental_features_userpref_blend. */
char SANITIZE_AFTER_HERE;
/* The following options are automatically sanitized (set to 0)
* when the release cycle is not alpha. */
char use_new_particle_system;
char use_new_hair_type;
char use_sculpt_vertex_colors;
char use_tools_missing_icons;
char use_switch_object_operator;
char _pad[7];
} UserDef_Experimental;
#define USER_EXPERIMENTAL_TEST(userdef, member) \