62 const rcti *rect_region)
100 if ((sel->
first < 0) && (sel->
last >= 0)) {
104 if ((sel->
first >= numfiles) && ((sel->
last < 0) || (sel->
last >= numfiles))) {
110 if ((sel->
first > 0) && (sel->
last < 0)) {
111 sel->
last = numfiles - 1;
115 if ((sel->
first >= numfiles)) {
116 sel->
first = numfiles - 1;
118 if ((sel->
last >= numfiles)) {
119 sel->
last = numfiles - 1;
131 if (!((sel.
first == -1) && (sel.
last == -1))) {
136 if (fill && (sel.
last >= 0) && (sel.
last < numfiles)) {
139 for (f = sel.
last; f >= 0; f--) {
149 for (f = sel.
first; f < numfiles; f++) {
172 if ((selected_idx >= 0) && (selected_idx < numfiles) &&
174 params->highlight_file = selected_idx;
175 params->active_file = selected_idx;
180 if (do_diropen ==
false) {
192 if (
params->recursion_level > 1) {
194 params->recursion_level = 0;
198 else if (
file->redirection_path) {
230 for (i = 0; i < numfiles; i++) {
248 for (file_index = 0; file_index < numfiles; file_index++) {
251 selection.
first = file_index;
256 for (; file_index < numfiles; file_index++) {
258 selection.
last = file_index;
356 else if (sel.
last >= 0) {
376 const int mouse_xy[2])
379 rcti bounds_first, bounds_last;
380 int dist_first, dist_last;
381 float mouseco_view[2];
392 const int my_loc = (int)mouseco_view[1];
398 const int mx_loc = (int)mouseco_view[0];
403 return (dist_first < dist_last) ? sel->
first : sel->
last;
432 for (idx = sel.
last; idx >= 0; idx--) {
442 if (sel.
last == idx) {
443 params->highlight_file = idx;
452 params->highlight_file = -1;
498 ot->
description =
"Activate/select the file(s) contained in the border";
538 const bool only_activate_if_selected =
RNA_boolean_get(op->
ptr,
"only_activate_if_selected");
556 if (extend || fill) {
557 wait_to_deselect_others =
false;
564 int idx =
params->highlight_file;
567 if ((idx >= 0) && (idx < numfiles)) {
570 if (only_activate_if_selected && is_selected) {
573 else if (wait_to_deselect_others && is_selected) {
619 ot->
description =
"Handle mouse clicks to select and activate items";
634 "Extend selection instead of deselecting everything first");
637 ot->
srna,
"fill",
false,
"Fill",
"Select everything beginning with the last selection");
644 "Deselect On Nothing",
645 "Deselect all when nothing under the cursor");
648 "only_activate_if_selected",
650 "Only Activate if Selected",
651 "Do not change selection if the item under the cursor is already "
652 "selected, only activate it");
658 "Even on successful execution, pass the event on so other operators can "
659 "execute on it as well");
677 const int active_old,
678 const int active_new,
679 const int other_site,
680 const bool has_selection,
686 const int last_sel =
params->active_file;
688 bool deselect =
false;
702 deselect = (fill || other_site == -1 ||
707 params->active_file = active_new;
710 if (deselect && fill) {
750 params->highlight_file = -1;
802 const int active_old =
params->active_file;
819 active_new = active_old - 1;
820 other_site = active_old + 1;
824 active_new = active_old + 1;
825 other_site = active_old - 1;
829 active_new = active_old - idx_shift;
830 other_site = active_old + idx_shift;
835 active_new = active_old + idx_shift;
836 other_site = active_old - idx_shift;
842 if (!
IN_RANGE(active_new, -1, numfiles)) {
849 if (active_new != 0) {
851 active_new = active_old;
854 if (!
IN_RANGE(other_site, 0, numfiles)) {
893 ot->
name =
"Walk Select/Deselect File";
894 ot->
description =
"Select/Deselect files by walking through them";
908 "Extend selection instead of deselecting everything first");
911 ot->
srna,
"fill",
false,
"Fill",
"Select everything beginning with the last selection");
935 sel.
last = numfiles - 1;
963 for (
int i = 0; i < numfiles; i++) {
981 ot->
name =
"(De)select All Files";
1034 ot->
name =
"Frame Selected";
1036 ot->
idname =
"FILE_OT_view_selected";
1078 ot->
name =
"Select Directory";
1080 ot->
idname =
"FILE_OT_select_bookmark";
1105 if (
params->dir[0] !=
'\0') {
1125 ot->
name =
"Add Bookmark";
1126 ot->
description =
"Add a bookmark for the selected/active directory";
1127 ot->
idname =
"FILE_OT_bookmark_add";
1158 if ((index > -1) && (index < nentries)) {
1180 ot->
name =
"Delete Bookmark";
1182 ot->
idname =
"FILE_OT_bookmark_delete";
1206 bool changed =
false;
1208 for (index = 0; fsme; fsme = fsme_next) {
1209 fsme_next = fsme->
next;
1239 ot->
name =
"Cleanup Bookmarks";
1241 ot->
idname =
"FILE_OT_bookmark_cleanup";
1270 const struct FSMenuEntry *fsmentry_org = fsmentry;
1283 switch (direction) {
1288 new_index = totitems - 1;
1293 new_index = (totitems + act_index + direction) % totitems;
1297 if (new_index == act_index) {
1302 if (fsmentry != fsmentry_org) {
1341 ot->
name =
"Move Bookmark";
1342 ot->
idname =
"FILE_OT_bookmark_move";
1343 ot->
description =
"Move the active bookmark up/down in the list";
1357 "Direction to move the active bookmark towards");
1388 ot->
name =
"Reset Recent";
1390 ot->
idname =
"FILE_OT_reset_recent";
1408 int numfiles, origfile;
1424 origfile =
params->highlight_file;
1438 if ((highlight_file >= 0) && (highlight_file < numfiles)) {
1439 params->highlight_file = highlight_file;
1442 params->highlight_file = -1;
1446 params->highlight_file = -1;
1449 return (
params->highlight_file != origfile);
1469 ot->
name =
"Highlight File";
1521 ot->
name =
"Sort from Column";
1522 ot->
description =
"Change sorting to use column under cursor";
1523 ot->
idname =
"FILE_OT_sort_column_ui_context";
1544 if (!sfile || !sfile->
op) {
1567 ot->
name =
"Cancel File Load";
1616 for (i = 0; i < numfiles; i++) {
1620 if (!
file->redirection_path) {
1629 if (0 == num_files) {
1639 for (i = 0; i < numfiles; i++) {
1650 if (0 == num_dirs) {
1777 if (
file &&
file->redirection_path) {
1793 if (!
file->relpath) {
1808 else if (sfile->
op) {
1850 ot->
name =
"Execute File Window";
1904 ot->
name =
"Execute File";
1906 "Perform the current execute action for the file under the cursor (e.g. open the file)";
1907 ot->
idname =
"FILE_OT_mouse_execute";
1944 ot->
name =
"Refresh File List";
1969 if (
params->recursion_level > 1) {
1971 params->recursion_level = 0;
1984 ot->
name =
"Parent File";
2020 ot->
name =
"Previous Folder";
2057 ot->
name =
"Next Folder";
2093 if ((
params->rename_flag &
2100 for (i = 0; i < numfiles; i++) {
2112 if (edit_idx == -1) {
2115 if (
params->rename_flag == 0) {
2135 sfile->
scroll_offset = (edit_idx / items_block_size) * items_block_size;
2141 const int last_visible_item = first_visible_item + numfiles_layout + 1;
2146 const int middle_offset =
max_ii(
2147 0, (first_visible_item + last_visible_item) / 2 - (is_horizontal ? 0 : items_block_size));
2149 const int min_middle_offset = numfiles_layout / 2;
2150 const int max_middle_offset = ((numfiles / items_block_size) * items_block_size +
2151 ((numfiles % items_block_size) != 0 ? items_block_size : 0)) -
2152 (numfiles_layout / 2);
2167 const bool is_centered = (
abs(middle_offset / items_block_size -
2170 const bool is_full_start = ((sfile->
scroll_offset < min_middle_offset) &&
2171 (min_curr_scroll - min_tot_scroll < 1.0f) &&
2172 (middle_offset - min_middle_offset < items_block_size));
2176 const bool is_full_end = ((sfile->
scroll_offset > max_middle_offset) &&
2177 (max_tot_scroll - max_curr_scroll < 1.0f) &&
2178 (max_middle_offset - middle_offset < items_block_size));
2180 if (is_ready && (is_centered || is_full_start || is_full_end)) {
2206 const int diff_offset = sfile->
scroll_offset / items_block_size -
2207 middle_offset / items_block_size;
2209 const int diff_offset_delta =
abs(diff_offset) *
2213 const int scroll_delta =
max_ii(2, diff_offset_delta / 15);
2215 if (diff_offset < 0) {
2216 if (is_horizontal) {
2217 deltax = -scroll_delta;
2220 deltay = scroll_delta;
2224 if (is_horizontal) {
2225 deltax = scroll_delta;
2228 deltay = -scroll_delta;
2249 ot->
name =
"Smooth Scroll";
2250 ot->
idname =
"FILE_OT_smoothscroll";
2251 ot->
description =
"Smooth scroll to make editable file visible";
2295 ot->
name =
"File Selector Drop";
2296 ot->
idname =
"FILE_OT_filepath_drop";
2340 bool generate_name =
true;
2357 if (path[0] !=
'\0') {
2358 generate_name =
false;
2362 if (generate_name) {
2376 "'%s' given path is OS-invalid, creating '%s' path instead",
2390 "Could not create new folder: %s",
2391 errno ? strerror(errno) :
"unknown error");
2398 if (do_diropen ==
false) {
2400 "File rename handling should immediately clear rename_id when done, "
2401 "because otherwise it will keep taking precedence over renamefile.");
2407 params->rename_flag = rename_flag;
2427 ot->
name =
"Create New Directory";
2429 ot->
idname =
"FILE_OT_directory_new";
2463 (blendfile_path[0] !=
'\0') ? blendfile_path :
2466 else if (
params->dir[0] ==
'~') {
2467 char tmpstr[
sizeof(
params->dir) - 1];
2473 else if (
params->dir[0] ==
'\0')
2484 else if ((isalpha(
params->dir[0]) && (
params->dir[1] ==
':')) && (
params->dir[2] ==
'\0')) {
2497 static bool can_create_dir(
const char *dir)
2520 char old_dir[
sizeof(
params->dir)];
2532 char path[
sizeof(
params->dir)];
2564 else if (!can_create_dir(
params->dir)) {
2608 uiBut *but = arg_but;
2612 char filepath[
sizeof(
params->dir)];
2614 matched_file[0] =
'\0';
2646 else if (matches > 1) {
2676 ot->
name =
"Toggle Hide Dot Files";
2718 if (add < 0 && digits > 0) {
2721 for (i = digits; i > 1; i--) {
2744 if (
params && (inc != 0)) {
2757 ot->
name =
"Increment Number in Filename";
2779 if ((file_idx >= 0) && (file_idx < numfiles)) {
2782 if ((require_selected ==
false) ||
2813 ot->
name =
"Rename File or Directory";
2847 for (
int i = 0; i < numfiles; i++) {
2859 const char **r_error_message)
2877 const char *error_message =
NULL;
2878 bool report_error =
false;
2880 for (
int i = 0; i < numfiles; i++) {
2884 report_error =
true;
2890 if (error_message !=
NULL) {
2896 "Could not delete file or directory: %s",
2897 errno ? strerror(errno) :
"unknown error");
2910 ot->
name =
"Delete Selected Files";
2911 ot->
description =
"Move selected files to the trash or recycle bin";
2953 ot->
idname =
"FILE_OT_start_filter";
2992 ot->
name =
"Edit Directory Path";
2994 ot->
idname =
"FILE_OT_edit_directory_path";
const char * BKE_appdir_folder_default_or_root(void) ATTR_WARN_UNUSED_RESULT ATTR_RETURNS_NONNULL
const char * BKE_appdir_folder_id_create(int folder_id, const char *subfolder)
#define BLENDER_BOOKMARK_FILE
struct ScrArea * CTX_wm_area(const bContext *C)
void CTX_wm_region_set(bContext *C, struct ARegion *region)
struct wmWindowManager * CTX_wm_manager(const bContext *C)
struct SpaceLink * CTX_wm_space_data(const bContext *C)
struct ARegion * CTX_wm_region(const bContext *C)
struct Main * CTX_data_main(const bContext *C)
struct SpaceFile * CTX_wm_space_file(const bContext *C)
struct wmWindow * CTX_wm_window(const bContext *C)
const char * BKE_main_blendfile_path(const struct Main *bmain) ATTR_NONNULL()
void BKE_reportf(ReportList *reports, eReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
void BKE_report(ReportList *reports, eReportType type, const char *message)
struct ARegion * BKE_area_find_region_type(const struct ScrArea *area, int type)
#define BLI_assert_msg(a, msg)
int BLI_exists(const char *path) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
bool BLI_is_file(const char *path) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
bool BLI_is_dir(const char *path) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
bool BLI_dir_create_recursive(const char *dir) ATTR_NONNULL()
int BLI_delete_soft(const char *file, const char **error_message) ATTR_NONNULL()
void BLI_linklist_move_item(LinkNode **listp, int curr_index, int new_index) ATTR_NONNULL(1)
#define LISTBASE_FOREACH(type, var, list)
MINLINE int max_ii(int a, int b)
void BLI_split_dir_part(const char *string, char *dir, size_t dirlen)
int BLI_path_sequence_decode(const char *string, char *head, char *tail, unsigned short *r_digits_len)
bool BLI_path_make_safe(char *path) ATTR_NONNULL(1)
bool BLI_filename_make_safe_ex(char *fname, bool allow_tokens) ATTR_NONNULL(1)
bool BLI_path_is_rel(const char *path) ATTR_NONNULL() ATTR_WARN_UNUSED_RESULT
void BLI_path_normalize_dir(const char *relabase, char *dir) ATTR_NONNULL(2)
void BLI_split_dirfile(const char *string, char *dir, char *file, size_t dirlen, size_t filelen)
void BLI_path_normalize(const char *relabase, char *path) ATTR_NONNULL(2)
#define FILENAME_IS_CURRPAR(_n)
void BLI_path_append(char *__restrict dst, size_t maxlen, const char *__restrict file) ATTR_NONNULL()
void BLI_path_sequence_encode(char *string, const char *head, const char *tail, unsigned short numlen, int pic)
size_t BLI_path_join(char *__restrict dst, size_t dst_len, const char *path_first,...) ATTR_NONNULL(1
int BLI_path_slash_ensure(char *string) ATTR_NONNULL()
void BLI_path_rel(char *file, const char *relfile) ATTR_NONNULL()
bool BLI_path_parent_dir(char *path) ATTR_NONNULL()
bool BLI_path_is_unc(const char *path) ATTR_NONNULL(1) ATTR_WARN_UNUSED_RESULT
bool BLI_path_abs(char *path, const char *basepath) ATTR_NONNULL()
#define FILENAME_IS_PARENT(_n)
void BLI_join_dirfile(char *__restrict dst, size_t maxlen, const char *__restrict dir, const char *__restrict file) ATTR_NONNULL()
int BLI_rcti_length_x(const rcti *rect, int x)
int BLI_rcti_length_y(const rcti *rect, int y)
void BLI_rcti_init(struct rcti *rect, int xmin, int xmax, int ymin, int ymax)
void BLI_rctf_rcti_copy(struct rctf *dst, const struct rcti *src)
char * BLI_strdup(const char *str) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL() ATTR_MALLOC
char * BLI_strncpy(char *__restrict dst, const char *__restrict src, size_t maxncpy) ATTR_NONNULL()
size_t BLI_snprintf(char *__restrict dst, size_t maxncpy, const char *__restrict format,...) ATTR_NONNULL(1
#define IN_RANGE(a, b, c)
Compatibility-like things for windows.
void BLI_windows_get_default_root_dir(char root_dir[4])
external readfile function prototypes.
bool BLO_library_path_explode(const char *path, char *r_dir, char **r_group, char **r_name)
eFileSel_Params_RenameFlag
@ FILE_PARAMS_RENAME_POSTSCROLL_PENDING
@ FILE_PARAMS_RENAME_ACTIVE
@ FILE_PARAMS_RENAME_POSTSCROLL_ACTIVE
@ FILE_PARAMS_RENAME_PENDING
#define FILE_MAX_LIBEXTRA
void ED_file_change_dir(struct bContext *C)
struct FSMenu * ED_fsmenu_get(void)
FileSelection ED_fileselect_layout_offset_rect(FileLayout *layout, const struct rcti *rect)
int ED_fileselect_layout_offset(FileLayout *layout, int x, int y)
bool ED_fileselect_layout_is_inside_pt(const FileLayout *layout, const struct View2D *v2d, int x, int y)
void ED_fileselect_clear(struct wmWindowManager *wm, struct SpaceFile *sfile)
struct FSMenuEntry * ED_fsmenu_get_category(struct FSMenu *fsmenu, FSMenuCategory category)
bool ED_fileselect_layout_isect_rect(const FileLayout *layout, const struct View2D *v2d, const struct rcti *rect, struct rcti *r_dst)
int ED_fsmenu_get_nentries(struct FSMenu *fsmenu, FSMenuCategory category)
int ED_fileselect_layout_numfiles(FileLayout *layout, struct ARegion *region)
struct FileSelectParams * ED_fileselect_get_active_params(const struct SpaceFile *sfile)
void ED_fsmenu_set_category(struct FSMenu *fsmenu, FSMenuCategory category, struct FSMenuEntry *fsm_head)
struct FSMenuEntry * ED_fsmenu_get_entry(struct FSMenu *fsmenu, FSMenuCategory category, int idx)
FileLayout * ED_fileselect_get_layout(struct SpaceFile *sfile, struct ARegion *region)
void ED_area_tag_redraw(ScrArea *area)
bool ED_operator_file_active(struct bContext *C)
bool ED_operator_file_browsing_active(struct bContext *C)
void ED_region_tag_redraw(struct ARegion *region)
void ED_area_tag_refresh(ScrArea *area)
#define SEL_OP_USE_PRE_DESELECT(sel_op)
Read Guarded memory(de)allocation.
bool UI_textbutton_activate_but(const struct bContext *C, uiBut *but)
bool UI_textbutton_activate_rna(const struct bContext *C, struct ARegion *region, const void *rna_poin_data, const char *rna_prop_id)
void UI_view2d_region_to_view_rctf(const struct View2D *v2d, const struct rctf *rect_src, struct rctf *rect_dst) ATTR_NONNULL()
void UI_view2d_region_to_view(const struct View2D *v2d, float x, float y, float *r_view_x, float *r_view_y) ATTR_NONNULL()
void UI_view2d_curRect_validate(struct View2D *v2d)
#define ND_SPACE_FILE_PARAMS
#define ND_SPACE_FILE_LIST
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
void file_params_renamefile_clear(struct FileSelectParams *params)
int file_select_match(struct SpaceFile *sfile, const char *pattern, char *matched_file)
void file_params_invoke_rename_postscroll(struct wmWindowManager *wm, struct wmWindow *win, SpaceFile *sfile)
void fileselect_file_set(SpaceFile *sfile, int index)
void file_params_renamefile_activate(struct SpaceFile *sfile, struct FileSelectParams *params)
bool file_attribute_column_header_is_inside(const struct View2D *v2d, const FileLayout *layout, int x, int y)
void file_tile_boundbox(const ARegion *region, FileLayout *layout, int file, rcti *r_bounds)
FileAttributeColumnType file_attribute_column_type_find_isect(const View2D *v2d, const FileSelectParams *params, FileLayout *layout, int x)
void file_params_smoothscroll_timer_clear(struct wmWindowManager *wm, struct wmWindow *win, SpaceFile *sfile)
void file_select_deselect_all(SpaceFile *sfile, uint flag)
void FILE_OT_filenum(struct wmOperatorType *ot)
void file_filename_enter_handle(bContext *C, void *UNUSED(arg_unused), void *arg_but)
void FILE_OT_select_box(wmOperatorType *ot)
static int file_edit_directory_path_exec(bContext *C, wmOperator *UNUSED(op))
void ED_operatormacros_file(void)
static int file_next_exec(bContext *C, wmOperator *UNUSED(unused))
void file_draw_check(bContext *C)
static int file_walk_select_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(event))
void FILE_OT_bookmark_add(wmOperatorType *ot)
void FILE_OT_rename(struct wmOperatorType *ot)
void FILE_OT_select_bookmark(wmOperatorType *ot)
static int file_cancel_exec(bContext *C, wmOperator *UNUSED(unused))
static bool file_walk_select_do(bContext *C, SpaceFile *sfile, FileSelectParams *params, const int direction, const bool extend, const bool fill)
static FileSelection find_file_mouse_rect(SpaceFile *sfile, ARegion *region, const rcti *rect_region)
void FILE_OT_mouse_execute(wmOperatorType *ot)
static int file_box_select_modal(bContext *C, wmOperator *op, const wmEvent *event)
void FILE_OT_edit_directory_path(struct wmOperatorType *ot)
static int file_start_filter_exec(bContext *C, wmOperator *UNUSED(op))
static bool file_bookmark_move_poll(bContext *C)
static int bookmark_add_exec(bContext *C, wmOperator *UNUSED(op))
static int file_box_select_exec(bContext *C, wmOperator *op)
void FILE_OT_cancel(struct wmOperatorType *ot)
static bool file_ensure_hovered_is_active(bContext *C, const wmEvent *event)
static int file_directory_new_exec(bContext *C, wmOperator *op)
static int file_execute_mouse_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *event)
static bool file_is_any_selected(struct FileList *files)
static int file_rename_exec(bContext *C, wmOperator *UNUSED(op))
void FILE_OT_highlight(struct wmOperatorType *ot)
void file_directory_enter_handle(bContext *C, void *UNUSED(arg_unused), void *UNUSED(arg_but))
void FILE_OT_sort_column_ui_context(wmOperatorType *ot)
static int file_box_select_find_last_selected(SpaceFile *sfile, ARegion *region, const FileSelection *sel, const int mouse_xy[2])
static rcti file_select_mval_to_select_rect(const int mval[2])
static FileSelect file_select_do(bContext *C, int selected_idx, bool do_diropen)
void file_operator_to_sfile(Main *bmain, SpaceFile *sfile, wmOperator *op)
static int file_previous_exec(bContext *C, wmOperator *UNUSED(op))
void FILE_OT_directory_new(struct wmOperatorType *ot)
void FILE_OT_filepath_drop(wmOperatorType *ot)
static void file_rename_state_activate(SpaceFile *sfile, int file_idx, bool require_selected)
void FILE_OT_parent(struct wmOperatorType *ot)
void FILE_OT_bookmark_delete(wmOperatorType *ot)
void FILE_OT_select_walk(wmOperatorType *ot)
static int file_column_sort_ui_context_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *event)
static int filepath_drop_exec(bContext *C, wmOperator *op)
static FileSelection file_selection_get(bContext *C, const rcti *rect, bool fill)
static int file_view_selected_exec(bContext *C, wmOperator *UNUSED(op))
static int file_parent_exec(bContext *C, wmOperator *UNUSED(unused))
static void clamp_to_filelist(int numfiles, FileSelection *sel)
@ FILE_BOOKMARK_MOVE_DOWN
@ FILE_BOOKMARK_MOVE_BOTTOM
void FILE_OT_bookmark_cleanup(wmOperatorType *ot)
static int file_refresh_exec(bContext *C, wmOperator *UNUSED(unused))
void file_draw_check_ex(bContext *C, ScrArea *area)
void FILE_OT_hidedot(struct wmOperatorType *ot)
void FILE_OT_smoothscroll(wmOperatorType *ot)
void FILE_OT_refresh(struct wmOperatorType *ot)
void FILE_OT_bookmark_move(wmOperatorType *ot)
static FileSelection file_current_selection_range_get(struct FileList *files)
static void filenum_newname(char *name, size_t name_size, int add)
static int bookmark_cleanup_exec(bContext *C, wmOperator *UNUSED(op))
void FILE_OT_select_all(wmOperatorType *ot)
static FileSelect file_select(bContext *C, const rcti *rect, FileSelType select, bool fill, bool do_diropen)
static int file_delete_exec(bContext *C, wmOperator *op)
static int file_hidedot_exec(bContext *C, wmOperator *UNUSED(unused))
static void file_ensure_inside_viewbounds(ARegion *region, SpaceFile *sfile, const int file)
static bool file_operator_poll(bContext *C)
void FILE_OT_reset_recent(wmOperatorType *ot)
static bool file_filenum_poll(bContext *C)
int file_highlight_set(SpaceFile *sfile, ARegion *region, int mx, int my)
void file_draw_check_cb(bContext *C, void *UNUSED(arg1), void *UNUSED(arg2))
void FILE_OT_select(wmOperatorType *ot)
void file_sfile_filepath_set(SpaceFile *sfile, const char *filepath)
void FILE_OT_delete(struct wmOperatorType *ot)
void FILE_OT_execute(struct wmOperatorType *ot)
static int file_highlight_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *event)
static bool file_delete_single(const FileSelectParams *params, FileDirEntry *file, const char **r_error_message)
static void file_ensure_selection_inside_viewbounds(ARegion *region, SpaceFile *sfile, FileSelection *sel)
static bool new_folder_path(const char *parent, char folder[FILE_MAX], char name[FILE_MAXFILE])
static int file_select_all_exec(bContext *C, wmOperator *op)
static int file_exec(bContext *C, wmOperator *UNUSED(op))
void file_sfile_to_operator_ex(Main *bmain, wmOperator *op, SpaceFile *sfile, char *filepath)
void FILE_OT_start_filter(struct wmOperatorType *ot)
static int file_smoothscroll_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *event)
static void file_expand_directory(bContext *C)
void file_sfile_to_operator(Main *bmain, wmOperator *op, SpaceFile *sfile)
bool file_draw_check_exists(SpaceFile *sfile)
static int reset_recent_exec(bContext *C, wmOperator *UNUSED(op))
static bool file_execute(bContext *C, SpaceFile *sfile)
void FILE_OT_next(struct wmOperatorType *ot)
void FILE_OT_view_selected(wmOperatorType *ot)
static int bookmark_delete_exec(bContext *C, wmOperator *op)
static int file_select_exec(bContext *C, wmOperator *op)
void FILE_OT_previous(struct wmOperatorType *ot)
static int bookmark_select_exec(bContext *C, wmOperator *op)
static int bookmark_move_exec(bContext *C, wmOperator *op)
static bool file_delete_poll(bContext *C)
static bool file_walk_select_selection_set(wmWindow *win, ARegion *region, SpaceFile *sfile, const int direction, const int numfiles, const int active_old, const int active_new, const int other_site, const bool has_selection, const bool extend, const bool fill)
static int file_filenum_exec(bContext *C, wmOperator *op)
bool filelist_is_ready(struct FileList *filelist)
void filelist_entry_select_index_set(FileList *filelist, const int index, FileSelType select, uint flag, FileCheckType check)
bool filelist_islibrary(struct FileList *filelist, char *dir, char **r_group)
const char * folderlist_peeklastdir(ListBase *folderlist)
void filelist_entry_parent_select_set(FileList *filelist, FileSelType select, uint flag, FileCheckType check)
void filelist_entries_select_index_range_set(FileList *filelist, FileSelection *sel, FileSelType select, uint flag, FileCheckType check)
void folderlist_popdir(struct ListBase *folderlist, char *dir)
uint filelist_entry_select_index_get(FileList *filelist, const int index, FileCheckType check)
void folderlist_pushdir(ListBase *folderlist, const char *dir)
void filelist_setrecursion(struct FileList *filelist, const int recursion_level)
uint filelist_entry_select_set(const FileList *filelist, const FileDirEntry *entry, FileSelType select, uint flag, FileCheckType check)
FileDirEntry * filelist_file(struct FileList *filelist, int index)
int filelist_files_ensure(FileList *filelist)
bool filelist_entry_is_selected(FileList *filelist, const int index)
bool filelist_is_dir(struct FileList *filelist, const char *path)
uint filelist_entry_select_get(FileList *filelist, FileDirEntry *entry, FileCheckType check)
void(* MEM_freeN)(void *vmemh)
ccl_device_inline float3 exp(float3 v)
bool add(void *owner, const AttributeIDRef &attribute_id, eAttrDomain domain, eCustomDataType data_type, const AttributeInit &initializer)
static void area(int d1, int d2, int e1, int e2, float weights[2])
bool active
all scheduled work for the GPU.
void RNA_string_set(PointerRNA *ptr, const char *name, const char *value)
void RNA_boolean_set(PointerRNA *ptr, const char *name, bool value)
bool RNA_property_is_set(PointerRNA *ptr, PropertyRNA *prop)
void RNA_int_set(PointerRNA *ptr, const char *name, int value)
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
bool RNA_property_boolean_get(PointerRNA *ptr, PropertyRNA *prop)
int RNA_property_int_get(PointerRNA *ptr, PropertyRNA *prop)
void RNA_string_get(PointerRNA *ptr, const char *name, char *value)
int RNA_int_get(PointerRNA *ptr, const char *name)
void RNA_property_string_get(PointerRNA *ptr, PropertyRNA *prop, char *value)
void RNA_property_collection_add(PointerRNA *ptr, PropertyRNA *prop, PointerRNA *r_ptr)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
void RNA_property_collection_clear(PointerRNA *ptr, PropertyRNA *prop)
int RNA_enum_get(PointerRNA *ptr, const char *name)
void RNA_property_string_set(PointerRNA *ptr, PropertyRNA *prop, const char *value)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_string_file_path(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_string_dir_path(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, int default_value, int hardmin, int hardmax, const char *ui_name, const char *ui_description, int softmin, int softmax)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
FileAttributeColumn attribute_columns[ATTRIBUTE_COLUMN_MAX]
struct wmTimer * smoothscroll_timer
struct FileLayout * layout
int(* invoke)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
int(* modal)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
void(* cancel)(struct bContext *, struct wmOperator *)
bool(* check)(struct bContext *, struct wmOperator *)
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
struct wmOperatorType * type
int WM_operator_name_call_ptr(bContext *C, wmOperatorType *ot, wmOperatorCallContext context, PointerRNA *properties, const wmEvent *event)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
int WM_operator_name_call(bContext *C, const char *opstring, wmOperatorCallContext context, PointerRNA *properties, const wmEvent *event)
void WM_event_fileselect_event(wmWindowManager *wm, void *ophandle, int eventval)
void WM_event_add_mousemove(wmWindow *win)
void WM_gesture_box_cancel(bContext *C, wmOperator *op)
int WM_gesture_box_invoke(bContext *C, wmOperator *op, const wmEvent *event)
int WM_gesture_box_modal(bContext *C, wmOperator *op, const wmEvent *event)
void WM_operator_properties_border_to_rcti(struct wmOperator *op, rcti *rect)
void WM_operator_properties_gesture_box(wmOperatorType *ot)
void WM_operator_properties_confirm_or_exec(wmOperatorType *ot)
void WM_operator_properties_select_operation_simple(wmOperatorType *ot)
void WM_operator_properties_generic_select(wmOperatorType *ot)
void WM_operator_properties_select_walk_direction(wmOperatorType *ot)
void WM_operator_properties_select_all(wmOperatorType *ot)
wmOperatorType * WM_operatortype_find(const char *idname, bool quiet)
int WM_operator_confirm(bContext *C, wmOperator *op, const wmEvent *UNUSED(event))
int WM_operator_confirm_or_exec(bContext *C, wmOperator *op, const wmEvent *UNUSED(event))
int WM_generic_select_invoke(bContext *C, wmOperator *op, const wmEvent *event)
void WM_operator_properties_create_ptr(PointerRNA *ptr, wmOperatorType *ot)
int WM_generic_select_modal(bContext *C, wmOperator *op, const wmEvent *event)
void WM_operator_properties_create(PointerRNA *ptr, const char *opstring)
void WM_operator_properties_free(PointerRNA *ptr)