diff options
author | Alan F <ajf@eth0.org.uk> | 2014-02-19 08:54:10 +0000 |
---|---|---|
committer | Alan F <ajf@eth0.org.uk> | 2014-02-19 08:54:10 +0000 |
commit | 1d6f77d4c4fafd0a9cafddd2797249557e601dba (patch) | |
tree | 33dee51882a0475aff63ec6c6d9095c92c9ac5d4 /src/upload.h | |
parent | adf06453574270bf467b5f37e632c04c153ee90a (diff) |
refactor the torrent upload code (it's called from a few places so is probably worth it), and make it easier to use a HTTP response as the input.
Diffstat (limited to 'src/upload.h')
-rw-r--r-- | src/upload.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/upload.h b/src/upload.h new file mode 100644 index 0000000..9f3f719 --- /dev/null +++ b/src/upload.h @@ -0,0 +1,25 @@ +#ifndef UPLOAD_H_ +#define UPLOAD_H_ + +#include <glib.h> + +#include "trg-client.h" +#include "trg-main-window.h" + +typedef struct { + GSList *list; // list of filenames + trg_response *upload_response; // OR: a HTTP response containing a torrent + TrgClient *client; + gpointer cb_data; + TrgMainWindow *main_window; // a parent window to attach any error dialogs to + guint flags; + gchar *dir; + gint priority; + gboolean extra_args; + guint progress_index; + +} trg_upload; + +void trg_do_upload(trg_upload *upload); + +#endif |