Mercurial > hg
annotate mcabber/src/hooks.h @ 1617:9ca672ee884f
Fix previous commit :)
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Sun, 11 Oct 2009 22:47:12 +0200 |
parents | 14690e624e9d |
children | b008ac166b91 |
rev | line source |
---|---|
113 | 1 #ifndef __HOOKS_H__ |
2 #define __HOOKS_H__ 1 | |
3 | |
4 #include <time.h> | |
1598 | 5 #include <loudmouth/loudmouth.h> |
6 #include "xmpp.h" | |
113 | 7 |
1484
7b36b91a4388
New UI message flag (O) when OTR is used
Mikael Berthe <mikael@lilotux.net>
parents:
1425
diff
changeset
|
8 // These two defines are used by hk_message_{in,out} arguments |
7b36b91a4388
New UI message flag (O) when OTR is used
Mikael Berthe <mikael@lilotux.net>
parents:
1425
diff
changeset
|
9 #define ENCRYPTED_PGP 1 |
7b36b91a4388
New UI message flag (O) when OTR is used
Mikael Berthe <mikael@lilotux.net>
parents:
1425
diff
changeset
|
10 #define ENCRYPTED_OTR 2 |
113 | 11 |
1607 | 12 #include "config.h" |
13 #ifdef MODULES_ENABLE | |
14 #include <glib.h> | |
15 | |
16 typedef struct { | |
17 const char *name; | |
18 const char *value; | |
19 } hk_arg_t; | |
20 | |
21 typedef void (*hk_handler_t) (hk_arg_t *args, gpointer userdata); | |
22 | |
23 void hk_add_handler (hk_handler_t handler, gpointer userdata); | |
24 void hk_del_handler (hk_handler_t handler, gpointer userdata); | |
25 #endif | |
26 | |
1425 | 27 void hk_mainloop(void); |
1398
f8321420ed7a
Remove useless inline's
Mikael Berthe <mikael@lilotux.net>
parents:
1352
diff
changeset
|
28 void hk_message_in(const char *bjid, const char *resname, |
1598 | 29 time_t timestamp, const char *msg, LmMessageSubType type, |
30 guint encrypted); | |
1398
f8321420ed7a
Remove useless inline's
Mikael Berthe <mikael@lilotux.net>
parents:
1352
diff
changeset
|
31 void hk_message_out(const char *bjid, const char *nickname, |
1602 | 32 time_t timestamp, const char *msg, |
33 guint encrypted, gpointer xep184); | |
1398
f8321420ed7a
Remove useless inline's
Mikael Berthe <mikael@lilotux.net>
parents:
1352
diff
changeset
|
34 void hk_statuschange(const char *bjid, const char *resname, gchar prio, |
1598 | 35 time_t timestamp, enum imstatus status, |
36 char const *status_msg); | |
1398
f8321420ed7a
Remove useless inline's
Mikael Berthe <mikael@lilotux.net>
parents:
1352
diff
changeset
|
37 void hk_mystatuschange(time_t timestamp, |
438
b44be19d6229
Handle multiple resources for the same buddy
Mikael Berthe <mikael@lilotux.net>
parents:
393
diff
changeset
|
38 enum imstatus old_status, |
b44be19d6229
Handle multiple resources for the same buddy
Mikael Berthe <mikael@lilotux.net>
parents:
393
diff
changeset
|
39 enum imstatus new_status, const char *msg); |
113 | 40 |
1352
61a54e172010
Add internal hooks support
Mikael Berthe <mikael@lilotux.net>
parents:
1058
diff
changeset
|
41 void hook_execute_internal(const char *hookname); |
61a54e172010
Add internal hooks support
Mikael Berthe <mikael@lilotux.net>
parents:
1058
diff
changeset
|
42 |
281
f562b9af2de7
Add "const" specifier in prototypes
Mikael Berthe <mikael@lilotux.net>
parents:
221
diff
changeset
|
43 void hk_ext_cmd_init(const char *command); |
1058 | 44 void hk_ext_cmd(const char *bjid, guchar type, guchar info, const char *data); |
160 | 45 |
113 | 46 #endif /* __HOOKS_H__ */ |
576 | 47 |
580 | 48 /* vim: set expandtab cindent cinoptions=>2\:2(0: For Vim users... */ |