Mercurial > hg
annotate mcabber/src/jabglue.h @ 35:a8ceaa3005fd
[/trunk] Changeset 51 by mikael
Work on libjabber integration. This is a big patch...
* Remove socket.[ch] server.[ch]
We have now fully switched to libjabber.
* Roster is fetched, and buddies are added to the buddylist
* Can send/receive messages using libjabber
* Presence messages are handled. I have added statuses, as there only were
online / offline statuses.
* Use halfdelay to have a non-blocking getch().
And use a timeout in jb_main().
* Use utf8_{encode,decode}
author | mikael |
---|---|
date | Mon, 04 Apr 2005 19:13:58 +0000 |
parents | 86837ff0554c |
children | 1441ba37a5c1 |
rev | line source |
---|---|
29 | 1 #ifndef __JABGLUE_H__ |
2 #define __JABGLUE_H__ 1 | |
3 | |
4 #include "../libjabber/jabber.h" | |
5 | |
6 extern jconn jc; | |
7 | |
8 enum imstatus { | |
9 offline = 0, | |
10 available, | |
11 invisible, | |
12 freeforchat, | |
13 dontdisturb, | |
14 occupied, | |
15 notavail, | |
16 away, | |
17 imstatus_size | |
18 }; | |
19 | |
20 static char imstatus2char[imstatus_size] = { | |
21 '_', 'o', 'i', 'f', 'd', 'c', 'n', 'a' | |
22 }; | |
23 | |
35 | 24 jconn jb_connect(const char *jid, unsigned int port, int ssl, const char *pass); |
29 | 25 void jb_disconnect(void); |
26 void jb_keepalive(); | |
27 void jb_main(); | |
35 | 28 void jb_send_msg(const char *, const char *); |
29 | 29 |
30 #endif /* __JABGLUE_H__ */ |