mirror of
https://github.com/irssi/irssi.git
synced 2026-08-11 21:00:40 +02:00
Config file: ircnets -> chatnets, added type = "chat protocol" to
chatnet config. Moved reading chatnets to core. Lots of other multiprotocol updates. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1237 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
513e140bce
commit
be6ba53fa4
35 changed files with 539 additions and 448 deletions
|
|
@ -34,20 +34,9 @@
|
|||
#include "fe-windows.h"
|
||||
#include "printtext.h"
|
||||
|
||||
static void sig_server_add_create(IRC_SERVER_SETUP_REC **rec,
|
||||
GHashTable *optlist)
|
||||
{
|
||||
char *ircnet;
|
||||
|
||||
ircnet = g_hash_table_lookup(optlist, "ircnet");
|
||||
if (ircnet == NULL)
|
||||
return;
|
||||
|
||||
*rec = g_new0(IRC_SERVER_SETUP_REC, 1);
|
||||
(*rec)->chat_type = chat_protocol_lookup("IRC");
|
||||
signal_stop();
|
||||
}
|
||||
|
||||
/* SYNTAX: SERVER ADD [-auto | -noauto] [-ircnet <ircnet>] [-host <hostname>]
|
||||
[-cmdspeed <ms>] [-cmdmax <count>] [-port <port>]
|
||||
<address> [<port> [<password>]] */
|
||||
static void sig_server_add_fill(IRC_SERVER_SETUP_REC *rec,
|
||||
GHashTable *optlist)
|
||||
{
|
||||
|
|
@ -107,7 +96,6 @@ static void cmd_server_list(const char *data)
|
|||
|
||||
void fe_irc_server_init(void)
|
||||
{
|
||||
signal_add("server add create", (SIGNAL_FUNC) sig_server_add_create);
|
||||
signal_add("server add fill", (SIGNAL_FUNC) sig_server_add_fill);
|
||||
command_bind("server list", NULL, (SIGNAL_FUNC) cmd_server_list);
|
||||
|
||||
|
|
@ -116,7 +104,6 @@ void fe_irc_server_init(void)
|
|||
|
||||
void fe_irc_server_deinit(void)
|
||||
{
|
||||
signal_remove("server add create", (SIGNAL_FUNC) sig_server_add_create);
|
||||
signal_remove("server add fill", (SIGNAL_FUNC) sig_server_add_fill);
|
||||
command_unbind("server list", (SIGNAL_FUNC) cmd_server_list);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -79,11 +79,11 @@ static void cmd_ircnet_list(void)
|
|||
printformat(NULL, NULL, MSGLEVEL_CLIENTCRAP, IRCTXT_IRCNET_FOOTER);
|
||||
}
|
||||
|
||||
/* SYNTAX: IRCNET ADD [-kicks <count>] [-msgs <count>] [-modes <count>]
|
||||
[-whois <count>] [-cmdspeed <ms>] [-cmdmax <count>]
|
||||
[-querychans <count>] [-nick <nick>] [-user <user>]
|
||||
[-realname <name>] [-host <host>] [-autosendcmd <cmd>]
|
||||
<name> */
|
||||
/* SYNTAX: IRCNET ADD [-nick <nick>] [-user <user>] [-realname <name>]
|
||||
[-host <host>] [-autosendcmd <cmd>]
|
||||
[-querychans <count>] [-whois <count>] [-msgs <count>]
|
||||
[-kicks <count>] [-modes <count>]
|
||||
[-cmdspeed <ms>] [-cmdmax <count>] <name> */
|
||||
static void cmd_ircnet_add(const char *data)
|
||||
{
|
||||
GHashTable *optlist;
|
||||
|
|
@ -176,6 +176,7 @@ static void cmd_ircnet(const char *data, IRC_SERVER_REC *server, WI_ITEM_REC *it
|
|||
void fe_ircnet_init(void)
|
||||
{
|
||||
command_bind("ircnet", NULL, (SIGNAL_FUNC) cmd_ircnet);
|
||||
command_bind("ircnet list", NULL, (SIGNAL_FUNC) cmd_ircnet_list);
|
||||
command_bind("ircnet add", NULL, (SIGNAL_FUNC) cmd_ircnet_add);
|
||||
command_bind("ircnet remove", NULL, (SIGNAL_FUNC) cmd_ircnet_remove);
|
||||
|
||||
|
|
@ -185,6 +186,7 @@ void fe_ircnet_init(void)
|
|||
void fe_ircnet_deinit(void)
|
||||
{
|
||||
command_unbind("ircnet", (SIGNAL_FUNC) cmd_ircnet);
|
||||
command_unbind("ircnet list", (SIGNAL_FUNC) cmd_ircnet_list);
|
||||
command_unbind("ircnet add", (SIGNAL_FUNC) cmd_ircnet_add);
|
||||
command_unbind("ircnet remove", (SIGNAL_FUNC) cmd_ircnet_remove);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue