mirror of
https://github.com/irssi/irssi.git
synced 2026-08-11 21:00:40 +02:00
show invites of other users when provided
This commit is contained in:
parent
c87919235a
commit
e62e55c0ab
8 changed files with 47 additions and 6 deletions
|
|
@ -336,11 +336,17 @@ static void event_kick(IRC_SERVER_REC *server, const char *data)
|
|||
|
||||
static void event_invite(IRC_SERVER_REC *server, const char *data)
|
||||
{
|
||||
char *params, *channel, *shortchan;
|
||||
char *params, *nick, *channel, *shortchan;
|
||||
|
||||
g_return_if_fail(data != NULL);
|
||||
|
||||
params = event_get_params(data, 2, NULL, &channel);
|
||||
params = event_get_params(data, 2, &nick, &channel);
|
||||
|
||||
if (server->nick_comp_func(nick, server->nick) != 0) {
|
||||
/* someone else was invited, no need to do anything */
|
||||
g_free(params);
|
||||
return;
|
||||
}
|
||||
|
||||
if (irc_channel_find(server, channel) == NULL) {
|
||||
/* check if we're supposed to autojoin this channel */
|
||||
|
|
|
|||
|
|
@ -236,6 +236,7 @@ static void server_init(IRC_SERVER_REC *server)
|
|||
irc_cap_toggle(server, CAP_MULTI_PREFIX, TRUE);
|
||||
irc_cap_toggle(server, CAP_EXTENDED_JOIN, TRUE);
|
||||
irc_cap_toggle(server, CAP_SETNAME, TRUE);
|
||||
irc_cap_toggle(server, CAP_INVITE_NOTIFY, TRUE);
|
||||
|
||||
irc_send_cmd_now(server, "CAP LS " CAP_LS_VERSION);
|
||||
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@
|
|||
#define CAP_MULTI_PREFIX "multi-prefix"
|
||||
#define CAP_EXTENDED_JOIN "extended-join"
|
||||
#define CAP_SETNAME "draft/setname"
|
||||
#define CAP_INVITE_NOTIFY "invite-notify"
|
||||
|
||||
/* returns IRC_SERVER_REC if it's IRC server, NULL if it isn't */
|
||||
#define IRC_SERVER(server) \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue