1998-02-27 07:54:42 +03:00
|
|
|
#ifndef __FILE_H
|
|
|
|
#define __FILE_H
|
|
|
|
|
1999-01-14 04:10:32 +03:00
|
|
|
#include "fileopctx.h"
|
1998-11-18 05:31:23 +03:00
|
|
|
#include "background.h"
|
|
|
|
|
2002-10-22 01:03:22 +04:00
|
|
|
extern int safe_delete;
|
1998-02-27 07:54:42 +03:00
|
|
|
|
1998-04-17 04:21:53 +04:00
|
|
|
struct link;
|
|
|
|
|
1999-01-14 04:10:32 +03:00
|
|
|
int copy_file_file (FileOpContext *ctx, char *s, char *d, int ask_overwrite,
|
2001-09-21 09:04:38 +04:00
|
|
|
off_t *progress_count, double *progress_bytes,
|
1998-12-29 19:52:49 +03:00
|
|
|
int is_toplevel_file);
|
1999-01-14 04:10:32 +03:00
|
|
|
int move_file_file (FileOpContext *ctx, char *s, char *d,
|
2001-09-21 09:04:38 +04:00
|
|
|
off_t *progress_count, double *progress_bytes);
|
1999-01-14 04:10:32 +03:00
|
|
|
int move_dir_dir (FileOpContext *ctx, char *s, char *d,
|
2001-09-21 09:04:38 +04:00
|
|
|
off_t *progress_count, double *progress_bytes);
|
1999-01-14 04:10:32 +03:00
|
|
|
int copy_dir_dir (FileOpContext *ctx, char *s, char *d, int toplevel, int move_over,
|
1998-12-05 02:39:41 +03:00
|
|
|
int delete, struct link *parent_dirs,
|
2001-09-21 09:04:38 +04:00
|
|
|
off_t *progress_count, double *progress_bytes);
|
|
|
|
int erase_dir (FileOpContext *ctx, char *s, off_t *progress_count, double *progress_bytes);
|
|
|
|
int erase_file (FileOpContext *ctx, char *s, off_t *progress_count, double *progress_bytes,
|
1999-01-14 04:10:32 +03:00
|
|
|
int is_toplevel_file);
|
|
|
|
int erase_dir_iff_empty (FileOpContext *ctx, char *s);
|
1998-02-27 07:54:42 +03:00
|
|
|
|
1998-12-17 07:51:24 +03:00
|
|
|
int panel_operate (void *source_panel, FileOperation op,
|
1999-01-14 04:10:32 +03:00
|
|
|
char *thedefault, int ask_user);
|
1998-11-18 05:31:23 +03:00
|
|
|
|
1998-12-05 02:39:41 +03:00
|
|
|
extern int file_op_compute_totals;
|
1998-02-27 07:54:42 +03:00
|
|
|
|
|
|
|
/* Error reporting routines */
|
|
|
|
/* Report error with one file */
|
|
|
|
int file_error (char *format, char *file);
|
|
|
|
|
|
|
|
/* Report error with two files */
|
|
|
|
int files_error (char *format, char *file1, char *file2);
|
|
|
|
|
|
|
|
/* Query routines */
|
1998-12-05 02:39:41 +03:00
|
|
|
|
2001-09-21 09:04:38 +04:00
|
|
|
void compute_dir_size (char *dirname, off_t *ret_marked, double *ret_total);
|
1998-11-18 05:31:23 +03:00
|
|
|
|
2001-09-21 09:04:38 +04:00
|
|
|
#endif /* !__FILE_H */
|