mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
Actions are now transferred correctly, own messages in main irssi are
transferred now to clients. Patch by ganesh@earth.li. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1848 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
1e87b0b59f
commit
40edf12dca
@ -88,7 +88,7 @@ void proxy_outserver(CLIENT_REC *client, const char *data, ...)
|
||||
va_end(args);
|
||||
}
|
||||
|
||||
/*void proxy_outserver_all(IRC_SERVER_REC *server, const char *data, ...)
|
||||
void proxy_outserver_all(IRC_SERVER_REC *server, const char *data, ...)
|
||||
{
|
||||
va_list args;
|
||||
GSList *tmp;
|
||||
@ -111,7 +111,7 @@ void proxy_outserver(CLIENT_REC *client, const char *data, ...)
|
||||
g_free(str);
|
||||
|
||||
va_end(args);
|
||||
}*/
|
||||
}
|
||||
|
||||
void proxy_outserver_all_except(CLIENT_REC *client, const char *data, ...)
|
||||
{
|
||||
|
@ -443,6 +443,9 @@ static void event_nick(IRC_SERVER_REC *server, const char *data,
|
||||
{
|
||||
GSList *tmp;
|
||||
|
||||
if (!IS_IRC_SERVER(server))
|
||||
return;
|
||||
|
||||
if (g_strcasecmp(orignick, server->nick) != 0)
|
||||
return;
|
||||
|
||||
@ -457,6 +460,15 @@ static void event_nick(IRC_SERVER_REC *server, const char *data,
|
||||
}
|
||||
}
|
||||
|
||||
static void sig_message_own_public(IRC_SERVER_REC *server, const char *msg,
|
||||
const char *target)
|
||||
{
|
||||
if (!IS_IRC_SERVER(server))
|
||||
return;
|
||||
|
||||
proxy_outserver_all(server, "PRIVMSG %s :%s", target, msg);
|
||||
}
|
||||
|
||||
static LISTEN_REC *find_listen(const char *ircnet, int port)
|
||||
{
|
||||
GSList *tmp;
|
||||
@ -557,6 +569,7 @@ void plugin_proxy_listen_init(void)
|
||||
signal_add("event connected", (SIGNAL_FUNC) event_connected);
|
||||
signal_add("server disconnected", (SIGNAL_FUNC) sig_server_disconnected);
|
||||
signal_add("event nick", (SIGNAL_FUNC) event_nick);
|
||||
signal_add("message own_public", (SIGNAL_FUNC) sig_message_own_public);
|
||||
signal_add("setup changed", (SIGNAL_FUNC) read_settings);
|
||||
}
|
||||
|
||||
@ -573,5 +586,6 @@ void plugin_proxy_listen_deinit(void)
|
||||
signal_remove("event connected", (SIGNAL_FUNC) event_connected);
|
||||
signal_remove("server disconnected", (SIGNAL_FUNC) sig_server_disconnected);
|
||||
signal_remove("event nick", (SIGNAL_FUNC) event_nick);
|
||||
signal_remove("message own_public", (SIGNAL_FUNC) sig_message_own_public);
|
||||
signal_remove("setup changed", (SIGNAL_FUNC) read_settings);
|
||||
}
|
||||
|
@ -44,5 +44,5 @@ void plugin_proxy_dump_data(CLIENT_REC *client);
|
||||
void proxy_outdata(CLIENT_REC *client, const char *data, ...);
|
||||
void proxy_outdata_all(IRC_SERVER_REC *server, const char *data, ...);
|
||||
void proxy_outserver(CLIENT_REC *client, const char *data, ...);
|
||||
/*void proxy_outserver_all(const char *data, ...);*/
|
||||
void proxy_outserver_all(IRC_SERVER_REC *server, const char *data, ...);
|
||||
void proxy_outserver_all_except(CLIENT_REC *client, const char *data, ...);
|
||||
|
Loading…
Reference in New Issue
Block a user