Mercurial > pidgin
comparison src/prpl.h @ 3609:4faf84dfdda2
[gaim-migrate @ 3722]
First draft of the file transfer prpl interface.
committer: Tailor Script <tailor@pidgin.im>
| author | Rob Flynn <gaim@robflynn.com> |
|---|---|
| date | Wed, 09 Oct 2002 04:55:29 +0000 |
| parents | bdd0bebd2d04 |
| children | 9682c0e022c6 |
comparison
equal
deleted
inserted
replaced
| 3608:7703b2689791 | 3609:4faf84dfdda2 |
|---|---|
| 76 #define OPT_PROTO_IM_IMAGE 0x00000080 | 76 #define OPT_PROTO_IM_IMAGE 0x00000080 |
| 77 | 77 |
| 78 #define GAIM_AWAY_CUSTOM "Custom" | 78 #define GAIM_AWAY_CUSTOM "Custom" |
| 79 | 79 |
| 80 typedef void (*proto_init)(struct prpl *); | 80 typedef void (*proto_init)(struct prpl *); |
| 81 | |
| 82 struct file_transfer; | |
| 81 | 83 |
| 82 struct _prpl_smiley { | 84 struct _prpl_smiley { |
| 83 char *key; | 85 char *key; |
| 84 char **xpm; | 86 char **xpm; |
| 85 int show; | 87 int show; |
| 178 | 180 |
| 179 /* this is really bad. */ | 181 /* this is really bad. */ |
| 180 void (* convo_closed) (struct gaim_connection *, char *who); | 182 void (* convo_closed) (struct gaim_connection *, char *who); |
| 181 | 183 |
| 182 char *(* normalize)(const char *); | 184 char *(* normalize)(const char *); |
| 185 | |
| 186 /* transfer files */ | |
| 187 void (* file_transfer_cancel) (struct gaim_connection *, struct file_transfer *); | |
| 188 void (* file_transfer_in) (struct gaim_connection *, struct file_transfer *, int); | |
| 189 void (* file_transfer_out) (struct gaim_connection *, struct file_transfer *, const char *, int, int); | |
| 190 void (* file_transfer_nextfile) (struct gaim_connection *, struct file_transfer *); | |
| 191 void (* file_transfer_data_chunk)(struct gaim_connection *, struct file_transfer *, const char *, int); | |
| 192 void (* file_transfer_done) (struct gaim_connection *, struct file_transfer *); | |
| 183 }; | 193 }; |
| 184 | 194 |
| 185 extern GSList *protocols; | 195 extern GSList *protocols; |
| 186 extern prpl_accounts[]; | 196 extern prpl_accounts[]; |
| 187 | 197 |
| 208 extern void set_icon_data(struct gaim_connection *, char *, void *, int); | 218 extern void set_icon_data(struct gaim_connection *, char *, void *, int); |
| 209 extern void *get_icon_data(struct gaim_connection *, char *, int *); | 219 extern void *get_icon_data(struct gaim_connection *, char *, int *); |
| 210 | 220 |
| 211 extern GSList *add_smiley(GSList *, char *, char **, int) ; | 221 extern GSList *add_smiley(GSList *, char *, char **, int) ; |
| 212 | 222 |
| 223 /* file transfer stuff */ | |
| 224 extern struct file_transfer *transfer_in_add(struct gaim_connection *gc, | |
| 225 const char *who, const char *filename, int totsize, | |
| 226 int totfiles, const char *msg); | |
| 227 extern struct file_transfer *transfer_out_add(struct gaim_connection *gc, | |
| 228 const char *who); | |
| 229 extern int transfer_abort(struct file_transfer *xfer, const char *why); | |
| 230 extern int transfer_out_do(struct file_transfer *xfer, int fd, | |
| 231 int offset); | |
| 232 extern int transfer_in_do(struct file_transfer *xfer, int fd, | |
| 233 const char *filename, int size); | |
| 234 int transfer_get_file_info(struct file_transfer *xfer, int *size, | |
| 235 char **name); | |
| 236 | |
| 213 #endif /* _PRPL_H_ */ | 237 #endif /* _PRPL_H_ */ |
