src/prpl.h

Sat, 24 Jul 2004 15:18:32 +0000

author
Nathan Fredrickson <nathan@silverorange.com>
date
Sat, 24 Jul 2004 15:18:32 +0000
changeset 9584
1a6198375303
parent 9473
89b30bf6670f
child 9713
bb37562302a1
permissions
-rw-r--r--

[gaim-migrate @ 10427]
" When joining a jabber conference many jabber servers
send a recap of the last 20 or so messages. If you
have sounds enabled, this will result in either 20
sounds in row, or worse if mixing is available, a
horrible mix of 20 overlapping sounds. These recap
messages can be identifed be the presence of the
"jabber:x:delay". This patch identifies delayed
messages, passes that information through flags from
the prpl to the core, and then on to the gui. Detailed
changes:

Add GAIM_MESSAGE_DELAYED to GaimMessageFlags to
indicate a delayed message.

Change gtkconv.c to not play sounds when either
GAIM_MESSAGE_DELAYED or GAIM_MESSAGE_SYSTEM are set.

Add GaimConvChatFlags, parallel to GaimConvImFlags, to
pass flags from protocols to core. Currently contains
two flags:
GAIM_CONV_CHAT_WHISPER
GAIM_CONV_CHAT_DELAYED

Change fourth arg of serv_got_chat_in() from "int
whisper" to "GaimConvChatFlags chatflags".

Change jabber prpl to set delayed flag when the
"jabber:x:delay" element is present. Change toc
protocol since it uses the whisper flag." --Nathan Fredrickson

Date: 2004-07-24 00:49
Sender: marv_sfAccepting Donations
Logged In: YES
user_id=790708

I'm not sure I like naming the flags "DELAYED". I mean
that's okay inside jabber since that's what the jabber
protocol refers to it as, but for the the GAIM_*_DELAYED
flags, I think they should be named something else.

I thought about NOSOUND, but I decided that was wrong,
because the flag should say what kind of message it is, not
what to do with it, that's up to the UI to decide.

What's up with not playing sounds on GAIM_MESSAGE_SYSTEM?
This sounds unrelated to this. Are there times when we want
to play sounds on system messages?

Date: 2004-07-24 09:13
Sender: noif
Logged In: YES
user_id=365548

I purposely did not use a name that implied what the UI
should do with the flag. The only characteristic that makes
these messages unique is that they've been stored in the
server for some period of time and are not current. I'm
open to a better flag name than "DELAYED"... I thought about
"RECAP", but that seemed less generalized than "DELAYED".

As for not playing sounds on GAIM_MESSAGE_SYSTEM, that can
be removed if it's controversial. I think I slipped that
in since the setting of the topic was still playing a sound
every time you joined a jabber conference.



I think we can change the flag name ourselves if something else is better.

committer: Luke Schierer <lschiere@pidgin.im>

