Blender Git Commit Log
Git Commits -> Revision cf08846
Revision cf08846 by Julian Eisel (asset-browser) December 2, 2020, 21:18 (GMT) |
Asset Browser: Internal File Browser changes & Python API additions The Asset Browser will be a sub-editor of the File Browser. This prepares the File Browser code for that. **File-Lists** * Support loading assets with metadata read from external files into the file-list. * New main based file-list type, for the "Current File" asset repository. * Refresh file-list when switching between browse modes or asset repositories. * Support empty file-lists (repository with no assets). * Store file previews as icons, so scripts can reference them via icon-id. See D9719. **Space Data** * Introduce "browse mode" to differeniate between file and asset browsing. * Add `FileAssetSelectParams` to `SpaceFile`, with `FileSelectParams` as base. Makes sure data is separated between asset and file browsing when switching between them. The active params can be obtained through `ED_fileselect_get_active_params()`. * `FileAssetSelectParams` stores the currently visible repository ID. * Introduce file history abstraction so file and asset browsing can keep a separate history (previous and next directories). **General** * Option to only show asset data-blocks while file browsing (not exposed here). * Add "active_file" context member, so scripts can get and display info about the active file. * Add "active_id" context member, so `ED_OT_lib_id_load_custom_preview` can set a custom ID preview. (Only for "Current File" repository) * Expose some of `FileDirEntry` in RNA as (non-editable). That way scripts can obtain name, preview icon and asset-data. Differential Revision: https://developer.blender.org/D9724 |
Commit Details:
Full Hash: cf0884632a1863cb8f00af5b75e02364903765cd
Parent Commit: 13d24d5
Lines Changed: +1274, -437
18 Modified Paths:
/source/blender/blenkernel/intern/screen.c (+5, -0) (Diff)
/source/blender/blenlib/intern/path_util.c (+4, -0) (Diff)
/source/blender/blenloader/intern/readblenentry.c (+2, -2) (Diff)
/source/blender/editors/include/ED_fileselect.h (+7, -4) (Diff)
/source/blender/editors/space_file/filelist.c (+458, -137) (Diff)
/source/blender/editors/space_file/filelist.h (+18, -5) (Diff)
/source/blender/editors/space_file/filesel.c (+183, -68) (Diff)
/source/blender/editors/space_file/file_draw.c (+23, -21) (Diff)
/source/blender/editors/space_file/file_intern.h (+1, -0) (Diff)
/source/blender/editors/space_file/file_ops.c (+157, -151) (Diff)
/source/blender/editors/space_file/file_panels.c (+1, -1) (Diff)
/source/blender/editors/space_file/space_file.c (+78, -29) (Diff)
/source/blender/makesdna/DNA_space_types.h (+114, -17) (Diff)
/source/blender/makesrna/intern/rna_space.c (+217, -1) (Diff)
/source/blender/makesrna/RNA_access.h (+1, -0) (Diff)
/source/blender/makesrna/RNA_enum_types.h (+1, -0) (Diff)
/source/blender/windowmanager/intern/wm_operators.c (+2, -1) (Diff)
/source/blender/windowmanager/intern/wm_operator_props.c (+2, -0) (Diff)
/source/blender/blenlib/intern/path_util.c (+4, -0) (Diff)
/source/blender/blenloader/intern/readblenentry.c (+2, -2) (Diff)
/source/blender/editors/include/ED_fileselect.h (+7, -4) (Diff)
/source/blender/editors/space_file/filelist.c (+458, -137) (Diff)
/source/blender/editors/space_file/filelist.h (+18, -5) (Diff)
/source/blender/editors/space_file/filesel.c (+183, -68) (Diff)
/source/blender/editors/space_file/file_draw.c (+23, -21) (Diff)
/source/blender/editors/space_file/file_intern.h (+1, -0) (Diff)
/source/blender/editors/space_file/file_ops.c (+157, -151) (Diff)
/source/blender/editors/space_file/file_panels.c (+1, -1) (Diff)
/source/blender/editors/space_file/space_file.c (+78, -29) (Diff)
/source/blender/makesdna/DNA_space_types.h (+114, -17) (Diff)
/source/blender/makesrna/intern/rna_space.c (+217, -1) (Diff)
/source/blender/makesrna/RNA_access.h (+1, -0) (Diff)
/source/blender/makesrna/RNA_enum_types.h (+1, -0) (Diff)
/source/blender/windowmanager/intern/wm_operators.c (+2, -1) (Diff)
/source/blender/windowmanager/intern/wm_operator_props.c (+2, -0) (Diff)