diff options
author | Julian Eisel <julian@blender.org> | 2021-01-13 02:52:10 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2021-01-13 13:10:17 +0300 |
commit | aed5b88ec1a651faad5f4a95828e1b9d907f0af4 (patch) | |
tree | bafe6858a775e4d359dec83be540b18307aec163 /source/blender/editors/asset | |
parent | 27b78c9c94baf6fa43268e851de58da96f7d7123 (diff) |
Asset System: Disable Asset Browser as experimental feature
The Asset Browser will be disabled and not available for the 2.92 release. In
alpha/beta builds, there will be an "Asset Browser" option under Preferences >
Experimental, if the developer extras are enabled.
Note that this also disables related UI elements (e.g. "Mark Asset" buttons,
Preferences settings for asset libraries, etc.).
The code is still in master of course, development and testing will continue
there. But there simply needs to be too much polishing and fixing before the
2.92 release, plus there are some design decisions to be reevaluated.
Check the milestone 1 project to follow ongoing work:
https://developer.blender.org/project/view/124/
Diffstat (limited to 'source/blender/editors/asset')
-rw-r--r-- | source/blender/editors/asset/asset_ops.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/editors/asset/asset_ops.c b/source/blender/editors/asset/asset_ops.c index 929d49e19fa..29c3174f051 100644 --- a/source/blender/editors/asset/asset_ops.c +++ b/source/blender/editors/asset/asset_ops.c @@ -26,8 +26,10 @@ #include "BLI_listbase.h" #include "BLI_string_utils.h" +#include "BLI_utildefines.h" #include "DNA_asset_types.h" +#include "DNA_userdef_types.h" #include "ED_asset.h" @@ -47,6 +49,11 @@ struct AssetMarkResultStats { ID *last_id; }; +static bool asset_ops_poll(bContext *UNUSED(C)) +{ + return U.experimental.use_asset_browser; +} + /** * Return the IDs to operate on as list of #CollectionPointerLink links. Needs freeing. */ @@ -146,6 +153,7 @@ static void ASSET_OT_mark(wmOperatorType *ot) ot->idname = "ASSET_OT_mark"; ot->exec = asset_mark_exec; + ot->poll = asset_ops_poll; ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; } @@ -225,6 +233,7 @@ static void ASSET_OT_clear(wmOperatorType *ot) ot->idname = "ASSET_OT_clear"; ot->exec = asset_clear_exec; + ot->poll = asset_ops_poll; ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; } |