diff options
author | Sybren A. Stüvel <sybren@blender.org> | 2021-09-30 18:30:30 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@blender.org> | 2021-09-30 18:34:58 +0300 |
commit | dd3391dd996e90fba3227c1cc2b50f4ef490ccdb (patch) | |
tree | 5a60f7589bb36be75f7bd1624925ef3f281bd927 /source/blender/blenkernel/BKE_asset_catalog.hh | |
parent | 4389067929d9a57923b7a85ec29b8ca9633fef29 (diff) |
Asset Catalogs: create missing parent catalogs
For every known catalog, ensure its parent catalog also exists. This
ensures that assets can be assigned to parent catalogs, even when they
didn't exist in the Catalog Definition File yet.
Diffstat (limited to 'source/blender/blenkernel/BKE_asset_catalog.hh')
-rw-r--r-- | source/blender/blenkernel/BKE_asset_catalog.hh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_asset_catalog.hh b/source/blender/blenkernel/BKE_asset_catalog.hh index 9d179011b25..a0bc1267826 100644 --- a/source/blender/blenkernel/BKE_asset_catalog.hh +++ b/source/blender/blenkernel/BKE_asset_catalog.hh @@ -150,6 +150,11 @@ class AssetCatalogService { std::unique_ptr<AssetCatalogTree> read_into_tree(); void rebuild_tree(); + + /** + * For every catalog, ensure that its parent path also has a known catalog. + */ + void create_missing_catalogs(); }; /** |