Blender V2.61 - r43446
|
#include "BKE_context.h"
#include "BKE_screen.h"
#include "BKE_global.h"
#include "BKE_report.h"
#include "BKE_main.h"
#include "BLI_blenlib.h"
#include "BLI_utildefines.h"
#include "ED_screen.h"
#include "ED_fileselect.h"
#include "MEM_guardedalloc.h"
#include "RNA_access.h"
#include "RNA_define.h"
#include "UI_view2d.h"
#include "WM_api.h"
#include "WM_types.h"
#include "file_intern.h"
#include "filelist.h"
#include "fsmenu.h"
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <ctype.h>
Go to the source code of this file.
Definition in file file_ops.c.
#define ACTIVATE 1 |
Definition at line 68 of file file_ops.c.
#define INACTIVATE 2 |
Definition at line 69 of file file_ops.c.
#define NOTACTIVEFILE 0 |
Definition at line 67 of file file_ops.c.
typedef enum FileSelect FileSelect |
enum FileSelect |
Definition at line 99 of file file_ops.c.
static int bookmark_add_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 450 of file file_ops.c.
References BLENDER_BOOKMARK_FILE, BLENDER_USER_CONFIG, BLI_get_folder_create(), BLI_make_file_string(), CTX_wm_area(), CTX_wm_space_file(), FileSelectParams::dir, ED_area_tag_redraw(), ED_fileselect_get_params(), FILE_MAX, FS_CATEGORY_BOOKMARKS, fsmenu_get(), fsmenu_insert_entry(), fsmenu_write_file(), NULL, and OPERATOR_FINISHED.
Referenced by FILE_OT_bookmark_add().
static int bookmark_delete_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 481 of file file_ops.c.
References BLENDER_BOOKMARK_FILE, BLENDER_USER_CONFIG, BLI_get_folder_create(), BLI_make_file_string(), CTX_wm_area(), ED_area_tag_redraw(), FILE_MAX, FS_CATEGORY_BOOKMARKS, fsmenu_get(), fsmenu_get_nentries(), fsmenu_remove_entry(), fsmenu_write_file(), NULL, OPERATOR_FINISHED, wmOperator::ptr, RNA_int_get(), and RNA_struct_find_property().
Referenced by FILE_OT_delete_bookmark().
static int bookmark_select_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 417 of file file_ops.c.
References BLI_cleanup_dir(), BLI_strncpy(), CTX_wm_space_file(), FileSelectParams::dir, file_change_dir(), G, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, wmOperator::ptr, RNA_string_get(), RNA_struct_find_property(), and WM_event_add_notifier().
Referenced by FILE_OT_select_bookmark().
static void clamp_to_filelist | ( | int | numfiles, |
FileSelection * | sel | ||
) | [static] |
Definition at line 105 of file file_ops.c.
References FileSelection::first, and FileSelection::last.
Referenced by file_selection_get().
void ED_operatormacros_file | ( | void | ) |
Definition at line 1427 of file file_ops.c.
Referenced by ED_spacetypes_init().
static int file_bookmark_toggle_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) | [static] |
Definition at line 1266 of file file_ops.c.
References CTX_wm_area(), ED_region_toggle_hidden(), file_buttons_region(), and OPERATOR_FINISHED.
Referenced by FILE_OT_bookmark_toggle().
static int file_border_select_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 271 of file file_ops.c.
References BLI_isect_rcti(), CTX_wm_region(), CTX_wm_space_file(), file_deselect_all(), FILE_SEL_ADD, FILE_SEL_REMOVE, file_select(), FILE_SELECT_DIR, FILE_SELECT_FILE, GESTURE_MODAL_SELECT, View2D::mask, NC_SPACE, ND_SPACE_FILE_LIST, ND_SPACE_FILE_PARAMS, NULL, OPERATOR_FINISHED, wmOperator::ptr, RNA_boolean_get(), RNA_int_get(), SELECTED_FILE, ARegion::v2d, WM_event_add_notifier(), rcti::xmax, rcti::xmin, rcti::ymax, and rcti::ymin.
Referenced by FILE_OT_select_border().
static int file_border_select_modal | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | event | ||
) | [static] |
Definition at line 232 of file file_ops.c.
References FileSelectParams::active_file, BLI_isect_rcti(), CHECK_ALL, CTX_wm_region(), CTX_wm_space_file(), ED_fileselect_get_params(), file_deselect_all(), FILE_SEL_ADD, file_selection_get(), filelist_select(), SpaceFile::files, FileSelection::first, HILITED_FILE, FileSelection::last, View2D::mask, NC_SPACE, ND_SPACE_FILE_PARAMS, NULL, OPERATOR_RUNNING_MODAL, wmOperator::ptr, RNA_int_get(), FileSelectParams::sel_first, FileSelectParams::sel_last, ARegion::v2d, WM_border_select_modal(), WM_event_add_notifier(), rcti::xmax, rcti::xmin, rcti::ymax, and rcti::ymin.
Referenced by FILE_OT_select_border().
Definition at line 1239 of file file_ops.c.
References ARegion::alignment, BLI_insertlinkafter(), ListBase::first, ARegion::flag, MEM_callocN(), ARegion::next, NULL, ScrArea::regionbase, ARegion::regiontype, RGN_ALIGN_LEFT, RGN_FLAG_HIDDEN, RGN_TYPE_CHANNELS, and RGN_TYPE_HEADER.
Referenced by file_bookmark_toggle_exec().
int file_cancel_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 576 of file file_ops.c.
References CTX_wm_space_file(), EVT_FILESELECT_CANCEL, NULL, SpaceFile::op, OPERATOR_FINISHED, and WM_event_fileselect_event().
int file_delete_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) |
Definition at line 1396 of file file_ops.c.
References FileSelectParams::active_file, BLI_delete(), BLI_make_file_string(), CTX_wm_space_file(), FileSelectParams::dir, ED_fileselect_clear(), FILE_MAX, filelist_file(), SpaceFile::files, G, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, direntry::relname, str, and WM_event_add_notifier().
static int file_delete_poll | ( | bContext * | C | ) | [static] |
Definition at line 1374 of file file_ops.c.
References FileSelectParams::active_file, CTX_wm_space_file(), ED_operator_file_active(), FILE_MAX, filelist_file(), filelist_islibrary(), SpaceFile::files, SpaceFile::params, and direntry::type.
Referenced by FILE_OT_delete().
static void file_deselect_all | ( | SpaceFile * | sfile, |
unsigned int | flag | ||
) | [static] |
Definition at line 90 of file file_ops.c.
References CHECK_ALL, FILE_SEL_REMOVE, filelist_numfiles(), filelist_select(), SpaceFile::files, FileSelection::first, and FileSelection::last.
Referenced by file_border_select_exec(), file_border_select_modal(), and file_select_invoke().
int file_directory_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 1135 of file file_ops.c.
References BLI_add_slash(), BLI_cleanup_dir(), BLI_dir_create_recursive(), BLI_exists(), BLI_is_file(), BLI_split_dirfile(), BLI_strncpy(), CTX_wm_space_file(), FileSelectParams::dir, FileSelectParams::file, file_change_dir(), file_expand_directory(), G, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, direntry::path, and WM_event_add_notifier().
static int file_directory_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | UNUSEDevent | ||
) | [static] |
Definition at line 1116 of file file_ops.c.
References BLI_exists(), CTX_wm_space_file(), FileSelectParams::dir, file_directory_exec(), file_expand_directory(), OPERATOR_CANCELLED, SpaceFile::params, and WM_operator_confirm_message().
Referenced by FILE_OT_directory().
int file_directory_new_exec | ( | bContext * | C, |
wmOperator * | op | ||
) |
Definition at line 1020 of file file_ops.c.
References BKE_report(), BLI_dir_create_recursive(), BLI_exists(), BLI_strncpy(), CTX_wm_manager(), CTX_wm_space_file(), CTX_wm_window(), FileSelectParams::dir, ED_fileselect_clear(), FILE_MAX, FILE_MAXFILE, NC_SPACE, ND_SPACE_FILE_LIST, new_folder_path(), NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, SpaceFile::params, direntry::path, wmOperator::ptr, FileSelectParams::renamefile, wmOperator::reports, RNA_string_get(), RNA_struct_find_property(), RPT_ERROR, RPT_WARNING, SpaceFile::scroll_offset, SpaceFile::smoothscroll_timer, TIMER1, WM_event_add_notifier(), and WM_event_add_timer().
Referenced by FILE_OT_directory_new().
static int file_directory_poll | ( | bContext * | C | ) | [static] |
Definition at line 1181 of file file_ops.c.
References CTX_wm_space_file(), ED_operator_file_active(), filelist_lib(), SpaceFile::files, and NULL.
Referenced by FILE_OT_directory().
void file_draw_check_cb | ( | bContext * | C, |
void * | UNUSEDarg1, | ||
void * | UNUSEDarg2 | ||
) |
Definition at line 691 of file file_ops.c.
References wmOperatorType::check, CTX_wm_area(), CTX_wm_space_file(), ED_area_tag_redraw(), FILE_MAX, file_operator_to_sfile(), file_sfile_to_operator(), SpaceFile::op, and wmOperator::type.
int file_draw_check_exists | ( | SpaceFile * | sfile | ) |
Definition at line 711 of file file_ops.c.
References BLI_is_file(), BLI_join_dirfile(), FileSelectParams::dir, FALSE, FileSelectParams::file, FILE_MAX, SpaceFile::op, SpaceFile::params, wmOperator::ptr, RNA_boolean_get(), RNA_struct_find_property(), and TRUE.
Referenced by file_draw_buttons().
int file_exec | ( | bContext * | C, |
wmOperator * | exec_op | ||
) |
Definition at line 729 of file file_ops.c.
References BLENDER_BOOKMARK_FILE, BLENDER_USER_CONFIG, BLI_exists(), BLI_get_folder_create(), BLI_make_file_string(), CHECK_ALL, CTX_wm_space_file(), FileSelectParams::dir, EVT_FILESELECT_EXEC, FILE_MAX, file_sfile_to_operator(), filelist_is_selected(), filelist_numfiles(), SpaceFile::files, FS_CATEGORY_RECENT, fsmenu_get(), fsmenu_insert_entry(), fsmenu_write_file(), G, i, NULL, SpaceFile::op, OPERATOR_CANCELLED, OPERATOR_FINISHED, SpaceFile::params, wmOperator::ptr, RNA_boolean_get(), and WM_event_fileselect_event().
Referenced by FILE_OT_execute().
static void file_expand_directory | ( | bContext * | C | ) | [static] |
Definition at line 1088 of file file_ops.c.
References BLI_getDefaultDocumentFolder(), BLI_join_dirfile(), BLI_strncpy(), CTX_wm_space_file(), FileSelectParams::dir, and SpaceFile::params.
Referenced by file_directory_exec(), and file_directory_invoke().
int file_filename_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 1164 of file file_ops.c.
References CTX_wm_space_file(), FileSelectParams::file, file_select_match(), NC_SPACE, ND_SPACE_FILE_PARAMS, NULL, OPERATOR_FINISHED, SpaceFile::params, and WM_event_add_notifier().
static int file_filenum_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1290 of file file_ops.c.
References BLI_newname(), CTX_wm_area(), CTX_wm_space_file(), ED_area_tag_redraw(), FileSelectParams::file, file_draw_check_cb(), NULL, OPERATOR_FINISHED, SpaceFile::params, wmOperator::ptr, and RNA_int_get().
Referenced by FILE_OT_filenum().
static int file_hidedot_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) | [static] |
Definition at line 1213 of file file_ops.c.
References CTX_wm_space_file(), ED_fileselect_clear(), FILE_HIDE_DOT, FileSelectParams::flag, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, and WM_event_add_notifier().
Referenced by FILE_OT_hidedot().
static int file_highlight_invoke | ( | bContext * | C, |
wmOperator * | UNUSEDop, | ||
wmEvent * | event | ||
) | [static] |
Definition at line 551 of file file_ops.c.
References CTX_wm_area(), CTX_wm_region(), CTX_wm_space_file(), ED_area_tag_redraw(), file_hilight_set(), OPERATOR_CANCELLED, OPERATOR_FINISHED, wmEvent::x, and wmEvent::y.
Referenced by FILE_OT_highlight().
Definition at line 516 of file file_ops.c.
References FileSelectParams::active_file, BLI_in_rcti(), ED_fileselect_get_params(), ED_fileselect_layout_offset(), filelist_numfiles(), SpaceFile::files, SpaceFile::layout, View2D::mask, NULL, View2D::tot, UI_view2d_region_to_view(), ARegion::v2d, ARegion::winrct, rcti::xmin, rctf::xmin, rctf::ymax, and rcti::ymin.
Referenced by file_highlight_invoke(), and file_main_area_draw().
int file_next_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 869 of file file_ops.c.
References CTX_wm_space_file(), FileSelectParams::dir, file_change_dir(), folderlist_new(), folderlist_popdir(), folderlist_pushdir(), SpaceFile::folders_next, SpaceFile::folders_prev, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, and WM_event_add_notifier().
static int file_operator_poll | ( | bContext * | C | ) | [static] |
Definition at line 588 of file file_ops.c.
References CTX_wm_space_file(), ED_operator_file_active(), and SpaceFile::op.
Referenced by FILE_OT_cancel(), and FILE_OT_execute().
void file_operator_to_sfile | ( | SpaceFile * | sfile, |
wmOperator * | op | ||
) |
Definition at line 665 of file file_ops.c.
References BLI_path_abs(), BLI_split_dirfile(), FileSelectParams::dir, FileSelectParams::file, FILE_MAX, G, SpaceFile::params, wmOperator::ptr, RNA_property_string_get(), and RNA_struct_find_property().
Referenced by file_draw_check_cb().
void FILE_OT_bookmark_add | ( | wmOperatorType * | ot | ) |
Definition at line 469 of file file_ops.c.
References bookmark_add_exec(), wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_bookmark_toggle | ( | struct wmOperatorType * | ot | ) |
Definition at line 1277 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_bookmark_toggle_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_cancel | ( | struct wmOperatorType * | ot | ) |
Definition at line 598 of file file_ops.c.
References wmOperatorType::description, wmOperatorType::exec, file_cancel_exec(), file_operator_poll(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_delete | ( | struct wmOperatorType * | ot | ) |
Definition at line 1413 of file file_ops.c.
References wmOperatorType::description, wmOperatorType::exec, file_delete_exec(), file_delete_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, wmOperatorType::poll, and WM_operator_confirm().
Referenced by file_operatortypes().
void FILE_OT_delete_bookmark | ( | wmOperatorType * | ot | ) |
Definition at line 502 of file file_ops.c.
References bookmark_delete_exec(), wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, wmOperatorType::idname, wmOperatorType::name, wmOperatorType::poll, RNA_def_int(), and wmOperatorType::srna.
Referenced by file_operatortypes().
void FILE_OT_directory | ( | struct wmOperatorType * | ot | ) |
Definition at line 1188 of file file_ops.c.
References wmOperatorType::description, wmOperatorType::exec, file_directory_exec(), file_directory_invoke(), file_directory_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_directory_new | ( | struct wmOperatorType * | ot | ) |
Definition at line 1071 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_directory_new_exec(), FILE_MAX, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, wmOperatorType::poll, RNA_def_string_dir_path(), wmOperatorType::srna, and WM_operator_confirm().
Referenced by file_operatortypes().
void FILE_OT_execute | ( | struct wmOperatorType * | ot | ) |
Definition at line 768 of file file_ops.c.
References wmOperatorType::description, wmOperatorType::exec, file_exec(), file_operator_poll(), wmOperatorType::idname, wmOperatorType::name, wmOperatorType::poll, RNA_def_boolean(), and wmOperatorType::srna.
Referenced by file_operatortypes().
void FILE_OT_filenum | ( | struct wmOperatorType * | ot | ) |
Definition at line 1307 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_filenum_exec(), wmOperatorType::idname, wmOperatorType::name, wmOperatorType::poll, RNA_def_int(), and wmOperatorType::srna.
Referenced by file_operatortypes().
void FILE_OT_hidedot | ( | struct wmOperatorType * | ot | ) |
Definition at line 1227 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_hidedot_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_highlight | ( | struct wmOperatorType * | ot | ) |
Definition at line 564 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), file_highlight_invoke(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_next | ( | struct wmOperatorType * | ot | ) |
Definition at line 857 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_next_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_parent | ( | struct wmOperatorType * | ot | ) |
Definition at line 801 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_parent_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_previous | ( | struct wmOperatorType * | ot | ) |
Definition at line 826 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_previous_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_refresh | ( | struct wmOperatorType * | ot | ) |
Definition at line 1201 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_refresh_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_rename | ( | struct wmOperatorType * | ot | ) |
Definition at line 1361 of file file_ops.c.
References wmOperatorType::description, wmOperatorType::exec, file_rename_exec(), file_rename_poll(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_select | ( | wmOperatorType * | ot | ) |
Definition at line 352 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), file_select_invoke(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, wmOperatorType::poll, RNA_def_boolean(), and wmOperatorType::srna.
Referenced by file_operatortypes().
void FILE_OT_select_all_toggle | ( | wmOperatorType * | ot | ) |
Definition at line 399 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_select_all_exec(), wmOperatorType::idname, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
void FILE_OT_select_bookmark | ( | wmOperatorType * | ot | ) |
Definition at line 436 of file file_ops.c.
References bookmark_select_exec(), wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, wmOperatorType::idname, wmOperatorType::name, wmOperatorType::poll, RNA_def_string(), and wmOperatorType::srna.
Referenced by file_operatortypes().
void FILE_OT_select_border | ( | wmOperatorType * | ot | ) |
Definition at line 301 of file file_ops.c.
References wmOperatorType::cancel, wmOperatorType::description, ED_operator_file_active(), wmOperatorType::exec, file_border_select_exec(), file_border_select_modal(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, wmOperatorType::poll, WM_border_select_cancel(), WM_border_select_invoke(), and WM_operator_properties_gesture_border().
Referenced by file_operatortypes().
void FILE_OT_smoothscroll | ( | wmOperatorType * | ot | ) |
Definition at line 983 of file file_ops.c.
References wmOperatorType::description, ED_operator_file_active(), file_smoothscroll_invoke(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, and wmOperatorType::poll.
Referenced by file_operatortypes().
int file_parent_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 783 of file file_ops.c.
References BLI_cleanup_dir(), BLI_has_parent(), BLI_parent_dir(), CTX_wm_space_file(), FileSelectParams::dir, file_change_dir(), G, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, and WM_event_add_notifier().
int file_previous_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) |
Definition at line 838 of file file_ops.c.
References CTX_wm_space_file(), FileSelectParams::dir, file_change_dir(), folderlist_new(), folderlist_popdir(), folderlist_pushdir(), SpaceFile::folders_next, SpaceFile::folders_prev, NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, SpaceFile::params, and WM_event_add_notifier().
static int file_refresh_exec | ( | bContext * | C, |
wmOperator * | UNUSEDunused | ||
) | [static] |
Definition at line 814 of file file_ops.c.
References CTX_wm_space_file(), ED_fileselect_clear(), NC_SPACE, ND_SPACE_FILE_LIST, NULL, OPERATOR_FINISHED, and WM_event_add_notifier().
Referenced by FILE_OT_refresh().
static int file_rename_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 1322 of file file_ops.c.
References FileSelectParams::active_file, BLI_strncpy(), CHECK_ALL, CTX_wm_area(), CTX_wm_space_data(), ED_area_tag_redraw(), EDITING_FILE, FILE_MAXFILE, FILE_SEL_ADD, filelist_file(), filelist_numfiles(), filelist_select_file(), SpaceFile::files, OPERATOR_FINISHED, SpaceFile::params, direntry::relname, FileSelectParams::renameedit, and FileSelectParams::renamefile.
Referenced by FILE_OT_rename().
static int file_rename_poll | ( | bContext * | C | ) | [static] |
Definition at line 1343 of file file_ops.c.
References FileSelectParams::active_file, CTX_wm_space_file(), ED_operator_file_active(), FILE_MAX, filelist_islibrary(), SpaceFile::files, and SpaceFile::params.
Referenced by FILE_OT_rename().
static FileSelect file_select | ( | bContext * | C, |
const rcti * | rect, | ||
FileSelType | select, | ||
short | fill | ||
) | [static] |
Definition at line 204 of file file_ops.c.
References CHECK_ALL, CHECK_DIRS, CTX_wm_space_file(), FILE_DIRSEL_ONLY, file_draw_check_cb(), FILE_SEL_ADD, FILE_SEL_TOGGLE, file_select_do(), FILE_SELECT_NOTHING, file_selection_get(), filelist_is_selected(), filelist_select(), SpaceFile::files, FileSelection::first, FileSelectParams::flag, FileSelection::last, NULL, SpaceFile::params, and SELECTED_FILE.
Referenced by file_border_select_exec(), and file_select_invoke().
static int file_select_all_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 368 of file file_ops.c.
References CHECK_ALL, CHECK_DIRS, CHECK_FILES, CTX_wm_area(), CTX_wm_space_file(), ED_area_tag_redraw(), FILE_DIRSEL_ONLY, FILE_SEL_ADD, FILE_SEL_REMOVE, filelist_is_selected(), filelist_numfiles(), filelist_select(), SpaceFile::files, FileSelection::first, FileSelectParams::flag, i, FileSelection::last, OPERATOR_FINISHED, SpaceFile::params, and SELECTED_FILE.
Referenced by FILE_OT_select_all_toggle().
static FileSelect file_select_do | ( | bContext * | C, |
int | selected_idx | ||
) | [static] |
Definition at line 158 of file file_ops.c.
References FileSelectParams::active_file, BLI_add_slash(), BLI_cleanup_dir(), BLI_parent_dir(), BLI_strncpy(), CTX_wm_space_file(), FileSelectParams::dir, ED_fileselect_get_params(), FileSelectParams::file, file_change_dir(), FILE_MAX, FILE_MAXFILE, FILE_SELECT_DIR, FILE_SELECT_FILE, FILE_SELECT_NOTHING, filelist_file(), filelist_numfiles(), SpaceFile::files, G, direntry::relname, strlen(), and direntry::type.
Referenced by file_select().
static int file_select_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | event | ||
) | [static] |
Definition at line 319 of file file_ops.c.
References BLI_in_rcti(), CTX_wm_region(), CTX_wm_space_file(), file_deselect_all(), FILE_SEL_ADD, FILE_SEL_TOGGLE, file_select(), FILE_SELECT_DIR, FILE_SELECT_FILE, View2D::mask, NC_SPACE, ND_SPACE_FILE_LIST, ND_SPACE_FILE_PARAMS, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, ARegion::regiontype, RGN_TYPE_WINDOW, RNA_boolean_get(), SELECTED_FILE, ARegion::v2d, WM_event_add_mousemove(), WM_event_add_notifier(), rcti::xmax, rcti::xmin, rcti::ymax, and rcti::ymin.
Referenced by FILE_OT_select().
static FileSelection file_selection_get | ( | bContext * | C, |
const rcti * | rect, | ||
short | fill | ||
) | [static] |
Definition at line 130 of file file_ops.c.
References CHECK_ALL, clamp_to_filelist(), CTX_wm_region(), CTX_wm_space_file(), filelist_is_selected(), filelist_numfiles(), SpaceFile::files, find_file_mouse_rect(), FileSelection::first, and FileSelection::last.
Referenced by file_border_select_modal(), and file_select().
void file_sfile_to_operator | ( | wmOperator * | op, |
SpaceFile * | sfile, | ||
char * | filepath | ||
) |
Definition at line 611 of file file_ops.c.
References BLI_join_dirfile(), BLI_path_rel(), CHECK_DIRS, CHECK_FILES, FileSelectParams::dir, FileSelectParams::file, FILE_MAX, filelist_file(), filelist_is_selected(), filelist_numfiles(), SpaceFile::files, G, i, SpaceFile::params, wmOperator::ptr, direntry::relname, RNA_boolean_get(), RNA_property_collection_add(), RNA_property_collection_clear(), RNA_string_set(), and RNA_struct_find_property().
Referenced by file_draw_check_cb(), and file_exec().
static int file_smoothscroll_invoke | ( | bContext * | C, |
wmOperator * | UNUSEDop, | ||
wmEvent * | event | ||
) | [static] |
Definition at line 891 of file file_ops.c.
References BKE_area_find_region_type(), CHECK_ALL, FileLayout::columns, CTX_wm_area(), CTX_wm_manager(), CTX_wm_region(), CTX_wm_region_set(), CTX_wm_space_file(), CTX_wm_window(), View2D::cur, wmEvent::customdata, ED_fileselect_layout_numfiles(), ED_fileselect_layout_offset(), ED_region_tag_redraw(), FILE_LAYOUT_HOR, filelist_is_selected(), filelist_numfiles(), SpaceFile::files, FileLayout::flag, i, if(), SpaceFile::layout, NULL, OPERATOR_FINISHED, OPERATOR_PASS_THROUGH, ARegion::regiontype, RGN_TYPE_WINDOW, FileLayout::rows, SpaceFile::scroll_offset, SpaceFile::smoothscroll_timer, ARegion::v2d, WM_event_remove_timer(), WM_operator_name_call(), rctf::xmin, and rctf::ymax.
Referenced by FILE_OT_smoothscroll().
static FileSelection find_file_mouse_rect | ( | SpaceFile * | sfile, |
struct ARegion * | ar, | ||
const rcti * | rect | ||
) | [static] |
Definition at line 72 of file file_ops.c.
References BLI_init_rcti(), ED_fileselect_layout_offset_rect(), SpaceFile::layout, View2D::tot, UI_view2d_region_to_view(), ARegion::v2d, rcti::xmax, rcti::xmin, rctf::xmin, rcti::ymax, rctf::ymax, and rcti::ymin.
Referenced by file_selection_get().
static int new_folder_path | ( | const char * | parent, |
char * | folder, | ||
char * | name | ||
) | [static] |
Definition at line 1001 of file file_ops.c.
References BLI_exists(), BLI_join_dirfile(), BLI_snprintf(), BLI_strncpy(), FILE_MAX, FILE_MAXFILE, i, and len().
Referenced by file_directory_new_exec().