|
Blender V4.3
|
Inherits blender::NonCopyable.
Public Member Functions | |
| AssetList ()=delete | |
| AssetList (AssetList &&other)=default | |
| ~AssetList ()=default | |
Asset list API | |
Internally re-uses FileList from the File Browser. It does all the heavy lifting already. | |
| AssetList (eFileSelectType filesel_type, const AssetLibraryReference &asset_library_ref) | |
| void | setup () |
| void | fetch (const bContext &C) |
| void | update_previews (const bContext &C) |
| void | clear (const bContext *C) |
| AssetHandle | asset_get_by_index (int index) const |
| void | previews_job_update (const bContext *C) |
| bool | needs_refetch () const |
| bool | is_loaded () const |
| bool | is_asset_preview_loading (const AssetHandle &asset) const |
| void | ensure_asset_preview_requested (const bContext &C, AssetHandle &asset) |
| asset_system::AssetLibrary * | asset_library () const |
| void | iterate (AssetListHandleIterFn fn, FunctionRef< bool(asset_system::AssetRepresentation &)> prefilter_fn) const |
| void | iterate (AssetListIterFn fn) const |
| int | size () const |
| void | tag_main_data_dirty () const |
| void | remap_id (ID *id_old, ID *id_new) const |
| static bool | listen (const wmNotifier ¬ifier) |
Definition at line 102 of file asset_list.cc.
|
delete |
| blender::ed::asset::list::AssetList::AssetList | ( | eFileSelectType | filesel_type, |
| const AssetLibraryReference & | asset_library_ref ) |
Definition at line 136 of file asset_list.cc.
|
default |
|
default |
| AssetHandle blender::ed::asset::list::AssetList::asset_get_by_index | ( | int | index | ) | const |
Definition at line 311 of file asset_list.cc.
References filelist_file().
| asset_system::AssetLibrary * blender::ed::asset::list::AssetList::asset_library | ( | ) | const |
Definition at line 228 of file asset_list.cc.
References filelist_asset_library().
| void blender::ed::asset::list::AssetList::clear | ( | const bContext * | C | ) |
Definition at line 298 of file asset_list.cc.
References CTX_wm_manager(), filelist_clear(), filelist_freelib(), filelist_readjob_stop(), filelist_tag_force_reset(), NC_ASSET, ND_ASSET_LIST, and WM_main_add_notifier().
| void blender::ed::asset::list::AssetList::ensure_asset_preview_requested | ( | const bContext & | C, |
| AssetHandle & | asset ) |
Definition at line 211 of file asset_list.cc.
References blender::ed::asset::list::PreviewTimer::ensure_running(), AssetHandle::file_data, filelist_cache_previews_set(), and filelist_file_ensure_preview_requested().
| void blender::ed::asset::list::AssetList::fetch | ( | const bContext & | C | ) |
Definition at line 173 of file asset_list.cc.
References CTX_wm_manager(), filelist_clear_from_reset_tag(), filelist_filter(), filelist_needs_force_reset(), filelist_needs_reading(), filelist_pending(), filelist_readjob_start(), filelist_readjob_stop(), filelist_sort(), NC_ASSET, and ND_ASSET_LIST_READING.
| bool blender::ed::asset::list::AssetList::is_asset_preview_loading | ( | const AssetHandle & | asset | ) | const |
Definition at line 223 of file asset_list.cc.
References AssetHandle::file_data, and filelist_file_is_preview_pending().
| bool blender::ed::asset::list::AssetList::is_loaded | ( | ) | const |
Definition at line 206 of file asset_list.cc.
References filelist_is_ready().
| void blender::ed::asset::list::AssetList::iterate | ( | AssetListHandleIterFn | fn, |
| FunctionRef< bool(asset_system::AssetRepresentation &)> | prefilter_fn ) const |
Definition at line 233 of file asset_list.cc.
References filelist_entry_get_asset_representation(), filelist_file(), and filelist_files_ensure().
| void blender::ed::asset::list::AssetList::iterate | ( | AssetListIterFn | fn | ) | const |
Definition at line 259 of file asset_list.cc.
References filelist_entry_get_asset_representation(), and filelist_files_ensure().
|
static |
Definition at line 319 of file asset_list.cc.
References wmNotifier::action, wmNotifier::category, wmNotifier::data, ELEM, NA_ADDED, NA_EDITED, NA_REMOVED, NA_RENAME, NC_ASSET, NC_ID, ND_ASSET_LIST, ND_ASSET_LIST_PREVIEW, and ND_ASSET_LIST_READING.
Referenced by blender::ed::asset::list::listen().
| bool blender::ed::asset::list::AssetList::needs_refetch | ( | ) | const |
Definition at line 201 of file asset_list.cc.
References filelist_needs_force_reset(), and filelist_needs_reading().
| void blender::ed::asset::list::AssetList::previews_job_update | ( | const bContext * | C | ) |
Definition at line 276 of file asset_list.cc.
References blender::ed::asset::list::PreviewTimer::ensure_running(), filelist_cache_previews_done(), filelist_cache_previews_enabled(), filelist_cache_previews_running(), and blender::ed::asset::list::PreviewTimer::stop().
Referenced by update_previews().
Definition at line 356 of file asset_list.cc.
References tag_main_data_dirty().
| void blender::ed::asset::list::AssetList::setup | ( | ) |
Definition at line 141 of file asset_list.cc.
References AS_asset_library_root_path_from_library_ref(), blender::ed::asset::index::file_indexer_asset, file_indexer_noop, FILE_MAX_LIBEXTRA, FILE_SELECT_MAX_RECURSIONS, FILE_SORT_ASSET_CATALOG, FILE_TYPE_BLENDERLIB, filelist_set_no_preview_auto_cache(), filelist_setdir(), filelist_setfilter_options(), filelist_setindexer(), filelist_setlibrary(), filelist_setrecursion(), filelist_setsorting(), FILTER_ID_ALL, STRNCPY, and USER_EXPERIMENTAL_TEST.
| int blender::ed::asset::list::AssetList::size | ( | ) | const |
Definition at line 344 of file asset_list.cc.
References filelist_files_ensure().
| void blender::ed::asset::list::AssetList::tag_main_data_dirty | ( | ) | const |
Definition at line 349 of file asset_list.cc.
References filelist_needs_reset_on_main_changes(), and filelist_tag_force_reset_mainfiles().
Referenced by remap_id().
| void blender::ed::asset::list::AssetList::update_previews | ( | const bContext & | C | ) |
Definition at line 191 of file asset_list.cc.
References filelist_cache_previews_enabled(), filelist_cache_previews_update(), and previews_job_update().