/[weechat]/weechat/src/irc/irc.h
ViewVC logotype

Diff of /weechat/src/irc/irc.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.42 by flashcode, Sun Feb 20 13:37:49 2005 UTC revision 1.43 by flashcode, Sun Feb 27 02:40:12 2005 UTC
# Line 71  Line 71 
71  #define DCC_FAILED              4   /* DCC failed                           */  #define DCC_FAILED              4   /* DCC failed                           */
72  #define DCC_ABORTED             5   /* DCC aborted by user                  */  #define DCC_ABORTED             5   /* DCC aborted by user                  */
73    
74    #define DCC_IS_CHAT(type) ((type == DCC_CHAT_RECV) || (type == DCC_CHAT_SEND))
75    #define DCC_IS_FILE(type) ((type == DCC_FILE_RECV) || (type == DCC_FILE_SEND))
76    #define DCC_IS_RECV(type) ((type == DCC_CHAT_RECV) || (type == DCC_FILE_RECV))
77    #define DCC_IS_SEND(type) ((type == DCC_CHAT_SEND) || (type == DCC_FILE_SEND))
78    
79    #define DCC_ENDED(status) ((status == DCC_DONE) || (status == DCC_FAILED) || \
80                              (status == DCC_ABORTED))
81    
82  /* nick types */  /* nick types */
83    
84  typedef struct t_irc_nick t_irc_nick;  typedef struct t_irc_nick t_irc_nick;
# Line 100  typedef struct t_irc_channel t_irc_chann Line 108  typedef struct t_irc_channel t_irc_chann
108  struct t_irc_channel  struct t_irc_channel
109  {  {
110      int type;                       /* channel type                         */      int type;                       /* channel type                         */
111        void *dcc_chat;                 /* DCC CHAT pointer (NULL if not DCC)   */
112      char *name;                     /* name of channel (exemple: "#abc")    */      char *name;                     /* name of channel (exemple: "#abc")    */
113      char *topic;                    /* topic of channel (host for private)  */      char *topic;                    /* topic of channel (host for private)  */
114      char modes[NUM_CHANNEL_MODES+1];/* channel modes                        */      char modes[NUM_CHANNEL_MODES+1];/* channel modes                        */
# Line 142  struct t_irc_server Line 151  struct t_irc_server
151      pid_t child_pid;                /* pid of child process (connecting)    */      pid_t child_pid;                /* pid of child process (connecting)    */
152      int child_read;                 /* to read into child pipe              */      int child_read;                 /* to read into child pipe              */
153      int child_write;                /* to write into child pipe             */      int child_write;                /* to write into child pipe             */
154      int sock4;                      /* socket for server                    */      int sock;                       /* socket for server                    */
155      int is_connected;               /* 1 if WeeChat is connected to server  */      int is_connected;               /* 1 if WeeChat is connected to server  */
156      char *unterminated_message;     /* beginning of a message in input buf  */      char *unterminated_message;     /* beginning of a message in input buf  */
157      char *nick;                     /* current nickname                     */      char *nick;                     /* current nickname                     */
# Line 198  typedef struct t_irc_dcc t_irc_dcc; Line 207  typedef struct t_irc_dcc t_irc_dcc;
207  struct t_irc_dcc  struct t_irc_dcc
208  {  {
209      t_irc_server *server;           /* irc server                           */      t_irc_server *server;           /* irc server                           */
210        t_irc_channel *channel;         /* irc channel (for DCC chat only)      */
211      int type;                       /* DCC type (send or receive)           */      int type;                       /* DCC type (send or receive)           */
212      int status;                     /* DCC status (waiting, sending, ..)    */      int status;                     /* DCC status (waiting, sending, ..)    */
213      unsigned long addr;             /* IP address                           */      unsigned long addr;             /* IP address                           */
214      int port;                       /* port                                 */      int port;                       /* port                                 */
215      char *nick;                     /* remote nick                          */      char *nick;                     /* remote nick                          */
216      int sock;                       /* socket for connection                */      int sock;                       /* socket for connection                */
217        char *unterminated_message;     /* beginning of a message in input buf  */
218      int file;                       /* local file (for reading or writing)  */      int file;                       /* local file (for reading or writing)  */
219      char *filename;                 /* filename (given by sender)           */      char *filename;                 /* filename (given by sender)           */
220      char *local_filename;           /* local filename (with path)           */      char *local_filename;           /* local filename (with path)           */
# Line 260  extern int string_is_channel (char *); Line 271  extern int string_is_channel (char *);
271  extern void channel_remove_away (t_irc_channel *);  extern void channel_remove_away (t_irc_channel *);
272  extern void channel_check_away (t_irc_server *, t_irc_channel *);  extern void channel_check_away (t_irc_server *, t_irc_channel *);
273  extern void channel_set_away (t_irc_channel *, char *, int);  extern void channel_set_away (t_irc_channel *, char *, int);
274    extern int channel_create_dcc (t_irc_dcc *);
275    extern void channel_remove_dcc (t_irc_dcc *);
276    
277  /* nick functions (irc-nick.c) */  /* nick functions (irc-nick.c) */
278    
# Line 275  extern void nick_set_away (t_irc_channel Line 288  extern void nick_set_away (t_irc_channel
288    
289  /* DCC functions (irc-dcc.c) */  /* DCC functions (irc-dcc.c) */
290    
291    extern void dcc_redraw (int);
292  extern void dcc_free (t_irc_dcc *);  extern void dcc_free (t_irc_dcc *);
293  extern void dcc_close (t_irc_dcc *, int);  extern void dcc_close (t_irc_dcc *, int);
294  extern void dcc_accept (t_irc_dcc *);  extern void dcc_accept (t_irc_dcc *);
295  extern t_irc_dcc *dcc_add (t_irc_server *, int, unsigned long, int, char *, int,  extern t_irc_dcc *dcc_add (t_irc_server *, int, unsigned long, int, char *, int,
296                             char *, char *, unsigned long);                             char *, char *, unsigned long);
297    extern void dcc_send_request (t_irc_server *, int, char *, char *);
298    extern void dcc_chat_sendf (t_irc_dcc *, char *, ...);
299  extern void dcc_handle ();  extern void dcc_handle ();
 extern void dcc_send (t_irc_server *, char *, char *);  
300  extern void dcc_end ();  extern void dcc_end ();
301    
302  /* IRC display (irc-diplay.c) */  /* IRC display (irc-diplay.c) */

Legend:
Removed from v.1.42  
changed lines
  Added in v.1.43

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26