From f5914992f316f8a628505067e108e7ba5a9590ba Mon Sep 17 00:00:00 2001 From: Magnus Damm Date: Sun, 8 Nov 2009 16:34:43 +0100 Subject: wget: factor out progress bar code Signed-off-by: Magnus Damm Signed-off-by: Denys Vlasenko --- include/libbb.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include') diff --git a/include/libbb.h b/include/libbb.h index d973d14..0f8973d 100644 --- a/include/libbb.h +++ b/include/libbb.h @@ -1451,6 +1451,16 @@ int print_flags_separated(const int *masks, const char *labels, int flags, const char *separator) FAST_FUNC; int print_flags(const masks_labels_t *ml, int flags) FAST_FUNC; +typedef struct bb_progress_t { + off_t lastsize; + unsigned lastupdate_sec; + unsigned start_sec; +} bb_progress_t; + +void bb_progress_init(bb_progress_t *p) FAST_FUNC; +void bb_progress_update(bb_progress_t *p, const char *curfile, + off_t beg_range, off_t transferred, + off_t totalsize) FAST_FUNC; extern const char *applet_name; /* "BusyBox vN.N.N (timestamp or extra_version)" */ -- cgit v1.1