diff options
Diffstat (limited to 'source/blender/editors/space_file/filelist.h')
-rw-r--r-- | source/blender/editors/space_file/filelist.h | 48 |
1 files changed, 31 insertions, 17 deletions
diff --git a/source/blender/editors/space_file/filelist.h b/source/blender/editors/space_file/filelist.h index 83f7718f0de..d70faab1d6a 100644 --- a/source/blender/editors/space_file/filelist.h +++ b/source/blender/editors/space_file/filelist.h @@ -40,9 +40,10 @@ extern "C" { struct BlendHandle; struct FileList; struct FileSelection; -struct direntry; struct wmWindowManager; +struct FileDirEntry; + typedef enum FileSelType { FILE_SEL_REMOVE = 0, FILE_SEL_ADD = 1, @@ -65,11 +66,10 @@ int folderlist_clear_next(struct SpaceFile *sfile); void filelist_setsorting(struct FileList *filelist, const short sort); -bool filelist_need_sorting(struct FileList *filelist); void filelist_sort(struct FileList *filelist); void filelist_setfilter_options(struct FileList *filelist, const bool hide_dot, const bool hide_parent, - const unsigned int filter, + const unsigned int filter, const unsigned int filter_id, const char *filter_glob, const char *filter_search); void filelist_filter(struct FileList *filelist); @@ -77,34 +77,48 @@ void filelist_init_icons(void); void filelist_free_icons(void); void filelist_imgsize(struct FileList *filelist, short w, short h); struct ImBuf * filelist_getimage(struct FileList *filelist, const int index); -struct ImBuf * filelist_geticon(struct FileList *filelist, const int index); +struct ImBuf * filelist_geticon_image(struct FileList *filelist, const int index); +int filelist_geticon(struct FileList *filelist, const int index, const bool is_main); struct FileList * filelist_new(short type); +void filelist_clear(struct FileList *filelist); +void filelist_clear_ex(struct FileList *filelist, const bool do_cache, const bool do_selection); void filelist_free(struct FileList *filelist); const char * filelist_dir(struct FileList *filelist); -void filelist_readdir(struct FileList *filelist); -void filelist_setdir(struct FileList *filelist, const char *dir); +void filelist_setdir(struct FileList *filelist, char *r_dir); +int filelist_files_ensure(struct FileList *filelist); int filelist_empty(struct FileList *filelist); -int filelist_numfiles(struct FileList *filelist); -struct direntry * filelist_file(struct FileList *filelist, int index); -int filelist_find(struct FileList *filelist, const char *file); +FileDirEntry * filelist_file(struct FileList *filelist, int index); +int filelist_file_findpath(struct FileList *filelist, const char *file); +FileDirEntry * filelist_entry_find_uuid(struct FileList *filelist, const int uuid[4]); +void filelist_file_cache_slidingwindow_set(struct FileList *filelist, size_t window_size); +bool filelist_file_cache_block(struct FileList *filelist, const int index); + +bool filelist_force_reset(struct FileList *filelist); +bool filelist_pending(struct FileList *filelist); +bool filelist_is_ready(struct FileList *filelist); -short filelist_changed(struct FileList *filelist); +unsigned int filelist_entry_select_set(const struct FileList *filelist, const struct FileDirEntry *entry, FileSelType select, unsigned int flag, FileCheckType check); +void filelist_entry_select_index_set(struct FileList *filelist, const int index, FileSelType select, unsigned int flag, FileCheckType check); +void filelist_entries_select_index_range_set(struct FileList *filelist, FileSelection *sel, FileSelType select, unsigned int flag, FileCheckType check); +unsigned int filelist_entry_select_get(struct FileList *filelist, struct FileDirEntry *entry, FileCheckType check); +unsigned int filelist_entry_select_index_get(struct FileList *filelist, const int index, FileCheckType check); -void filelist_select(struct FileList *filelist, FileSelection *sel, FileSelType select, unsigned int flag, FileCheckType check); -void filelist_select_file(struct FileList *filelist, int index, FileSelType select, unsigned int flag, FileCheckType check); -bool filelist_is_selected(struct FileList *filelist, int index, FileCheckType check); +void filelist_setrecursion(struct FileList *filelist, const int recursion_level); struct BlendHandle *filelist_lib(struct FileList *filelist); bool filelist_islibrary(struct FileList *filelist, char *dir, char **group); void filelist_freelib(struct FileList *filelist); -bool filelist_need_thumbnails(struct FileList *filelist); -void thumbnails_start(struct FileList *filelist, const struct bContext *C); -void thumbnails_stop(struct wmWindowManager *wm, struct FileList *filelist); -int thumbnails_running(struct wmWindowManager *wm, struct FileList *filelist); +void filelist_readjob_start(struct FileList *filelist, const struct bContext *C); +void filelist_readjob_stop(struct wmWindowManager *wm, struct ScrArea *sa); +int filelist_readjob_running(struct wmWindowManager *wm, struct ScrArea *sa); + +bool filelist_cache_previews_update(struct FileList *filelist); +void filelist_cache_previews_set(struct FileList *filelist, const bool use_previews); +bool filelist_cache_previews_running(struct FileList *filelist); #ifdef __cplusplus } |