1
0
mirror of https://github.com/irssi/irssi.git synced 2024-10-27 05:20:20 -04:00

Added support for dalnet's whois registered event.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@576 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-08-10 12:23:56 +00:00 committed by cras
parent d1a25e0fc2
commit fc890ebd82
3 changed files with 15 additions and 0 deletions

View File

@ -434,6 +434,17 @@ static void event_whois_oper(const char *data, IRC_SERVER_REC *server)
g_free(params); g_free(params);
} }
static void event_whois_registered(const char *data, IRC_SERVER_REC *server)
{
char *params, *nick;
g_return_if_fail(data != NULL);
params = event_get_params(data, 2, NULL, &nick);
printformat(server, nick, MSGLEVEL_CRAP, IRCTXT_WHOIS_REGISTERED, nick);
g_free(params);
}
static void event_whowas(const char *data, IRC_SERVER_REC *server) static void event_whowas(const char *data, IRC_SERVER_REC *server)
{ {
char *params, *nick, *user, *host, *realname; char *params, *nick, *user, *host, *realname;
@ -668,6 +679,7 @@ void fe_events_numeric_init(void)
signal_add("event 301", (SIGNAL_FUNC) event_whois_away); signal_add("event 301", (SIGNAL_FUNC) event_whois_away);
signal_add("event 312", (SIGNAL_FUNC) event_whois_server); signal_add("event 312", (SIGNAL_FUNC) event_whois_server);
signal_add("event 313", (SIGNAL_FUNC) event_whois_oper); signal_add("event 313", (SIGNAL_FUNC) event_whois_oper);
signal_add("event 307", (SIGNAL_FUNC) event_whois_registered);
signal_add("event 314", (SIGNAL_FUNC) event_whowas); signal_add("event 314", (SIGNAL_FUNC) event_whowas);
signal_add("event 317", (SIGNAL_FUNC) event_whois_idle); signal_add("event 317", (SIGNAL_FUNC) event_whois_idle);
signal_add("event 318", (SIGNAL_FUNC) event_end_of_whois); signal_add("event 318", (SIGNAL_FUNC) event_end_of_whois);
@ -723,6 +735,7 @@ void fe_events_numeric_deinit(void)
signal_remove("event 301", (SIGNAL_FUNC) event_whois_away); signal_remove("event 301", (SIGNAL_FUNC) event_whois_away);
signal_remove("event 312", (SIGNAL_FUNC) event_whois_server); signal_remove("event 312", (SIGNAL_FUNC) event_whois_server);
signal_remove("event 313", (SIGNAL_FUNC) event_whois_oper); signal_remove("event 313", (SIGNAL_FUNC) event_whois_oper);
signal_remove("event 307", (SIGNAL_FUNC) event_whois_registered);
signal_remove("event 314", (SIGNAL_FUNC) event_whowas); signal_remove("event 314", (SIGNAL_FUNC) event_whowas);
signal_remove("event 317", (SIGNAL_FUNC) event_whois_idle); signal_remove("event 317", (SIGNAL_FUNC) event_whois_idle);
signal_remove("event 318", (SIGNAL_FUNC) event_end_of_whois); signal_remove("event 318", (SIGNAL_FUNC) event_end_of_whois);

View File

@ -131,6 +131,7 @@ FORMAT_REC fecommon_irc_formats[] = {
{ "whois_idle_signon", " idle : $1 days $2 hours $3 mins $4 secs %K[%nsignon: $5%K]", 6, { 0, 1, 1, 1, 1, 0 } }, { "whois_idle_signon", " idle : $1 days $2 hours $3 mins $4 secs %K[%nsignon: $5%K]", 6, { 0, 1, 1, 1, 1, 0 } },
{ "whois_server", " server : $1 %K[%n$2%K]", 3, { 0, 0, 0 } }, { "whois_server", " server : $1 %K[%n$2%K]", 3, { 0, 0, 0 } },
{ "whois_oper", " : %_IRC operator%_", 1, { 0 } }, { "whois_oper", " : %_IRC operator%_", 1, { 0 } },
{ "whois_registered", " : has registered this nick", 1, { 0 } },
{ "whois_channels", " channels : $1", 2, { 0, 0 } }, { "whois_channels", " channels : $1", 2, { 0, 0 } },
{ "whois_away", " away : $1", 2, { 0, 0 } }, { "whois_away", " away : $1", 2, { 0, 0 } },
{ "end_of_whois", "End of WHOIS", 1, { 0 } }, { "end_of_whois", "End of WHOIS", 1, { 0 } },

View File

@ -106,6 +106,7 @@ enum {
IRCTXT_WHOIS_IDLE_SIGNON, IRCTXT_WHOIS_IDLE_SIGNON,
IRCTXT_WHOIS_SERVER, IRCTXT_WHOIS_SERVER,
IRCTXT_WHOIS_OPER, IRCTXT_WHOIS_OPER,
IRCTXT_WHOIS_REGISTERED,
IRCTXT_WHOIS_CHANNELS, IRCTXT_WHOIS_CHANNELS,
IRCTXT_WHOIS_AWAY, IRCTXT_WHOIS_AWAY,
IRCTXT_END_OF_WHOIS, IRCTXT_END_OF_WHOIS,