4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
1 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
2 * @file prpl.h Protocol Plugin functions
5034
077678f7b048 [gaim-migrate @ 5377]
Christian Hammond <chipx86@chipx86.com>
parents: 4966
diff changeset
3 * @ingroup core
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
4 *
981
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
5 * gaim
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
6 *
8046
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 7999
diff changeset
7 * Gaim is the legal property of its developers, whose names are too numerous
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 7999
diff changeset
8 * to list here. Please refer to the COPYRIGHT file distributed with this
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 7999
diff changeset
9 * source distribution.
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
10 *
981
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
11 * This program is free software; you can redistribute it and/or modify
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
12 * it under the terms of the GNU General Public License as published by
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
13 * the Free Software Foundation; either version 2 of the License, or
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
14 * (at your option) any later version.
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
15 *
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
16 * This program is distributed in the hope that it will be useful,
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
19 * GNU General Public License for more details.
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
20 *
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
21 * You should have received a copy of the GNU General Public License
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
22 * along with this program; if not, write to the Free Software
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
24 */
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
25
2417
7751d1269b09 [gaim-migrate @ 2430]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2411
diff changeset
26 /* this file should be all that prpls need to include. therefore, by including
7751d1269b09 [gaim-migrate @ 2430]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2411
diff changeset
27 * this file, they should get glib, proxy, gaim_connection, prpl, etc. */
981
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
28
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
29 #ifndef _GAIM_PRPL_H_
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
30 #define _GAIM_PRPL_H_
2417
7751d1269b09 [gaim-migrate @ 2430]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2411
diff changeset
31
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
32 typedef struct _GaimPluginProtocolInfo GaimPluginProtocolInfo;
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
33
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
34 /**************************************************************************/
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
35 /** @name Basic Protocol Information */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
36 /**************************************************************************/
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
37 /*@{*/
3572
d07e14aa6f26 [gaim-migrate @ 3670]
Sean Egan <seanegan@pidgin.im>
parents: 3466
diff changeset
38
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
39 /** Default protocol plugin description */
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
40 #define GAIM_PRPL_DESC(x) \
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
41 "Allows gaim to use the " (x) " protocol.\n\n" \
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
42 "Now that you have loaded this protocol, use the " \
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
43 "Account Editor to add an account that uses this " \
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
44 "protocol. You can access the Account Editor from " \
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
45 "the \"Accounts\" button on the login window or " \
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
46 "in the \"Tools\" menu in the buddy list window."
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
47
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
48 /** Default protocol */
7956
21d891f33b89 [gaim-migrate @ 8631]
Nathan Walp <nwalp@pidgin.im>
parents: 7650
diff changeset
49 #define GAIM_PROTO_DEFAULT "prpl-oscar"
1878
ffbde9f31c65 [gaim-migrate @ 1888]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 1815
diff changeset
50
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
51 /*@}*/
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
52
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
53 /**
6622
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
54 * Flags applicable to outgoing/incoming IMs from prpls.
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
55 */
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
56 typedef enum
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
57 {
7118
280b3b85a28a [gaim-migrate @ 7685]
Christian Hammond <chipx86@chipx86.com>
parents: 7015
diff changeset
58 GAIM_CONV_IM_AUTO_RESP = 0x0001, /**< Auto response. */
280b3b85a28a [gaim-migrate @ 7685]
Christian Hammond <chipx86@chipx86.com>
parents: 7015
diff changeset
59 GAIM_CONV_IM_IMAGES = 0x0002 /**< Contains images. */
9584
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
60 } GaimConvImFlags;
8749
fb487e9e101a [gaim-migrate @ 9504]
Christian Hammond <chipx86@chipx86.com>
parents: 8713
diff changeset
61
9584
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
62 typedef enum
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
63 {
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
64 GAIM_CONV_CHAT_WHISPER = 0x0001, /**< Whispered message.*/
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
65 GAIM_CONV_CHAT_DELAYED = 0x0002 /**< Delayed message. */
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
66
1a6198375303 [gaim-migrate @ 10427]
Nathan Fredrickson <nathan@silverorange.com>
parents: 9473
diff changeset
67 } GaimConvChatFlags;
6622
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
68
9318
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
69 typedef enum {
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
70 GAIM_ICON_SCALE_DISPLAY = 0x01, /**< We scale the icon when we display it */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
71 GAIM_ICON_SCALE_SEND = 0x02 /**< We scale the icon before we send it to the server */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
72 } GaimIconScaleRules;
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
73
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
74
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
75 /**
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
76 * A description of a Buddy Icon specification. This tells Gaim what kind of image file
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
77 * it should give this prpl, and what kind of image file it should expect back.
9316
fcff1e6830e2 [gaim-migrate @ 10124]
Sean Egan <seanegan@pidgin.im>
parents: 9308
diff changeset
78 * Dimensions less than 1 should be ignored and the image not scaled.
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
79 */
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
80 typedef struct {
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
81 char *format; /**< This is a comma-delimited list of image formats or NULL if icons are not supported.
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
82 * The core nor the prpl will actually check to see if the data it's given matches this, it's entirely
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
83 * up to the UI to do what it wants */
9318
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
84 int min_width; /**< The minimum width of this icon */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
85 int min_height; /**< The minimum height of this icon */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
86 int max_width; /**< The maximum width of this icon */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
87 int max_height; /**< The maximum height of this icon */
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
88 GaimIconScaleRules scale_rules; /**< How to stretch this icon */
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
89 } GaimBuddyIconSpec;
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
90
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
91 /* This #define exists just to make it easier to fill out the buddy icon field in he prpl info struct for protocols that couldn't care less. */
9318
9d1c6820a588 [gaim-migrate @ 10126]
Nathan Walp <nwalp@pidgin.im>
parents: 9316
diff changeset
92 #define NO_BUDDY_ICONS {NULL, 0, 0, 0, 0, 0}
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
93
8573
3f37bd7005c8 [gaim-migrate @ 9321]
Ka-Hing Cheung <khc@pidgin.im>
parents: 8568
diff changeset
94 #include "blist.h"
3f37bd7005c8 [gaim-migrate @ 9321]
Ka-Hing Cheung <khc@pidgin.im>
parents: 8568
diff changeset
95 #include "proxy.h"
3f37bd7005c8 [gaim-migrate @ 9321]
Ka-Hing Cheung <khc@pidgin.im>
parents: 8568
diff changeset
96 #include "plugin.h"
3f37bd7005c8 [gaim-migrate @ 9321]
Ka-Hing Cheung <khc@pidgin.im>
parents: 8568
diff changeset
97
6622
277eb0b14653 [gaim-migrate @ 7146]
Robert McQueen <robot101@debian.org>
parents: 6451
diff changeset
98 /**
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
99 * Protocol options
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
100 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
101 * These should all be stuff that some plugins can do and others can't.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
102 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
103 typedef enum
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
104 {
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
105 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
106 * Use a unique name, not an alias, for chat rooms.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
107 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
108 * Jabber lets you choose what name you want for chat.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
109 * So it shouldn't be pulling the alias for when you're in chat;
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
110 * it gets annoying.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
111 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
112 OPT_PROTO_UNIQUE_CHATNAME = 0x00000004,
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
113
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
114 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
115 * Chat rooms have topics.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
116 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
117 * IRC and Jabber support this.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
118 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
119 OPT_PROTO_CHAT_TOPIC = 0x00000008,
1370
de786e8d0146 [gaim-migrate @ 1380]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 1355
diff changeset
120
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
121 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
122 * Don't require passwords for sign-in.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
123 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
124 * Zephyr doesn't require passwords, so there's no need for
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
125 * a password prompt.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
126 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
127 OPT_PROTO_NO_PASSWORD = 0x00000010,
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
128
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
129 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
130 * Notify on new mail.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
131 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
132 * MSN and Yahoo notify you when you have new mail.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
133 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
134 OPT_PROTO_MAIL_CHECK = 0x00000020,
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
135
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
136 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
137 * Buddy icon support.
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
138 *
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
139 * Oscar and Jabber have buddy icons.
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
140 *
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
141 * *We'll do this a bit more sophisticated like, now.
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
142 *
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
143 * OPT_PROTO_BUDDY_ICON = 0x00000040,
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
144 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
145
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
146 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
147 * Images in IMs.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
148 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
149 * Oscar lets you send images in direct IMs.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
150 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
151 OPT_PROTO_IM_IMAGE = 0x00000080,
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
152
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
153 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
154 * Allow passwords to be optional.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
155 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
156 * Passwords in IRC are optional, and are needed for certain
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
157 * functionality.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
158 */
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
159 OPT_PROTO_PASSWORD_OPTIONAL = 0x00000100,
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
160
5367
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
161 /**
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
162 * Allows font size to be specified in sane point size
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
163 *
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
164 * Probably just Jabber and Y!M
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
165 */
6063
8fbafa2e1846 [gaim-migrate @ 6513]
Nathan Walp <nwalp@pidgin.im>
parents: 6059
diff changeset
166 OPT_PROTO_USE_POINTSIZE = 0x00000200
5367
a2f9e6418413 [gaim-migrate @ 5743]
Ka-Hing Cheung <khc@pidgin.im>
parents: 5234
diff changeset
167
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
168 } GaimProtocolOptions;
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
169
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
170 /** Custom away message. */
4596
64e72bf4ece4 [gaim-migrate @ 4881]
Björn Voigt <bjoern@cs.tu-berlin.de>
parents: 4557
diff changeset
171 #define GAIM_AWAY_CUSTOM _("Custom")
1401
e81430ba5d7a [gaim-migrate @ 1411]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 1370
diff changeset
172
8113
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
173 /** Some structs defined in roomlist.h */
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
174 struct _GaimRoomlist;
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
175 struct _GaimRoomlistRoom;
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
176
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
177 /**
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
178 * A protocol plugin information structure.
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
179 *
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
180 * Every protocol plugin initializes this structure. It is the gateway
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
181 * between gaim and the protocol plugin.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
182 */
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
183 struct _GaimPluginProtocolInfo
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
184 {
8749
fb487e9e101a [gaim-migrate @ 9504]
Christian Hammond <chipx86@chipx86.com>
parents: 8713
diff changeset
185 unsigned int api_version; /**< API version number. */
fb487e9e101a [gaim-migrate @ 9504]
Christian Hammond <chipx86@chipx86.com>
parents: 8713
diff changeset
186
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
187 GaimProtocolOptions options; /**< Protocol options. */
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
188
5638
53e752c88ea1 [gaim-migrate @ 6047]
Christian Hammond <chipx86@chipx86.com>
parents: 5573
diff changeset
189 GList *user_splits; /* A GList of GaimAccountUserSplit */
53e752c88ea1 [gaim-migrate @ 6047]
Christian Hammond <chipx86@chipx86.com>
parents: 5573
diff changeset
190 GList *protocol_options; /* A GList of GaimAccountOption */
9308
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
191
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
192 GaimBuddyIconSpec icon_spec; /* The icon spec. */
4ea759d72d37 [gaim-migrate @ 10116]
Sean Egan <seanegan@pidgin.im>
parents: 9301
diff changeset
193
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
194 /**
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
195 * Returns the base icon name for the given buddy and account.
4687
91ad36873636 [gaim-migrate @ 4998]
Sean Egan <seanegan@pidgin.im>
parents: 4668
diff changeset
196 * If buddy is NULL, it will return the name to use for the account's icon
91ad36873636 [gaim-migrate @ 4998]
Sean Egan <seanegan@pidgin.im>
parents: 4668
diff changeset
197 */
6695
2a63688f0d6d [gaim-migrate @ 7221]
Nathan Walp <nwalp@pidgin.im>
parents: 6622
diff changeset
198 const char *(*list_icon)(GaimAccount *account, GaimBuddy *buddy);
4687
91ad36873636 [gaim-migrate @ 4998]
Sean Egan <seanegan@pidgin.im>
parents: 4668
diff changeset
199
91ad36873636 [gaim-migrate @ 4998]
Sean Egan <seanegan@pidgin.im>
parents: 4668
diff changeset
200 /**
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
201 * Fills the four char**'s with string identifiers for "emblems"
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
202 * that the UI will interpret and display as relevant
4687
91ad36873636 [gaim-migrate @ 4998]
Sean Egan <seanegan@pidgin.im>
parents: 4668
diff changeset
203 */
6695
2a63688f0d6d [gaim-migrate @ 7221]
Nathan Walp <nwalp@pidgin.im>
parents: 6622
diff changeset
204 void (*list_emblems)(GaimBuddy *buddy, char **se, char **sw,
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
205 char **nw, char **ne);
4722
f834a9a217c4 [gaim-migrate @ 5034]
Sean Egan <seanegan@pidgin.im>
parents: 4687
diff changeset
206
f834a9a217c4 [gaim-migrate @ 5034]
Sean Egan <seanegan@pidgin.im>
parents: 4687
diff changeset
207 /**
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
208 * Gets a short string representing this buddy's status. This will
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
209 * be shown on the buddy list.
4722
f834a9a217c4 [gaim-migrate @ 5034]
Sean Egan <seanegan@pidgin.im>
parents: 4687
diff changeset
210 */
6695
2a63688f0d6d [gaim-migrate @ 7221]
Nathan Walp <nwalp@pidgin.im>
parents: 6622
diff changeset
211 char *(*status_text)(GaimBuddy *buddy);
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
212
4724
2c7fae3847c8 [gaim-migrate @ 5037]
Sean Egan <seanegan@pidgin.im>
parents: 4722
diff changeset
213 /**
2c7fae3847c8 [gaim-migrate @ 5037]
Sean Egan <seanegan@pidgin.im>
parents: 4722
diff changeset
214 * Gets a string to put in the buddy list tooltip.
2c7fae3847c8 [gaim-migrate @ 5037]
Sean Egan <seanegan@pidgin.im>
parents: 4722
diff changeset
215 */
6695
2a63688f0d6d [gaim-migrate @ 7221]
Nathan Walp <nwalp@pidgin.im>
parents: 6622
diff changeset
216 char *(*tooltip_text)(GaimBuddy *buddy);
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
217
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
218 GList *(*away_states)(GaimConnection *gc);
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
219
9030
7b574a641391 [gaim-migrate @ 9806]
Mark Doliner <markdoliner@pidgin.im>
parents: 9015
diff changeset
220 GList *(*blist_node_menu)(GaimBlistNode *node);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
221 GList *(*chat_info)(GaimConnection *);
1333
bbd54f86976f [gaim-migrate @ 1343]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 1318
diff changeset
222
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
223 /* All the server-related functions */
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
224 void (*login)(GaimAccount *);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
225 void (*close)(GaimConnection *);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
226 int (*send_im)(GaimConnection *, const char *who,
6982
12f08de92674 [gaim-migrate @ 7538]
Mark Doliner <markdoliner@pidgin.im>
parents: 6885
diff changeset
227 const char *message,
7118
280b3b85a28a [gaim-migrate @ 7685]
Christian Hammond <chipx86@chipx86.com>
parents: 7015
diff changeset
228 GaimConvImFlags flags);
5954
58e43cf2dc1f [gaim-migrate @ 6398]
Mark Doliner <markdoliner@pidgin.im>
parents: 5946
diff changeset
229 void (*set_info)(GaimConnection *, const char *info);
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
230 int (*send_typing)(GaimConnection *, const char *name, int typing);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
231 void (*get_info)(GaimConnection *, const char *who);
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
232 void (*set_away)(GaimConnection *, const char *state, const char *message);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
233 void (*set_idle)(GaimConnection *, int idletime);
5946
ebabcd2b4637 [gaim-migrate @ 6387]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
234 void (*change_passwd)(GaimConnection *, const char *old_pass,
ebabcd2b4637 [gaim-migrate @ 6387]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
235 const char *new_pass);
9285
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
236 void (*add_buddy)(GaimConnection *, GaimBuddy *buddy, GaimGroup *group);
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
237 void (*add_buddies)(GaimConnection *, GList *buddies, GList *groups);
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
238 void (*remove_buddy)(GaimConnection *, GaimBuddy *buddy, GaimGroup *group);
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
239 void (*remove_buddies)(GaimConnection *, GList *buddies, GList *groups);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
240 void (*add_permit)(GaimConnection *, const char *name);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
241 void (*add_deny)(GaimConnection *, const char *name);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
242 void (*rem_permit)(GaimConnection *, const char *name);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
243 void (*rem_deny)(GaimConnection *, const char *name);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
244 void (*set_permit_deny)(GaimConnection *);
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
245 void (*warn)(GaimConnection *, const char *who, int anonymous);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
246 void (*join_chat)(GaimConnection *, GHashTable *components);
8562
7e73676d1772 [gaim-migrate @ 9306]
Christopher O'Brien <siege@pidgin.im>
parents: 8170
diff changeset
247 void (*reject_chat)(GaimConnection *, GHashTable *components);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
248 void (*chat_invite)(GaimConnection *, int id,
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
249 const char *who, const char *message);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
250 void (*chat_leave)(GaimConnection *, int id);
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
251 void (*chat_whisper)(GaimConnection *, int id,
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
252 const char *who, const char *message);
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
253 int (*chat_send)(GaimConnection *, int id, const char *message);
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
254 void (*keepalive)(GaimConnection *);
1713
3e0138242a5b [gaim-migrate @ 1723]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 1626
diff changeset
255
2827
e3d10df95e74 [gaim-migrate @ 2840]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2773
diff changeset
256 /* new user registration */
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
257 void (*register_user)(GaimAccount *);
2956
1836bfe768df [gaim-migrate @ 2969]
Rob Flynn <gaim@robflynn.com>
parents: 2827
diff changeset
258
1836bfe768df [gaim-migrate @ 2969]
Rob Flynn <gaim@robflynn.com>
parents: 2827
diff changeset
259 /* get "chat buddy" info and away message */
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
260 void (*get_cb_info)(GaimConnection *, int, const char *who);
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
261 void (*get_cb_away)(GaimConnection *, int, const char *who);
2827
e3d10df95e74 [gaim-migrate @ 2840]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2773
diff changeset
262
3136
8d988a6d2f4c [gaim-migrate @ 3151]
Rob Flynn <gaim@robflynn.com>
parents: 3044
diff changeset
263 /* save/store buddy's alias on server list/roster */
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
264 void (*alias_buddy)(GaimConnection *, const char *who,
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
265 const char *alias);
3136
8d988a6d2f4c [gaim-migrate @ 3151]
Rob Flynn <gaim@robflynn.com>
parents: 3044
diff changeset
266
8d988a6d2f4c [gaim-migrate @ 3151]
Rob Flynn <gaim@robflynn.com>
parents: 3044
diff changeset
267 /* change a buddy's group on a server list/roster */
5563
d5a7852aa0cb [gaim-migrate @ 5965]
Christian Hammond <chipx86@chipx86.com>
parents: 5538
diff changeset
268 void (*group_buddy)(GaimConnection *, const char *who,
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
269 const char *old_group, const char *new_group);
3136
8d988a6d2f4c [gaim-migrate @ 3151]
Rob Flynn <gaim@robflynn.com>
parents: 3044
diff changeset
270
3348
57ed471963ba [gaim-migrate @ 3367]
Mark Doliner <markdoliner@pidgin.im>
parents: 3313
diff changeset
271 /* rename a group on a server list/roster */
9285
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
272 void (*rename_group)(GaimConnection *, const char *old_name,
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
273 GaimGroup *group, GList *moved_buddies);
3348
57ed471963ba [gaim-migrate @ 3367]
Mark Doliner <markdoliner@pidgin.im>
parents: 3313
diff changeset
274
6695
2a63688f0d6d [gaim-migrate @ 7221]
Nathan Walp <nwalp@pidgin.im>
parents: 6622
diff changeset
275 void (*buddy_free)(GaimBuddy *);
2607
7bcd3ea48df3 [gaim-migrate @ 2620]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2582
diff changeset
276
6059
9934c862ca14 [gaim-migrate @ 6509]
John Silvestri <john.silvestri@gmail.com>
parents: 5954
diff changeset
277 void (*convo_closed)(GaimConnection *, const char *who);
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
278
7322
de15a9314c04 [gaim-migrate @ 7908]
Nathan Walp <nwalp@pidgin.im>
parents: 7262
diff changeset
279 const char *(*normalize)(const GaimAccount *, const char *);
6451
2ff17ce330d8 [gaim-migrate @ 6960]
Christian Hammond <chipx86@chipx86.com>
parents: 6418
diff changeset
280
5842
8c35097a15b5 [gaim-migrate @ 6273]
Sean Egan <seanegan@pidgin.im>
parents: 5730
diff changeset
281 void (*set_buddy_icon)(GaimConnection *, const char *filename);
6885
65132ebfc662 [gaim-migrate @ 7431]
Christian Hammond <chipx86@chipx86.com>
parents: 6846
diff changeset
282
9285
9cedf5d26577 [gaim-migrate @ 10088]
Mark Doliner <markdoliner@pidgin.im>
parents: 9058
diff changeset
283 void (*remove_group)(GaimConnection *gc, GaimGroup *group);
7398
90663d97aa6a [gaim-migrate @ 7994]
Nathan Walp <nwalp@pidgin.im>
parents: 7322
diff changeset
284
90663d97aa6a [gaim-migrate @ 7994]
Nathan Walp <nwalp@pidgin.im>
parents: 7322
diff changeset
285 char *(*get_cb_real_name)(GaimConnection *gc, int id, const char *who);
7971
a9309feca3c8 [gaim-migrate @ 8648]
Nathan Walp <nwalp@pidgin.im>
parents: 7956
diff changeset
286
a9309feca3c8 [gaim-migrate @ 8648]
Nathan Walp <nwalp@pidgin.im>
parents: 7956
diff changeset
287 void (*set_chat_topic)(GaimConnection *gc, int id, const char *topic);
7999
f3f95e0c956a [gaim-migrate @ 8676]
Nathan Walp <nwalp@pidgin.im>
parents: 7971
diff changeset
288
f3f95e0c956a [gaim-migrate @ 8676]
Nathan Walp <nwalp@pidgin.im>
parents: 7971
diff changeset
289 GaimChat *(*find_blist_chat)(GaimAccount *account, const char *name);
8113
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
290
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
291 /* room listing prpl callbacks */
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
292 struct _GaimRoomlist *(*roomlist_get_list)(GaimConnection *gc);
6a2ffc66c022 [gaim-migrate @ 8817]
Tim Ringenbach <marv@pidgin.im>
parents: 8046
diff changeset
293 void (*roomlist_cancel)(struct _GaimRoomlist *list);
8584
871f67e4aa3c [gaim-migrate @ 9334]
Daniel Atallah <datallah@pidgin.im>
parents: 8573
diff changeset
294 void (*roomlist_expand_category)(struct _GaimRoomlist *list, struct _GaimRoomlistRoom *category);
9466
b6425eab60ca [gaim-migrate @ 10291]
Daniel Atallah <datallah@pidgin.im>
parents: 9460
diff changeset
295
b6425eab60ca [gaim-migrate @ 10291]
Daniel Atallah <datallah@pidgin.im>
parents: 9460
diff changeset
296 /* file transfer callbacks */
b6425eab60ca [gaim-migrate @ 10291]
Daniel Atallah <datallah@pidgin.im>
parents: 9460
diff changeset
297 gboolean (*can_receive_file)(GaimConnection *, const char *who);
b6425eab60ca [gaim-migrate @ 10291]
Daniel Atallah <datallah@pidgin.im>
parents: 9460
diff changeset
298 void (*send_file)(GaimConnection *, const char *who, const char *filename);
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
299 };
2246
8ade8b7421af [gaim-migrate @ 2256]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2232
diff changeset
300
5205
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
301 #define GAIM_IS_PROTOCOL_PLUGIN(plugin) \
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
302 ((plugin)->info->type == GAIM_PLUGIN_PROTOCOL)
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
303
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
304 #define GAIM_PLUGIN_PROTOCOL_INFO(plugin) \
242b8aa81328 [gaim-migrate @ 5573]
Christian Hammond <chipx86@chipx86.com>
parents: 5148
diff changeset
305 ((GaimPluginProtocolInfo *)(plugin)->info->extra_info)
981
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
306
9030
7b574a641391 [gaim-migrate @ 9806]
Mark Doliner <markdoliner@pidgin.im>
parents: 9015
diff changeset
307 /* It's not like we're going to run out of integers for this version
7b574a641391 [gaim-migrate @ 9806]
Mark Doliner <markdoliner@pidgin.im>
parents: 9015
diff changeset
308 number, but we only want to really change it once per release. */
9473
89b30bf6670f [gaim-migrate @ 10298]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 9466
diff changeset
309 /* GAIM_PRPL_API_VERSION last changed for version: 0.80 */
89b30bf6670f [gaim-migrate @ 10298]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 9466
diff changeset
310 #define GAIM_PRPL_API_VERSION 6
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
311
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
312 #ifdef __cplusplus
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
313 extern "C" {
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
314 #endif
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
315
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
316 /**
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
317 * Finds a protocol plugin structure of the specified type.
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
318 *
9000
ff260ac20c29 [gaim-migrate @ 9775]
Gary Kramlich <grim@pidgin.im>
parents: 8951
diff changeset
319 * @param id The protocol plugin;
4557
40c90b1671cf [gaim-migrate @ 4837]
Christian Hammond <chipx86@chipx86.com>
parents: 4514
diff changeset
320 */
7956
21d891f33b89 [gaim-migrate @ 8631]
Nathan Walp <nwalp@pidgin.im>
parents: 7650
diff changeset
321 GaimPlugin *gaim_find_prpl(const char *id);
981
00723c9a507c [gaim-migrate @ 991]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents:
diff changeset
322
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
323 #ifdef __cplusplus
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
324 }
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
325 #endif
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5943
diff changeset
326
2417
7751d1269b09 [gaim-migrate @ 2430]
Eric Warmenhoven <warmenhoven@yahoo.com>
parents: 2411
diff changeset
327 #endif /* _PRPL_H_ */

mercurial