Mon, 04 Sep 2006 03:55:12 +0000
[gaim-migrate @ 17150]
libxml2 is now required for XML parsing
| 7014 | 1 | /** |
| 2 | * @file message.h Message handlers | |
| 3 | * | |
| 4 | * gaim | |
| 5 | * | |
| 6 | * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com> | |
| 7 | * | |
| 8 | * This program is free software; you can redistribute it and/or modify | |
| 9 | * it under the terms of the GNU General Public License as published by | |
| 10 | * the Free Software Foundation; either version 2 of the License, or | |
| 11 | * (at your option) any later version. | |
| 12 | * | |
| 13 | * This program is distributed in the hope that it will be useful, | |
| 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 16 | * GNU General Public License for more details. | |
| 17 | * | |
| 18 | * You should have received a copy of the GNU General Public License | |
| 19 | * along with this program; if not, write to the Free Software | |
| 20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
| 21 | */ | |
| 22 | #ifndef _GAIM_JABBER_MESSAGE_H_ | |
| 23 | #define _GAIM_JABBER_MESSAGE_H_ | |
| 24 | ||
| 25 | #include "jabber.h" | |
| 26 | #include "xmlnode.h" | |
| 27 | ||
| 28 | typedef struct _JabberMessage { | |
| 29 | JabberStream *js; | |
| 30 | enum { | |
| 31 | JABBER_MESSAGE_NORMAL, | |
| 32 | JABBER_MESSAGE_CHAT, | |
| 33 | JABBER_MESSAGE_GROUPCHAT, | |
| 34 | JABBER_MESSAGE_HEADLINE, | |
| 35 | JABBER_MESSAGE_ERROR, | |
| 36 | JABBER_MESSAGE_GROUPCHAT_INVITE, | |
| 37 | JABBER_MESSAGE_OTHER | |
| 38 | } type; | |
| 39 | time_t sent; | |
|
9584
1a6198375303
[gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents:
8400
diff
changeset
|
40 | gboolean delayed; |
| 13484 | 41 | char *id; |
| 7014 | 42 | char *from; |
| 43 | char *to; | |
| 44 | char *subject; | |
| 45 | char *body; | |
| 46 | char *xhtml; | |
| 47 | char *password; | |
| 48 | char *error; | |
| 8400 | 49 | char *thread_id; |
| 7014 | 50 | enum { |
| 13708 | 51 | JM_TS_NONE = 0, |
| 52 | JM_TS_JEP_0022 = 0x1, | |
| 53 | JM_TS_JEP_0085 = 0x2 | |
| 54 | } typing_style; | |
| 55 | enum { | |
| 56 | JM_STATE_ACTIVE, | |
| 57 | JM_STATE_COMPOSING, | |
| 58 | JM_STATE_PAUSED, | |
| 59 | JM_STATE_INACTIVE, | |
| 60 | JM_STATE_GONE | |
| 61 | } chat_state; | |
| 7145 | 62 | GList *etc; |
| 7014 | 63 | } JabberMessage; |
| 64 | ||
| 7971 | 65 | void jabber_message_free(JabberMessage *jm); |
| 66 | ||
| 67 | void jabber_message_send(JabberMessage *jm); | |
| 7014 | 68 | |
| 69 | void jabber_message_parse(JabberStream *js, xmlnode *packet); | |
| 70 | int jabber_message_send_im(GaimConnection *gc, const char *who, const char *msg, | |
|
12216
d80739091a63
[gaim-migrate @ 14518]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
9584
diff
changeset
|
71 | GaimMessageFlags flags); |
|
d80739091a63
[gaim-migrate @ 14518]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
9584
diff
changeset
|
72 | int jabber_message_send_chat(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags); |
| 7014 | 73 | |
|
13844
835b8f7b3d1d
[gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents:
13708
diff
changeset
|
74 | unsigned int jabber_send_typing(GaimConnection *gc, const char *who, GaimTypingState state); |
| 7014 | 75 | |
| 7971 | 76 | |
| 7014 | 77 | #endif /* _GAIM_JABBER_MESSAGE_H_ */ |