Page MenuHome

Asset Browser: Allow specific ID types to be enabled by default
ClosedPublic

Authored by Julian Eisel (Severin) on Oct 21 2021, 4:31 PM.

Details

Summary

Updates UI code so that we can enable the asset UI for specific ID types by default, i.e. irrespective of the "Extended Asset Browser" experimental feature.
Mark as Asset and Clear Asset are always visible in the Outliner context menu now, but are grayed out if not applicable and show a disabled hint in the tooltip.

Also enables Materials and World assets by default. More for testing, should be committed separately.

Open Issue:
With this it will be possible to mark regular actions as assets, even if they were not created as poses. Should we deal with that differently?

Diff Detail

Repository
rB Blender
Branch
temp-asset-browser-non-experimental-ids (branched from master)
Build Status
Buildable 18079
Build 18079: arc lint + arc unit

Event Timeline

Julian Eisel (Severin) requested review of this revision.Oct 21 2021, 4:31 PM
Julian Eisel (Severin) created this revision.
source/blender/editors/interface/interface_region_tooltip.c
963–966

This is a fix needed for tooltips to get the correct context from the button they are for. To be committed separately.

  • Merge branch 'master' into temp-asset-browser-non-experimental-ids
Julian Eisel (Severin) added inline comments.
source/blender/editors/interface/interface_region_tooltip.c
963–966

Done with rB594c857f652b.

  • Move alle experimental flag logic to ED
release/scripts/startup/bl_ui/space_outliner.py
316–318

Just always show the mark/clear context menu entries in the Outliner now. We could make it "smarter" and only show it when supported assets are selected. Then we'd have to move the menu back to C though, and I think having a disabled button with a disabled hint is nice.

LGTM, just some small pokes. Can be committed when those have been addressed.

release/scripts/startup/bl_ui/space_outliner.py
316–318

+1 on disabled + hint

source/blender/editors/asset/ED_asset_type.h
50 ↗(On Diff #43703)

Oxford comma: , or

50 ↗(On Diff #43703)

Add a note that this should start with a consonant, as it'll be prefixed with "a " in asset_operation_unsupported_type_msg

source/blender/editors/asset/intern/asset_ops.cc
74–84

Document what this is. The design is nice, but when reading the file from top to bottom this'll be a mystery.

source/blender/editors/asset/intern/asset_type.cc
31–32 ↗(On Diff #43703)

👍 👍

This revision is now accepted and ready to land.Oct 21 2021, 7:27 PM