summaryrefslogtreecommitdiff
path: root/src/irc/irc.h
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2006-04-12 13:34:33 +0000
committerSebastien Helleu <flashcode@flashtux.org>2006-04-12 13:34:33 +0000
commit1bee0ba0b2f86e6e697e648acd565934ccd69e0b (patch)
treebc083222b3939a63b6670d247d2eaa4e9f21c7e2 /src/irc/irc.h
parent69730a21ddc2f867e0dd69fc2b34179f87aeecdb (diff)
downloadweechat-1bee0ba0b2f86e6e697e648acd565934ccd69e0b.zip
Added new option to customize input prompt, added nick modes, fixed commands 332, 333 (/topic now ok when channel is not opened)
Diffstat (limited to 'src/irc/irc.h')
-rw-r--r--src/irc/irc.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/src/irc/irc.h b/src/irc/irc.h
index 2b2b00959..906d5b08b 100644
--- a/src/irc/irc.h
+++ b/src/irc/irc.h
@@ -125,6 +125,20 @@ struct t_irc_channel
/* server types */
+#define NUM_NICK_MODES 7
+#define NICK_MODE_AWAY 0
+#define NICK_MODE_INVISIBLE 1
+#define NICK_MODE_WALLOPS 2
+#define NICK_MODE_RESTRICTED 3
+#define NICK_MODE_OPERATOR 4
+#define NICK_MODE_LOCAL_OPERATOR 5
+#define NICK_MODE_SERVER_NOTICES 6
+#define NICK_SET_MODE(server, set, mode) \
+ if (set) \
+ server->nick_modes[mode] = nick_modes[mode]; \
+ else \
+ server->nick_modes[mode] = ' ';
+
typedef struct t_irc_server t_irc_server;
struct t_irc_server
@@ -167,6 +181,7 @@ struct t_irc_server
#endif
char *unterminated_message; /* beginning of a message in input buf */
char *nick; /* current nickname */
+ char *nick_modes; /* nick modes */
time_t reconnect_start; /* this time + delay = reconnect time */
int reconnect_join; /* 1 if channels opened to rejoin */
int is_away; /* 1 is user is marker as away */
@@ -301,6 +316,7 @@ extern int check_away;
extern t_irc_dcc *dcc_list;
extern char *dcc_status_string[6];
extern char *channel_modes;
+extern char *nick_modes;
extern char *ignore_types[];
extern t_irc_ignore *irc_ignore;
extern t_irc_ignore *irc_last_ignore;
@@ -408,8 +424,8 @@ extern void irc_display_prefix (t_irc_server *, t_gui_buffer *, char *);
extern void irc_display_nick (t_gui_buffer *, t_irc_nick *, char *, int,
int, int, int);
extern void irc_display_away (t_irc_server *, char *, char *);
-extern void irc_display_mode (t_irc_server *, t_gui_buffer *, char *, char,
- char *, char *, char *, char *);
+extern void irc_display_mode (t_irc_server *, t_gui_buffer *, char *, char *,
+ char, char *, char *, char *, char *);
extern void irc_display_server (t_irc_server *ptr_server);
/* IRC commands issued by user (irc-send.c) */