Mercurial > pidgin
diff libgaim/protocols/jabber/iq.c @ 15163:fe05223b5d04
[gaim-migrate @ 17949]
Gmail notifications patch from Chris Stafford
- The plugin will only do anything if it sees "google:mail:notify" in disco.
- I decided to give Jabber a mail notification option for this, since the
feature has traditionally meant "notify me of new mail if I happen to have
a mail account that this server will notify me of"
- I decided to show the first unread mail in a thread, rather than all unread
messages[A
- I made a google.c/google.h file to keep code for Google Talk extensions
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Sun, 10 Dec 2006 23:08:45 +0000 |
parents | 6e89bfd2b33f |
children |
line wrap: on
line diff
--- a/libgaim/protocols/jabber/iq.c Sun Dec 10 22:01:22 2006 +0000 +++ b/libgaim/protocols/jabber/iq.c Sun Dec 10 23:08:45 2006 +0000 @@ -25,6 +25,7 @@ #include "buddy.h" #include "disco.h" +#include "google.h" #include "iq.h" #include "oob.h" #include "roster.h" @@ -279,12 +280,16 @@ } } - if(xmlnode_get_child_with_namespace(packet, "si", "http://jabber.org/protocol/si")) { jabber_si_parse(js, packet); return; } + if(xmlnode_get_child_with_namespace(packet, "new-mail", "google:mail:notify")) { + jabber_gmail_poke(js, packet); + return; + } + /* If we get here, send the default error reply mandated by XMPP-CORE */ if(type && (!strcmp(type, "set") || !strcmp(type, "get"))) { JabberIq *iq = jabber_iq_new(js, JABBER_IQ_ERROR);