diff options
author | Julian Eisel <julian@blender.org> | 2021-07-21 20:22:44 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2021-07-21 20:35:39 +0300 |
commit | 10e28bd27017664064b1fb93f1ed347d6b404ae6 (patch) | |
tree | 32408fee2bad70af7eeb66f3f189cef8ae7612ee /source/blender/editors/asset | |
parent | 8de2b6a02020ad0bc4e4ad7868988a37251e3f88 (diff) |
Assets: Replace duplicated asset library reference type from DNA
Since recently it's possible to access assets from outside the
File/Asset Browser, via the asset view template. So we are slowly
moving away from file space specific code to dedicated asset system
code. I introduced `AssetLibraryReference` as a duplicate of
`FileSelectAssetLibraryUID`, with a plan to delete the latter in a
separate cleanup commit. That's exactly what this commit is.
This will cause Asset Browsers to open with the default "Current File"
Asset Library. We could avoid that, but it's a minor issue really.
Diffstat (limited to 'source/blender/editors/asset')
-rw-r--r-- | source/blender/editors/asset/asset_list.cc | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/source/blender/editors/asset/asset_list.cc b/source/blender/editors/asset/asset_list.cc index e610a1dfbcd..9e611edd715 100644 --- a/source/blender/editors/asset/asset_list.cc +++ b/source/blender/editors/asset/asset_list.cc @@ -143,11 +143,6 @@ void AssetList::setup(const AssetFilterSettings *filter_settings) { FileList *files = filelist_; - /* TODO there should only be one (FileSelectAssetLibraryUID vs. AssetLibraryReference). */ - FileSelectAssetLibraryUID file_asset_lib_ref; - file_asset_lib_ref.type = library_ref_.type; - file_asset_lib_ref.custom_library_index = library_ref_.custom_library_index; - bUserAssetLibrary *user_library = nullptr; /* Ensure valid repository, or fall-back to local one. */ @@ -162,7 +157,7 @@ void AssetList::setup(const AssetFilterSettings *filter_settings) /* TODO pass options properly. */ filelist_setrecursion(files, 1); filelist_setsorting(files, FILE_SORT_ALPHA, false); - filelist_setlibrary(files, &file_asset_lib_ref); + filelist_setlibrary(files, &library_ref_); /* TODO different filtering settings require the list to be reread. That's a no-go for when we * want to allow showing the same asset library with different filter settings (as in, * different ID types). The filelist needs to be made smarter somehow, maybe goes together with |