comparison libpurple/protocols/jabber/chat.h @ 15374:5fe8042783c1

Rename gtk/ and libgaim/ to pidgin/ and libpurple/
author Sean Egan <seanegan@gmail.com>
date Sat, 20 Jan 2007 02:32:10 +0000
parents
children 32c366eeeb99
comparison
equal deleted inserted replaced
15373:f79e0f4df793 15374:5fe8042783c1
1 /**
2 * @file chat.h Chat stuff
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_CHAT_H_
23 #define _GAIM_JABBER_CHAT_H_
24
25 #include "internal.h"
26 #include "connection.h"
27 #include "conversation.h"
28 #include "request.h"
29 #include "roomlist.h"
30
31 #include "jabber.h"
32
33 typedef struct _JabberChatMember {
34 char *handle;
35 char *jid;
36 } JabberChatMember;
37
38
39 typedef struct _JabberChat {
40 JabberStream *js;
41 char *room;
42 char *server;
43 char *handle;
44 int id;
45 GaimConversation *conv;
46 gboolean muc;
47 gboolean xhtml;
48 GaimRequestType config_dialog_type;
49 void *config_dialog_handle;
50 GHashTable *members;
51 } JabberChat;
52
53 GList *jabber_chat_info(GaimConnection *gc);
54 GHashTable *jabber_chat_info_defaults(GaimConnection *gc, const char *chat_name);
55 char *jabber_get_chat_name(GHashTable *data);
56 void jabber_chat_join(GaimConnection *gc, GHashTable *data);
57 JabberChat *jabber_chat_find(JabberStream *js, const char *room,
58 const char *server);
59 JabberChat *jabber_chat_find_by_id(JabberStream *js, int id);
60 JabberChat *jabber_chat_find_by_conv(GaimConversation *conv);
61 void jabber_chat_destroy(JabberChat *chat);
62 void jabber_chat_free(JabberChat *chat);
63 gboolean jabber_chat_find_buddy(GaimConversation *conv, const char *name);
64 void jabber_chat_invite(GaimConnection *gc, int id, const char *message,
65 const char *name);
66 void jabber_chat_leave(GaimConnection *gc, int id);
67 char *jabber_chat_buddy_real_name(GaimConnection *gc, int id, const char *who);
68 void jabber_chat_request_room_configure(JabberChat *chat);
69 void jabber_chat_create_instant_room(JabberChat *chat);
70 void jabber_chat_register(JabberChat *chat);
71 void jabber_chat_change_topic(JabberChat *chat, const char *topic);
72 void jabber_chat_set_topic(GaimConnection *gc, int id, const char *topic);
73 void jabber_chat_change_nick(JabberChat *chat, const char *nick);
74 void jabber_chat_part(JabberChat *chat, const char *msg);
75 void jabber_chat_track_handle(JabberChat *chat, const char *handle,
76 const char *jid, const char *affiliation, const char *role);
77 void jabber_chat_remove_handle(JabberChat *chat, const char *handle);
78 gboolean jabber_chat_ban_user(JabberChat *chat, const char *who,
79 const char *why);
80 gboolean jabber_chat_affiliate_user(JabberChat *chat, const char *who,
81 const char *affiliation);
82 gboolean jabber_chat_role_user(JabberChat *chat, const char *who,
83 const char *role);
84 gboolean jabber_chat_kick_user(JabberChat *chat, const char *who,
85 const char *why);
86
87 GaimRoomlist *jabber_roomlist_get_list(GaimConnection *gc);
88 void jabber_roomlist_cancel(GaimRoomlist *list);
89
90 void jabber_chat_disco_traffic(JabberChat *chat);
91
92 char *jabber_roomlist_room_serialize(GaimRoomlistRoom *room);
93
94
95 #endif /* _GAIM_JABBER_CHAT_H_ */