forked from bartvdbraak/blender
UI: Remove User Preference "Enable All Experimental Features"
Users should be able to know explicitly what they are testing. By having them all enabled we run into a scenario where a new experimental feature may have been introduced, and the user is now using it without being even aware of that. Differential Revision: https://developer.blender.org/D6404
This commit is contained in:
parent
31a3b57037
commit
afcdea3961
@ -2176,28 +2176,12 @@ class ExperimentalPanel:
|
||||
self.draw_props(context, layout)
|
||||
|
||||
|
||||
class USERPREF_PT_experimental_all(ExperimentalPanel, Panel):
|
||||
bl_label = "All"
|
||||
bl_options = {'HIDE_HEADER'}
|
||||
|
||||
def draw_props(self, context, layout):
|
||||
prefs = context.preferences
|
||||
experimental = prefs.experimental
|
||||
|
||||
col = layout.column()
|
||||
col.prop(experimental, "use_experimental_all")
|
||||
|
||||
# For the other settings create new panels
|
||||
# and make sure they are disabled if use_experimental_all is True
|
||||
|
||||
|
||||
class USERPREF_PT_experimental_ui(ExperimentalPanel, Panel):
|
||||
bl_label = "User Interface"
|
||||
|
||||
def draw_props(self, context, layout):
|
||||
prefs = context.preferences
|
||||
experimental = prefs.experimental
|
||||
layout.active = not experimental.use_experimental_all
|
||||
|
||||
task = "T66304"
|
||||
split = layout.split(factor=0.66)
|
||||
@ -2217,7 +2201,6 @@ class USERPREF_PT_experimental_virtual_reality(ExperimentalPanel, Panel):
|
||||
def draw_props(self, context, layout):
|
||||
prefs = context.preferences
|
||||
experimental = prefs.experimental
|
||||
layout.active = not experimental.use_experimental_all
|
||||
|
||||
task = "T71347"
|
||||
split = layout.split(factor=0.66)
|
||||
@ -2316,7 +2299,6 @@ classes = (
|
||||
USERPREF_PT_studiolight_matcaps,
|
||||
USERPREF_PT_studiolight_world,
|
||||
|
||||
USERPREF_PT_experimental_all,
|
||||
USERPREF_PT_experimental_ui,
|
||||
|
||||
# Popovers.
|
||||
|
@ -601,17 +601,13 @@ typedef struct UserDef_FileSpaceData {
|
||||
} UserDef_FileSpaceData;
|
||||
|
||||
typedef struct UserDef_Experimental {
|
||||
/** #eUserPref_Experimental_Flag options. */
|
||||
int flag;
|
||||
|
||||
char use_tool_fallback;
|
||||
|
||||
char _pad0[3];
|
||||
char _pad0[7];
|
||||
} UserDef_Experimental;
|
||||
|
||||
#define USER_EXPERIMENTAL_TEST(userdef, member) \
|
||||
(((userdef)->flag & USER_DEVELOPER_UI) && \
|
||||
(((userdef)->experimental.flag & USER_EXPERIMENTAL_ALL) || ((userdef)->experimental).member))
|
||||
(((userdef)->flag & USER_DEVELOPER_UI) && ((userdef)->experimental).member)
|
||||
|
||||
typedef struct UserDef {
|
||||
/** UserDef has separate do-version handling, and can be read from other files. */
|
||||
@ -908,11 +904,6 @@ typedef enum eUserPref_SpaceData_Flag {
|
||||
USER_SPACEDATA_ADDONS_SHOW_ONLY_ENABLED = (1 << 1),
|
||||
} eUserPref_SpaceData_Flag;
|
||||
|
||||
/** #UserDef_Experimental.flag. */
|
||||
typedef enum eUserPref_Experimental_Flag {
|
||||
USER_EXPERIMENTAL_ALL = (1 << 0),
|
||||
} eUserPref_Experimental_Flag;
|
||||
|
||||
/** #UserDef.flag */
|
||||
typedef enum eUserPref_Flag {
|
||||
USER_AUTOSAVE = (1 << 0),
|
||||
|
@ -5858,13 +5858,6 @@ static void rna_def_userdef_experimental(BlenderRNA *brna)
|
||||
RNA_def_struct_clear_flag(srna, STRUCT_UNDO);
|
||||
RNA_def_struct_ui_text(srna, "Experimental", "Experimental features");
|
||||
|
||||
prop = RNA_def_property(srna, "use_experimental_all", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", USER_EXPERIMENTAL_ALL);
|
||||
RNA_def_property_ui_text(prop,
|
||||
"All Experimental Features",
|
||||
"Expose all the experimental features in the user interface");
|
||||
RNA_def_property_update(prop, 0, "rna_userdef_update");
|
||||
|
||||
prop = RNA_def_property(srna, "use_tool_fallback", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "use_tool_fallback", 1);
|
||||
RNA_def_property_boolean_funcs(prop, "rna_userdef_experimental_use_tool_fallback_get", NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user