mirror of
https://github.com/rkd77/elinks.git
synced 2025-01-03 14:57:44 -05:00
[download] enum download_flags -> download_flags_T
This commit is contained in:
parent
bd27d9a793
commit
2b9f3d5cf9
@ -571,7 +571,7 @@ download_data(struct download *download, struct file_download *file_download)
|
|||||||
*
|
*
|
||||||
* @relates lun_hop */
|
* @relates lun_hop */
|
||||||
typedef void lun_callback_T(struct terminal *term, char *file,
|
typedef void lun_callback_T(struct terminal *term, char *file,
|
||||||
void *data, enum download_flags flags);
|
void *data, download_flags_T flags);
|
||||||
|
|
||||||
/** The user is being asked what to do when the local file for
|
/** The user is being asked what to do when the local file for
|
||||||
* the download already exists. This structure is allocated by
|
* the download already exists. This structure is allocated by
|
||||||
@ -606,7 +606,7 @@ struct lun_hop {
|
|||||||
* @invariant The ::DOWNLOAD_RESUME_SELECTED bit should be
|
* @invariant The ::DOWNLOAD_RESUME_SELECTED bit should be
|
||||||
* clear here because otherwise there would have been no
|
* clear here because otherwise there would have been no
|
||||||
* reason to ask the user and initialize this structure. */
|
* reason to ask the user and initialize this structure. */
|
||||||
enum download_flags flags;
|
download_flags_T flags;
|
||||||
};
|
};
|
||||||
|
|
||||||
/** Data saved by common_download() for the common_download_do()
|
/** Data saved by common_download() for the common_download_do()
|
||||||
@ -762,7 +762,7 @@ lun_resume(void *lun_hop_)
|
|||||||
* @relates lun_hop */
|
* @relates lun_hop */
|
||||||
static void
|
static void
|
||||||
lookup_unique_name(struct terminal *term, char *ofile,
|
lookup_unique_name(struct terminal *term, char *ofile,
|
||||||
enum download_flags flags,
|
download_flags_T flags,
|
||||||
lun_callback_T *callback, void *data)
|
lun_callback_T *callback, void *data)
|
||||||
{
|
{
|
||||||
/* [gettext_accelerator_context(.lookup_unique_name)] */
|
/* [gettext_accelerator_context(.lookup_unique_name)] */
|
||||||
@ -861,7 +861,7 @@ error:
|
|||||||
* @relates cdf_hop */
|
* @relates cdf_hop */
|
||||||
static void
|
static void
|
||||||
create_download_file_do(struct terminal *term, char *file,
|
create_download_file_do(struct terminal *term, char *file,
|
||||||
void *data, enum download_flags flags)
|
void *data, download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct cdf_hop *cdf_hop = (struct cdf_hop *)data;
|
struct cdf_hop *cdf_hop = (struct cdf_hop *)data;
|
||||||
char *wd;
|
char *wd;
|
||||||
@ -970,7 +970,7 @@ finish:
|
|||||||
void
|
void
|
||||||
create_download_file(struct terminal *term, char *fi,
|
create_download_file(struct terminal *term, char *fi,
|
||||||
char **real_file,
|
char **real_file,
|
||||||
enum download_flags flags,
|
download_flags_T flags,
|
||||||
cdf_callback_T *callback, void *data)
|
cdf_callback_T *callback, void *data)
|
||||||
{
|
{
|
||||||
struct cdf_hop *cdf_hop = (struct cdf_hop *)mem_calloc(1, sizeof(*cdf_hop));
|
struct cdf_hop *cdf_hop = (struct cdf_hop *)mem_calloc(1, sizeof(*cdf_hop));
|
||||||
@ -1105,7 +1105,7 @@ subst_file(char *prog, char *file, char *uri)
|
|||||||
* @relates cmdw_hop */
|
* @relates cmdw_hop */
|
||||||
static void
|
static void
|
||||||
common_download_do(struct terminal *term, int fd, void *data,
|
common_download_do(struct terminal *term, int fd, void *data,
|
||||||
enum download_flags flags)
|
download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct file_download *file_download;
|
struct file_download *file_download;
|
||||||
struct cmdw_hop *cmdw_hop = (struct cmdw_hop *)data;
|
struct cmdw_hop *cmdw_hop = (struct cmdw_hop *)data;
|
||||||
@ -1148,7 +1148,7 @@ finish:
|
|||||||
* @relates cmdw_hop */
|
* @relates cmdw_hop */
|
||||||
static void
|
static void
|
||||||
common_download(struct session *ses, char *file,
|
common_download(struct session *ses, char *file,
|
||||||
enum download_flags flags)
|
download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct cmdw_hop *cmdw_hop;
|
struct cmdw_hop *cmdw_hop;
|
||||||
|
|
||||||
@ -1207,7 +1207,7 @@ resume_download(void *ses, char *file)
|
|||||||
static void
|
static void
|
||||||
transform_codw_to_cmdw(struct terminal *term, int fd,
|
transform_codw_to_cmdw(struct terminal *term, int fd,
|
||||||
struct codw_hop *codw_hop,
|
struct codw_hop *codw_hop,
|
||||||
enum download_flags flags)
|
download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct type_query *type_query = codw_hop->type_query;
|
struct type_query *type_query = codw_hop->type_query;
|
||||||
struct cmdw_hop *cmdw_hop = (struct cmdw_hop *)mem_calloc(1, sizeof(*cmdw_hop));
|
struct cmdw_hop *cmdw_hop = (struct cmdw_hop *)mem_calloc(1, sizeof(*cmdw_hop));
|
||||||
@ -1231,7 +1231,7 @@ transform_codw_to_cmdw(struct terminal *term, int fd,
|
|||||||
* @relates codw_hop */
|
* @relates codw_hop */
|
||||||
static void
|
static void
|
||||||
continue_download_do(struct terminal *term, int fd, void *data,
|
continue_download_do(struct terminal *term, int fd, void *data,
|
||||||
enum download_flags flags)
|
download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct codw_hop *codw_hop = (struct codw_hop *)data;
|
struct codw_hop *codw_hop = (struct codw_hop *)data;
|
||||||
struct file_download *file_download = NULL;
|
struct file_download *file_download = NULL;
|
||||||
|
@ -47,6 +47,8 @@ enum download_flags {
|
|||||||
DOWNLOAD_OVERWRITE = 8
|
DOWNLOAD_OVERWRITE = 8
|
||||||
};
|
};
|
||||||
|
|
||||||
|
typedef unsigned char download_flags_T;
|
||||||
|
|
||||||
struct download {
|
struct download {
|
||||||
/* XXX: order matters there, there's some hard initialization in
|
/* XXX: order matters there, there's some hard initialization in
|
||||||
* src/session/session.c and src/viewer/text/view.c */
|
* src/session/session.c and src/viewer/text/view.c */
|
||||||
@ -210,12 +212,12 @@ int are_there_downloads(void);
|
|||||||
*
|
*
|
||||||
* @relates cdf_hop */
|
* @relates cdf_hop */
|
||||||
typedef void cdf_callback_T(struct terminal *term, int fd,
|
typedef void cdf_callback_T(struct terminal *term, int fd,
|
||||||
void *data, enum download_flags flags);
|
void *data, download_flags_T flags);
|
||||||
|
|
||||||
void start_download(void *, char *);
|
void start_download(void *, char *);
|
||||||
void resume_download(void *, char *);
|
void resume_download(void *, char *);
|
||||||
void create_download_file(struct terminal *, char *, char **,
|
void create_download_file(struct terminal *, char *, char **,
|
||||||
enum download_flags, cdf_callback_T *, void *);
|
download_flags_T, cdf_callback_T *, void *);
|
||||||
|
|
||||||
void abort_all_downloads(void);
|
void abort_all_downloads(void);
|
||||||
void destroy_downloads(struct session *);
|
void destroy_downloads(struct session *);
|
||||||
|
@ -1833,7 +1833,7 @@ save_as(struct session *ses, struct document_view *doc_view, int magic)
|
|||||||
* create_download_finish(). */
|
* create_download_finish(). */
|
||||||
static void
|
static void
|
||||||
save_formatted_finish(struct terminal *term, int h,
|
save_formatted_finish(struct terminal *term, int h,
|
||||||
void *data, enum download_flags flags)
|
void *data, download_flags_T flags)
|
||||||
{
|
{
|
||||||
struct document *document = (struct document *)data;
|
struct document *document = (struct document *)data;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user