36 |
|
|
37 |
|
|
38 |
/* |
/* |
39 |
* irc_display_prefix: display prefix for action or info message |
* irc_display_prefix: display a prefix for action/info/error msg |
40 |
* prefix must be 3 chars length |
* prefix must be 3 chars length |
41 |
*/ |
*/ |
42 |
|
|
43 |
void |
void |
44 |
irc_display_prefix (t_gui_buffer *buffer, char *prefix) |
irc_display_prefix (t_irc_server *server, t_gui_buffer *buffer, char *prefix) |
45 |
{ |
{ |
46 |
int type; |
int type; |
47 |
|
|
65 |
else |
else |
66 |
gui_printf_color (buffer, COLOR_WIN_CHAT_PREFIX1, "%s ", prefix); |
gui_printf_color (buffer, COLOR_WIN_CHAT_PREFIX1, "%s ", prefix); |
67 |
} |
} |
68 |
|
if (server && (server->buffer == buffer) && buffer->all_servers) |
69 |
|
{ |
70 |
|
gui_printf_type_color (buffer, type, COLOR_WIN_CHAT_DARK, "["); |
71 |
|
gui_printf_type_color (buffer, type, COLOR_WIN_CHAT_SERVER, "%s", server->name); |
72 |
|
gui_printf_type_color (buffer, type, COLOR_WIN_CHAT_DARK, "] "); |
73 |
|
} |
74 |
} |
} |
75 |
|
|
76 |
/* |
/* |
139 |
*/ |
*/ |
140 |
|
|
141 |
void |
void |
142 |
irc_display_mode (t_gui_buffer *buffer, char *channel_name, char set_flag, |
irc_display_mode (t_irc_server *server, t_gui_buffer *buffer, |
143 |
|
char *channel_name, char set_flag, |
144 |
char *symbol, char *nick_host, char *message, char *param) |
char *symbol, char *nick_host, char *message, char *param) |
145 |
{ |
{ |
146 |
irc_display_prefix (buffer, PREFIX_INFO); |
irc_display_prefix (server, buffer, PREFIX_INFO); |
147 |
gui_printf_color (buffer, COLOR_WIN_CHAT_DARK, "["); |
gui_printf_color (buffer, COLOR_WIN_CHAT_DARK, "["); |
148 |
gui_printf_color (buffer, COLOR_WIN_CHAT_CHANNEL, "%s", channel_name); |
gui_printf_color (buffer, COLOR_WIN_CHAT_CHANNEL, "%s", channel_name); |
149 |
gui_printf_color (buffer, COLOR_WIN_CHAT, "/"); |
gui_printf_color (buffer, COLOR_WIN_CHAT, "/"); |