annotate libpurple/plugins/signals-test.c @ 32516:4d5e1dc93265

disapproval of revision '0d9c985d91b5de7f20f3443d7edbe22fb7ce80af'
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Tue, 06 Sep 2011 18:22:03 +0000
parents 1cdae196aac8
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
1 /*
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
2 * Signals test plugin.
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
3 *
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
4 * Copyright (C) 2003 Christian Hammond.
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
5 *
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
6 * This program is free software; you can redistribute it and/or
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
7 * modify it under the terms of the GNU General Public License as
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
8 * published by the Free Software Foundation; either version 2 of the
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
9 * License, or (at your option) any later version.
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
10 *
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
11 * This program is distributed in the hope that it will be useful, but
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
14 * General Public License for more details.
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
15 *
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
16 * You should have received a copy of the GNU General Public License
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
17 * along with this program; if not, write to the Free Software
19680
44b4e8bd759b The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 18675
diff changeset
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
44b4e8bd759b The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 18675
diff changeset
19 * 02111-1301, USA.
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
20 */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
21 #define SIGNAL_TEST_PLUGIN_ID "core-signals-test"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
22
29028
f1437342cc0e Include 'internal.h' before all other headers to make some non-gcc compilers happy.
Paul Aurich <paul@darkrain42.org>
parents: 27089
diff changeset
23 #include "internal.h"
f1437342cc0e Include 'internal.h' before all other headers to make some non-gcc compilers happy.
Paul Aurich <paul@darkrain42.org>
parents: 27089
diff changeset
24
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
25 #include <stdio.h>
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
26
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
27 #include "cipher.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
28 #include "connection.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
29 #include "conversation.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
30 #include "core.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
31 #include "debug.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
32 #include "ft.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
33 #include "signals.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
34 #include "version.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
35 #include "status.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
36 #include "sound.h"
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
37
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
38 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
39 * Account subsystem signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
40 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
41 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
42 account_connecting_cb(PurpleAccount *account, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
43 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
44 purple_debug_misc("signals test", "account-connecting (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
45 purple_account_get_username(account));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
46 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
47
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
48 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
49 account_setting_info_cb(PurpleAccount *account, const char *info, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
50 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
51 purple_debug_misc("signals test", "account-setting-info (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
52 purple_account_get_username(account), info);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
53 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
54
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
55 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
56 account_set_info_cb(PurpleAccount *account, const char *info, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
57 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
58 purple_debug_misc("signals test", "account-set-info (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
59 purple_account_get_username(account), info);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
60 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
61
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
62 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
63 account_status_changed(PurpleAccount *account, PurpleStatus *old, PurpleStatus *new,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
64 gpointer data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
65 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
66 purple_debug_misc("signals test", "account-status-changed (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
67 purple_account_get_username(account),
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
68 purple_status_get_name(old),
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
69 purple_status_get_name(new));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
70 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
71
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
72 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
73 account_alias_changed(PurpleAccount *account, const char *old, gpointer data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
74 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
75 purple_debug_misc("signals test", "account-alias-changed (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
76 purple_account_get_username(account),
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
77 old, purple_account_get_alias(account));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
78 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
79
20178
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
80 static int
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
81 account_authorization_requested_cb(PurpleAccount *account, const char *user, gpointer data)
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
82 {
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
83 purple_debug_misc("signals test", "account-authorization-requested (%s, %s)\n",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
84 purple_account_get_username(account), user);
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
85 return 0;
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
86 }
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
87
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
88 static void
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
89 account_authorization_granted_cb(PurpleAccount *account, const char *user, gpointer data)
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
90 {
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
91 purple_debug_misc("signals test", "account-authorization-granted (%s, %s)\n",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
92 purple_account_get_username(account), user);
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
93 }
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
94
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
95 static void
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
96 account_authorization_denied_cb(PurpleAccount *account, const char *user, gpointer data)
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
97 {
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
98 purple_debug_misc("signals test", "account-authorization-denied (%s, %s)\n",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
99 purple_account_get_username(account), user);
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
100 }
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
101
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
102 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
103 * Buddy Icons signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
104 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
105 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
106 buddy_icon_changed_cb(PurpleBuddy *buddy)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
107 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
108 purple_debug_misc("signals test", "buddy icon changed (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
109 purple_buddy_get_name(buddy));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
110 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
111
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
112 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
113 * Buddy List subsystem signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
114 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
115 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
116 buddy_status_changed_cb(PurpleBuddy *buddy, PurpleStatus *old_status,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
117 PurpleStatus *status, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
118 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
119 purple_debug_misc("signals test", "buddy-status-changed (%s %s to %s)\n",
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
120 purple_buddy_get_name(buddy),
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
121 purple_status_get_id(old_status),
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
122 purple_status_get_id(status));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
123 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
124
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
125 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
126 buddy_idle_changed_cb(PurpleBuddy *buddy, gboolean old_idle, gboolean idle,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
127 void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
128 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
129 purple_debug_misc("signals test", "buddy-idle-changed (%s %s)\n",
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
130 purple_buddy_get_name(buddy),
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
131 old_idle ? "unidled" : "idled");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
132 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
133
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
134 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
135 buddy_signed_on_cb(PurpleBuddy *buddy, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
136 {
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
137 purple_debug_misc("signals test", "buddy-signed-on (%s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
138 purple_buddy_get_name(buddy));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
139 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
140
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
141 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
142 buddy_signed_off_cb(PurpleBuddy *buddy, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
143 {
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
144 purple_debug_misc("signals test", "buddy-signed-off (%s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
145 purple_buddy_get_name(buddy));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
146 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
147
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
148 static void
26878
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
149 blist_node_added_cb(PurpleBlistNode *bnode, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
150 {
26878
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
151 const char *name;
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
152 if (PURPLE_BLIST_NODE_IS_GROUP(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
153 name = purple_group_get_name(PURPLE_GROUP(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
154 else if (PURPLE_BLIST_NODE_IS_CONTACT(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
155 /* Close enough */
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
156 name = purple_contact_get_alias(PURPLE_CONTACT(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
157 else if (PURPLE_BLIST_NODE_IS_BUDDY(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
158 name = purple_buddy_get_name(PURPLE_BUDDY(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
159 else
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
160 name = "(unknown)";
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
161
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
162 purple_debug_misc("signals test", "blist_node_added_cb (%s)\n",
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
163 name ? name : "(null)");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
164 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
165
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
166 static void
26878
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
167 blist_node_removed_cb(PurpleBlistNode *bnode, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
168 {
26878
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
169 const char *name;
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
170 if (PURPLE_BLIST_NODE_IS_GROUP(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
171 name = purple_group_get_name(PURPLE_GROUP(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
172 else if (PURPLE_BLIST_NODE_IS_CONTACT(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
173 /* Close enough */
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
174 name = purple_contact_get_alias(PURPLE_CONTACT(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
175 else if (PURPLE_BLIST_NODE_IS_BUDDY(bnode))
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
176 name = purple_buddy_get_name(PURPLE_BUDDY(bnode));
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
177 else
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
178 name = "(unknown)";
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
179
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
180 purple_debug_misc("signals test", "blist_node_removed_cb (%s)\n",
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
181 name ? name : "(null)");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
182 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
183
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
184 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
185 blist_node_aliased(PurpleBlistNode *node, const char *old_alias)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
186 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
187 PurpleContact *p = (PurpleContact *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
188 PurpleBuddy *b = (PurpleBuddy *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
189 PurpleChat *c = (PurpleChat *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
190 PurpleGroup *g = (PurpleGroup *)node;
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
191
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
192 if (PURPLE_BLIST_NODE_IS_CONTACT(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
193 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
194 "blist-node-aliased (Contact: %s, %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
195 purple_contact_get_alias(p), old_alias);
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
196 } else if (PURPLE_BLIST_NODE_IS_BUDDY(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
197 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
198 "blist-node-aliased (Buddy: %s, %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
199 purple_buddy_get_name(b), old_alias);
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
200 } else if (PURPLE_BLIST_NODE_IS_CHAT(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
201 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
202 "blist-node-aliased (Chat: %s, %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
203 purple_chat_get_name(c), old_alias);
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
204 } else if (PURPLE_BLIST_NODE_IS_GROUP(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
205 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
206 "blist-node-aliased (Group: %s, %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
207 purple_group_get_name(g), old_alias);
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
208 } else {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
209 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
210 "blist-node-aliased (UNKNOWN: %d, %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
211 purple_blist_node_get_type(node), old_alias);
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
212 }
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
213 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
214
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
215 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
216 blist_node_extended_menu_cb(PurpleBlistNode *node, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
217 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
218 PurpleContact *p = (PurpleContact *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
219 PurpleBuddy *b = (PurpleBuddy *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
220 PurpleChat *c = (PurpleChat *)node;
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
221 PurpleGroup *g = (PurpleGroup *)node;
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
222
24256
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
223 if (PURPLE_BLIST_NODE_IS_CONTACT(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
224 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
225 "blist-node-extended-menu (Contact: %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
226 purple_contact_get_alias(p));
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
227 } else if (PURPLE_BLIST_NODE_IS_BUDDY(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
228 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
229 "blist-node-extended-menu (Buddy: %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
230 purple_buddy_get_name(b));
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
231 } else if (PURPLE_BLIST_NODE_IS_CHAT(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
232 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
233 "blist-node-extended-menu (Chat: %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
234 purple_chat_get_name(c));
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
235 } else if (PURPLE_BLIST_NODE_IS_GROUP(node)) {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
236 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
237 "blist-node-extended-menu (Group: %s)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
238 purple_group_get_name(g));
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
239 } else {
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
240 purple_debug_misc("signals test",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
241 "blist-node-extended-menu (UNKNOWN: %d)\n",
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
242 purple_blist_node_get_type(node));
0d0088b03745 Hide the blistnode, buddy, contact, group, and chat structs
Gary Kramlich <grim@reaperworld.com>
parents: 21418
diff changeset
243 }
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
244 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
245
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
246
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
247 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
248 * Connection subsystem signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
249 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
250 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
251 signing_on_cb(PurpleConnection *gc, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
252 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
253 purple_debug_misc("signals test", "signing-on (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
254 purple_account_get_username(purple_connection_get_account(gc)));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
255 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
256
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
257 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
258 signed_on_cb(PurpleConnection *gc, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
259 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
260 purple_debug_misc("signals test", "signed-on (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
261 purple_account_get_username(purple_connection_get_account(gc)));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
262 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
263
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
264 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
265 signing_off_cb(PurpleConnection *gc, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
266 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
267 purple_debug_misc("signals test", "signing-off (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
268 purple_account_get_username(purple_connection_get_account(gc)));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
269 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
270
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
271 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
272 signed_off_cb(PurpleConnection *gc, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
273 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
274 purple_debug_misc("signals test", "signed-off (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
275 purple_account_get_username(purple_connection_get_account(gc)));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
276 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
277
21364
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
278 static void
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
279 connection_error_cb(PurpleConnection *gc,
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
280 PurpleConnectionError err,
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
281 const gchar *desc,
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
282 void *data)
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
283 {
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
284 const gchar *username =
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
285 purple_account_get_username(purple_connection_get_account(gc));
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
286 purple_debug_misc("signals test", "connection-error (%s, %u, %s)\n",
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
287 username, err, desc);
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
288 }
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
289
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
290 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
291 * Conversation subsystem signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
292 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
293 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
294 writing_im_msg_cb(PurpleAccount *account, const char *who, char **buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
295 PurpleConversation *conv, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
296 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
297 purple_debug_misc("signals test", "writing-im-msg (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
298 purple_account_get_username(account), purple_conversation_get_name(conv), *buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
299
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
300 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
301
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
302 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
303
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
304 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
305 wrote_im_msg_cb(PurpleAccount *account, const char *who, const char *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
306 PurpleConversation *conv, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
307 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
308 purple_debug_misc("signals test", "wrote-im-msg (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
309 purple_account_get_username(account), purple_conversation_get_name(conv), buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
310 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
311
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
312 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
313 sending_im_msg_cb(PurpleAccount *account, char *recipient, char **buffer, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
314 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
315 purple_debug_misc("signals test", "sending-im-msg (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
316 purple_account_get_username(account), recipient, *buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
317
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
318 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
319
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
320 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
321 sent_im_msg_cb(PurpleAccount *account, const char *recipient, const char *buffer, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
322 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
323 purple_debug_misc("signals test", "sent-im-msg (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
324 purple_account_get_username(account), recipient, buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
325 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
326
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
327 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
328 receiving_im_msg_cb(PurpleAccount *account, char **sender, char **buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
329 PurpleConversation *conv, PurpleMessageFlags *flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
330 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
331 purple_debug_misc("signals test", "receiving-im-msg (%s, %s, %s, %s, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
332 purple_account_get_username(account), *sender, *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
333 (conv != NULL) ? purple_conversation_get_name(conv) : "(null)", *flags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
334
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
335 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
336 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
337
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
338 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
339 received_im_msg_cb(PurpleAccount *account, char *sender, char *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
340 PurpleConversation *conv, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
341 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
342 purple_debug_misc("signals test", "received-im-msg (%s, %s, %s, %s, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
343 purple_account_get_username(account), sender, buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
344 (conv != NULL) ? purple_conversation_get_name(conv) : "(null)", flags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
345 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
346
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
347 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
348 writing_chat_msg_cb(PurpleAccount *account, const char *who, char **buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
349 PurpleConversation *conv, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
350 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
351 purple_debug_misc("signals test", "writing-chat-msg (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
352 purple_conversation_get_name(conv), *buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
353
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
354 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
355 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
356
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
357 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
358 wrote_chat_msg_cb(PurpleAccount *account, const char *who, const char *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
359 PurpleConversation *conv, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
360 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
361 purple_debug_misc("signals test", "wrote-chat-msg (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
362 purple_conversation_get_name(conv), buffer);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
363 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
364
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
365 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
366 sending_chat_msg_cb(PurpleAccount *account, char **buffer, int id, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
367 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
368 purple_debug_misc("signals test", "sending-chat-msg (%s, %s, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
369 purple_account_get_username(account), *buffer, id);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
370
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
371 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
372 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
373
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
374 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
375 sent_chat_msg_cb(PurpleAccount *account, const char *buffer, int id, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
376 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
377 purple_debug_misc("signals test", "sent-chat-msg (%s, %s, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
378 purple_account_get_username(account), buffer, id);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
379 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
380
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
381 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
382 receiving_chat_msg_cb(PurpleAccount *account, char **sender, char **buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
383 PurpleConversation *chat, PurpleMessageFlags *flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
384 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
385 purple_debug_misc("signals test",
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
386 "receiving-chat-msg (%s, %s, %s, %s, %d)\n",
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
387 purple_account_get_username(account), *sender, *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
388 purple_conversation_get_name(chat), *flags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
389
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
390 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
391 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
392
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
393 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
394 received_chat_msg_cb(PurpleAccount *account, char *sender, char *buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
395 PurpleConversation *chat, PurpleMessageFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
396 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
397 purple_debug_misc("signals test",
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
398 "received-chat-msg (%s, %s, %s, %s, %d)\n",
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
399 purple_account_get_username(account), sender, buffer,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
400 purple_conversation_get_name(chat), flags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
401 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
402
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
403 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
404 conversation_created_cb(PurpleConversation *conv, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
405 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
406 purple_debug_misc("signals test", "conversation-created (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
407 purple_conversation_get_name(conv));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
408 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
409
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
410 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
411 deleting_conversation_cb(PurpleConversation *conv, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
412 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
413 purple_debug_misc("signals test", "deleting-conversation (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
414 purple_conversation_get_name(conv));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
415 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
416
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
417 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
418 buddy_typing_cb(PurpleAccount *account, const char *name, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
419 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
420 purple_debug_misc("signals test", "buddy-typing (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
421 purple_account_get_username(account), name);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
422 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
423
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
424 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
425 buddy_typing_stopped_cb(PurpleAccount *account, const char *name, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
426 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
427 purple_debug_misc("signals test", "buddy-typing-stopped (%s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
428 purple_account_get_username(account), name);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
429 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
430
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
431 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
432 chat_buddy_joining_cb(PurpleConversation *conv, const char *user,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
433 PurpleConvChatBuddyFlags flags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
434 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
435 purple_debug_misc("signals test", "chat-buddy-joining (%s, %s, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
436 purple_conversation_get_name(conv), user, flags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
437
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
438 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
439 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
440
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
441 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
442 chat_buddy_joined_cb(PurpleConversation *conv, const char *user,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
443 PurpleConvChatBuddyFlags flags, gboolean new_arrival, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
444 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
445 purple_debug_misc("signals test", "chat-buddy-joined (%s, %s, %d, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
446 purple_conversation_get_name(conv), user, flags, new_arrival);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
447 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
448
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
449 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
450 chat_buddy_flags_cb(PurpleConversation *conv, const char *user,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
451 PurpleConvChatBuddyFlags oldflags, PurpleConvChatBuddyFlags newflags, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
452 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
453 purple_debug_misc("signals test", "chat-buddy-flags (%s, %s, %d, %d)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
454 purple_conversation_get_name(conv), user, oldflags, newflags);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
455 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
456
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
457 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
458 chat_buddy_leaving_cb(PurpleConversation *conv, const char *user,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
459 const char *reason, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
460 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
461 purple_debug_misc("signals test", "chat-buddy-leaving (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
462 purple_conversation_get_name(conv), user, reason);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
463
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
464 return FALSE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
465 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
466
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
467 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
468 chat_buddy_left_cb(PurpleConversation *conv, const char *user,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
469 const char *reason, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
470 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
471 purple_debug_misc("signals test", "chat-buddy-left (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
472 purple_conversation_get_name(conv), user, reason);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
473 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
474
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
475 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
476 chat_inviting_user_cb(PurpleConversation *conv, const char *name,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
477 char **reason, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
478 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
479 purple_debug_misc("signals test", "chat-inviting-user (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
480 purple_conversation_get_name(conv), name, *reason);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
481 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
482
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
483 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
484 chat_invited_user_cb(PurpleConversation *conv, const char *name,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
485 const char *reason, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
486 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
487 purple_debug_misc("signals test", "chat-invited-user (%s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
488 purple_conversation_get_name(conv), name, reason);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
489 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
490
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
491 static gint
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
492 chat_invited_cb(PurpleAccount *account, const char *inviter,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
493 const char *room_name, const char *message,
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
494 const GHashTable *components, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
495 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
496 purple_debug_misc("signals test", "chat-invited (%s, %s, %s, %s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
497 purple_account_get_username(account), inviter,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
498 room_name, message);
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
499
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
500 return 0;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
501 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
502
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
503 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
504 chat_joined_cb(PurpleConversation *conv, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
505 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
506 purple_debug_misc("signals test", "chat-joined (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
507 purple_conversation_get_name(conv));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
508 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
509
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
510 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
511 chat_left_cb(PurpleConversation *conv, void *data)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
512 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
513 purple_debug_misc("signals test", "chat-left (%s)\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
514 purple_conversation_get_name(conv));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
515 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
516
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
517 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
518 chat_topic_changed_cb(PurpleConversation *conv, const char *who,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
519 const char *topic, void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
520 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
521 purple_debug_misc("signals test",
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
522 "chat-topic-changed (%s topic changed to: \"%s\" by %s)\n",
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
523 purple_conversation_get_name(conv), topic,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
524 (who) ? who : "unknown");
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
525 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
526 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
527 * Ciphers signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
528 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
529 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
530 cipher_added_cb(PurpleCipher *cipher, void *data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
531 purple_debug_misc("signals test", "cipher %s added\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
532 purple_cipher_get_name(cipher));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
533 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
534
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
535 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
536 cipher_removed_cb(PurpleCipher *cipher, void *data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
537 purple_debug_misc("signals test", "cipher %s removed\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
538 purple_cipher_get_name(cipher));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
539 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
540
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
541 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
542 * Core signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
543 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
544 static void
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
545 quitting_cb(void *data)
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
546 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
547 purple_debug_misc("signals test", "quitting ()\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
548 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
549
29236
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
550 static void
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
551 printhash(gpointer key, gpointer value, gpointer data)
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
552 {
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
553 char *a = (char *)key;
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
554 char *b = (char *)value;
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
555 GString *str = (GString *)data;
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
556 g_string_append_printf(str, " [%s] = [%s]\n", a, b ? b : "(null)");
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
557 }
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
558
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
559 static gboolean
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
560 uri_handler(const char *proto, const char *cmd, GHashTable *params)
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
561 {
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
562 GString *str = g_string_new("\n{\n");
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
563 g_hash_table_foreach(params, printhash, str);
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
564 g_string_append_c(str, '}');
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
565 purple_debug_misc("signals test", "uri handler (%s, %s, %s)\n", proto, cmd, str->str);
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
566 g_string_free(str, TRUE);
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
567 return FALSE;
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
568 }
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
569
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
570 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
571 * File transfer signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
572 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
573 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
574 ft_recv_accept_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
575 purple_debug_misc("signals test", "file receive accepted\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
576 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
577
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
578 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
579 ft_send_accept_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
580 purple_debug_misc("signals test", "file send accepted\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
581 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
582
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
583 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
584 ft_recv_start_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
585 purple_debug_misc("signals test", "file receive started\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
586 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
587
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
588 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
589 ft_send_start_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
590 purple_debug_misc("signals test", "file send started\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
591 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
592
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
593 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
594 ft_recv_cancel_cb(PurpleXfer *xfer, gpointer data) {
30865
1cdae196aac8 Standardize on "cancelled".
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 29236
diff changeset
595 purple_debug_misc("signals test", "file receive cancelled\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
596 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
597
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
598 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
599 ft_send_cancel_cb(PurpleXfer *xfer, gpointer data) {
30865
1cdae196aac8 Standardize on "cancelled".
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 29236
diff changeset
600 purple_debug_misc("signals test", "file send cancelled\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
601 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
602
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
603 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
604 ft_recv_complete_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
605 purple_debug_misc("signals test", "file receive completed\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
606 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
607
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
608 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
609 ft_send_complete_cb(PurpleXfer *xfer, gpointer data) {
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
610 purple_debug_misc("signals test", "file send completed\n");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
611 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
612
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
613 /**************************************************************************
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
614 * Sound signal callbacks
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
615 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
616 static int
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
617 sound_playing_event_cb(PurpleSoundEventID event, const PurpleAccount *account) {
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
618 if (account != NULL)
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
619 purple_debug_misc("signals test", "sound playing event: %d for account: %s\n",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
620 event, purple_account_get_username(account));
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
621 else
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
622 purple_debug_misc("signals test", "sound playing event: %d\n", event);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
623
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
624 return 0;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
625 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
626
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
627 /**************************************************************************
18675
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
628 * Notify signals callbacks
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
629 **************************************************************************/
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
630 static void
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
631 notify_email_cb(char *subject, char *from, char *to, char *url) {
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
632 purple_debug_misc("signals test", "notify email: subject=%s, from=%s, to=%s, url=%s\n",
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
633 subject, from, to, url);
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
634 }
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
635
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
636 static void
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
637 notify_emails_cb(char **subjects, char **froms, char **tos, char **urls, guint count) {
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
638 int i;
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
639 purple_debug_misc("signals test", "notify emails: count=%d\n", count);
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
640 for(i=0; i<count && i<5; i++) {
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
641 if(subjects[i]==NULL || froms[i]==NULL || tos[i]==NULL || urls[i]==NULL) continue;
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
642 purple_debug_misc("signals test", "notify emails[%d]: subject=%s, from=%s, to=%s, url=%s\n",
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
643 i, subjects[i], froms[i], tos[i], urls[i]);
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
644 }
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
645 }
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
646
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
647 /**************************************************************************
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
648 * Jabber signals callbacks
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
649 **************************************************************************/
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
650 static gboolean
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
651 jabber_iq_received(PurpleConnection *pc, const char *type, const char *id,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
652 const char *from, xmlnode *iq)
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
653 {
27019
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
654 purple_debug_misc("signals test", "jabber IQ (type=%s, id=%s, from=%s) %p\n",
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
655 type, id, from ? from : "(null)", iq);
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
656
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
657 /* We don't want the plugin to stop processing */
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
658 return FALSE;
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
659 }
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
660
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
661 static gboolean
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
662 jabber_message_received(PurpleConnection *pc, const char *type, const char *id,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
663 const char *from, const char *to, xmlnode *message)
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
664 {
27019
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
665 purple_debug_misc("signals test", "jabber message (type=%s, id=%s, "
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
666 "from=%s to=%s) %p\n",
27019
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
667 type ? type : "(null)", id ? id : "(null)",
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
668 from ? from : "(null)", to ? to : "(null)", message);
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
669
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
670 /* We don't want the plugin to stop processing */
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
671 return FALSE;
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
672 }
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
673
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
674 static gboolean
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
675 jabber_presence_received(PurpleConnection *pc, const char *type,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
676 const char *from, xmlnode *presence)
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
677 {
27019
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
678 purple_debug_misc("signals test", "jabber presence (type=%s, from=%s) %p\n",
74c9f4f79825 Add 'jabber' to the signals output and NULL checking so it won't crash on Windows
Paul Aurich <paul@darkrain42.org>
parents: 27018
diff changeset
679 type ? type : "(null)", from ? from : "(null)", presence);
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
680
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
681 /* We don't want the plugin to stop processing */
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
682 return FALSE;
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
683 }
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
684
27086
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
685 static gboolean
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
686 jabber_watched_iq(PurpleConnection *pc, const char *type, const char *id,
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
687 const char *from, xmlnode *child)
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
688 {
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
689 purple_debug_misc("signals test", "jabber watched IQ (type=%s, id=%s, from=%s)\n"
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
690 "child %p name=%s, namespace=%s\n",
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
691 type, id, from, child, child->name,
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
692 xmlnode_get_namespace(child));
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
693
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
694 if (g_str_equal(type, "get") || g_str_equal(type, "set")) {
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
695 /* Send the requisite reply */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
696 xmlnode *iq = xmlnode_new("iq");
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
697 xmlnode_set_attrib(iq, "to", from);
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
698 xmlnode_set_attrib(iq, "id", id);
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
699 xmlnode_set_attrib(iq, "type", "result");
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
700
27089
d148ca9e4d9a Use the modified signal in more places.
Paul Aurich <paul@darkrain42.org>
parents: 27087
diff changeset
701 purple_signal_emit(purple_connection_get_prpl(pc),
d148ca9e4d9a Use the modified signal in more places.
Paul Aurich <paul@darkrain42.org>
parents: 27087
diff changeset
702 "jabber-sending-xmlnode", pc, &iq);
d148ca9e4d9a Use the modified signal in more places.
Paul Aurich <paul@darkrain42.org>
parents: 27087
diff changeset
703 if (iq != NULL)
d148ca9e4d9a Use the modified signal in more places.
Paul Aurich <paul@darkrain42.org>
parents: 27087
diff changeset
704 xmlnode_free(iq);
27086
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
705 }
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
706
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
707 /* Cookie monster eats IQ stanzas; the prpl shouldn't keep processing */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
708 return TRUE;
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
709 }
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
710
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
711 /**************************************************************************
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
712 * Plugin stuff
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
713 **************************************************************************/
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
714 static gboolean
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
715 plugin_load(PurplePlugin *plugin)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
716 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
717 void *core_handle = purple_get_core();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
718 void *blist_handle = purple_blist_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
719 void *conn_handle = purple_connections_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
720 void *conv_handle = purple_conversations_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
721 void *accounts_handle = purple_accounts_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
722 void *ciphers_handle = purple_ciphers_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
723 void *ft_handle = purple_xfers_get_handle();
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
724 void *sound_handle = purple_sounds_get_handle();
18675
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
725 void *notify_handle = purple_notify_get_handle();
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
726 void *jabber_handle = purple_plugins_find_with_id("prpl-jabber");
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
727
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
728 /* Accounts subsystem signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
729 purple_signal_connect(accounts_handle, "account-connecting",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
730 plugin, PURPLE_CALLBACK(account_connecting_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
731 purple_signal_connect(accounts_handle, "account-setting-info",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
732 plugin, PURPLE_CALLBACK(account_setting_info_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
733 purple_signal_connect(accounts_handle, "account-set-info",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
734 plugin, PURPLE_CALLBACK(account_set_info_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
735 purple_signal_connect(accounts_handle, "account-status-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
736 plugin, PURPLE_CALLBACK(account_status_changed), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
737 purple_signal_connect(accounts_handle, "account-alias-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
738 plugin, PURPLE_CALLBACK(account_alias_changed), NULL);
20178
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
739 purple_signal_connect(accounts_handle, "account-authorization-requested",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
740 plugin, PURPLE_CALLBACK(account_authorization_requested_cb), NULL);
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
741 purple_signal_connect(accounts_handle, "account-authorization-denied",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
742 plugin, PURPLE_CALLBACK(account_authorization_denied_cb), NULL);
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
743 purple_signal_connect(accounts_handle, "account-authorization-granted",
8e3ef71c4362 Authorization signals. Modified patch from cockroach. Closes #1061.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents: 19680
diff changeset
744 plugin, PURPLE_CALLBACK(account_authorization_granted_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
745
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
746 /* Buddy List subsystem signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
747 purple_signal_connect(blist_handle, "buddy-status-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
748 plugin, PURPLE_CALLBACK(buddy_status_changed_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
749 purple_signal_connect(blist_handle, "buddy-idle-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
750 plugin, PURPLE_CALLBACK(buddy_idle_changed_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
751 purple_signal_connect(blist_handle, "buddy-signed-on",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
752 plugin, PURPLE_CALLBACK(buddy_signed_on_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
753 purple_signal_connect(blist_handle, "buddy-signed-off",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
754 plugin, PURPLE_CALLBACK(buddy_signed_off_cb), NULL);
26878
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
755 purple_signal_connect(blist_handle, "blist-node-added",
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
756 plugin, PURPLE_CALLBACK(blist_node_added_cb), NULL);
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
757 purple_signal_connect(blist_handle, "blist-node-removed",
0924698e2362 Add blist-node-(added|removed) and deprecate buddy-(added|removed). Closes #8309
Paul Aurich <paul@darkrain42.org>
parents: 24256
diff changeset
758 plugin, PURPLE_CALLBACK(blist_node_removed_cb), NULL);
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
759 purple_signal_connect(blist_handle, "buddy-icon-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
760 plugin, PURPLE_CALLBACK(buddy_icon_changed_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
761 purple_signal_connect(blist_handle, "blist-node-aliased",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
762 plugin, PURPLE_CALLBACK(blist_node_aliased), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
763 purple_signal_connect(blist_handle, "blist-node-extended-menu",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
764 plugin, PURPLE_CALLBACK(blist_node_extended_menu_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
765
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
766 /* Connection subsystem signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
767 purple_signal_connect(conn_handle, "signing-on",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
768 plugin, PURPLE_CALLBACK(signing_on_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
769 purple_signal_connect(conn_handle, "signed-on",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
770 plugin, PURPLE_CALLBACK(signed_on_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
771 purple_signal_connect(conn_handle, "signing-off",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
772 plugin, PURPLE_CALLBACK(signing_off_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
773 purple_signal_connect(conn_handle, "signed-off",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
774 plugin, PURPLE_CALLBACK(signed_off_cb), NULL);
21364
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
775 purple_signal_connect(conn_handle, "connection-error",
5a7202fa43a0 I figured a signal firing on a connection error would be useful.
Will Thompson <will.thompson@collabora.co.uk>
parents: 20178
diff changeset
776 plugin, PURPLE_CALLBACK(connection_error_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
777
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
778 /* Conversations subsystem signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
779 purple_signal_connect(conv_handle, "writing-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
780 plugin, PURPLE_CALLBACK(writing_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
781 purple_signal_connect(conv_handle, "wrote-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
782 plugin, PURPLE_CALLBACK(wrote_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
783 purple_signal_connect(conv_handle, "sending-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
784 plugin, PURPLE_CALLBACK(sending_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
785 purple_signal_connect(conv_handle, "sent-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
786 plugin, PURPLE_CALLBACK(sent_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
787 purple_signal_connect(conv_handle, "receiving-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
788 plugin, PURPLE_CALLBACK(receiving_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
789 purple_signal_connect(conv_handle, "received-im-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
790 plugin, PURPLE_CALLBACK(received_im_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
791 purple_signal_connect(conv_handle, "writing-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
792 plugin, PURPLE_CALLBACK(writing_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
793 purple_signal_connect(conv_handle, "wrote-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
794 plugin, PURPLE_CALLBACK(wrote_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
795 purple_signal_connect(conv_handle, "sending-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
796 plugin, PURPLE_CALLBACK(sending_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
797 purple_signal_connect(conv_handle, "sent-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
798 plugin, PURPLE_CALLBACK(sent_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
799 purple_signal_connect(conv_handle, "receiving-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
800 plugin, PURPLE_CALLBACK(receiving_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
801 purple_signal_connect(conv_handle, "received-chat-msg",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
802 plugin, PURPLE_CALLBACK(received_chat_msg_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
803 purple_signal_connect(conv_handle, "conversation-created",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
804 plugin, PURPLE_CALLBACK(conversation_created_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
805 purple_signal_connect(conv_handle, "deleting-conversation",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
806 plugin, PURPLE_CALLBACK(deleting_conversation_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
807 purple_signal_connect(conv_handle, "buddy-typing",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
808 plugin, PURPLE_CALLBACK(buddy_typing_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
809 purple_signal_connect(conv_handle, "buddy-typing-stopped",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
810 plugin, PURPLE_CALLBACK(buddy_typing_stopped_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
811 purple_signal_connect(conv_handle, "chat-buddy-joining",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
812 plugin, PURPLE_CALLBACK(chat_buddy_joining_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
813 purple_signal_connect(conv_handle, "chat-buddy-joined",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
814 plugin, PURPLE_CALLBACK(chat_buddy_joined_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
815 purple_signal_connect(conv_handle, "chat-buddy-flags",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
816 plugin, PURPLE_CALLBACK(chat_buddy_flags_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
817 purple_signal_connect(conv_handle, "chat-buddy-leaving",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
818 plugin, PURPLE_CALLBACK(chat_buddy_leaving_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
819 purple_signal_connect(conv_handle, "chat-buddy-left",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
820 plugin, PURPLE_CALLBACK(chat_buddy_left_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
821 purple_signal_connect(conv_handle, "chat-inviting-user",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
822 plugin, PURPLE_CALLBACK(chat_inviting_user_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
823 purple_signal_connect(conv_handle, "chat-invited-user",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
824 plugin, PURPLE_CALLBACK(chat_invited_user_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
825 purple_signal_connect(conv_handle, "chat-invited",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
826 plugin, PURPLE_CALLBACK(chat_invited_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
827 purple_signal_connect(conv_handle, "chat-joined",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
828 plugin, PURPLE_CALLBACK(chat_joined_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
829 purple_signal_connect(conv_handle, "chat-left",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
830 plugin, PURPLE_CALLBACK(chat_left_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
831 purple_signal_connect(conv_handle, "chat-topic-changed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
832 plugin, PURPLE_CALLBACK(chat_topic_changed_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
833
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
834 /* Ciphers signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
835 purple_signal_connect(ciphers_handle, "cipher-added",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
836 plugin, PURPLE_CALLBACK(cipher_added_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
837 purple_signal_connect(ciphers_handle, "cipher-removed",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
838 plugin, PURPLE_CALLBACK(cipher_removed_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
839
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
840 /* Core signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
841 purple_signal_connect(core_handle, "quitting",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
842 plugin, PURPLE_CALLBACK(quitting_cb), NULL);
29236
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
843 purple_signal_connect(core_handle, "uri-handler",
91ac03a72875 Add support for the uri-handler signal to the signals-test plugin
Stu Tomlinson <stu@nosnilmot.com>
parents: 29028
diff changeset
844 plugin, PURPLE_CALLBACK(uri_handler), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
845
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
846 /* File transfer signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
847 purple_signal_connect(ft_handle, "file-recv-accept",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
848 plugin, PURPLE_CALLBACK(ft_recv_accept_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
849 purple_signal_connect(ft_handle, "file-recv-start",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
850 plugin, PURPLE_CALLBACK(ft_recv_start_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
851 purple_signal_connect(ft_handle, "file-recv-cancel",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
852 plugin, PURPLE_CALLBACK(ft_recv_cancel_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
853 purple_signal_connect(ft_handle, "file-recv-complete",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
854 plugin, PURPLE_CALLBACK(ft_recv_complete_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
855 purple_signal_connect(ft_handle, "file-send-accept",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
856 plugin, PURPLE_CALLBACK(ft_send_accept_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
857 purple_signal_connect(ft_handle, "file-send-start",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
858 plugin, PURPLE_CALLBACK(ft_send_start_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
859 purple_signal_connect(ft_handle, "file-send-cancel",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
860 plugin, PURPLE_CALLBACK(ft_send_cancel_cb), NULL);
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
861 purple_signal_connect(ft_handle, "file-send-complete",
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
862 plugin, PURPLE_CALLBACK(ft_send_complete_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
863
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
864 /* Sound signals */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
865 purple_signal_connect(sound_handle, "playing-sound-event", plugin,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
866 PURPLE_CALLBACK(sound_playing_event_cb), NULL);
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
867
18675
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
868 /* Notify signals */
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
869 purple_signal_connect(notify_handle, "displaying-email-notification",
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
870 plugin, PURPLE_CALLBACK(notify_email_cb), NULL);
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
871 purple_signal_connect(notify_handle, "displaying-emails-notification",
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
872 plugin, PURPLE_CALLBACK(notify_emails_cb), NULL);
cb91bb07eeff Email notification signals from charkins. Fixes #1324
Sean Egan <seanegan@gmail.com>
parents: 16719
diff changeset
873
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
874 /* Jabber signals */
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
875 if (jabber_handle) {
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
876 purple_signal_connect(jabber_handle, "jabber-receiving-iq", plugin,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
877 PURPLE_CALLBACK(jabber_iq_received), NULL);
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
878 purple_signal_connect(jabber_handle, "jabber-receiving-message", plugin,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
879 PURPLE_CALLBACK(jabber_message_received), NULL);
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
880 purple_signal_connect(jabber_handle, "jabber-receiving-presence", plugin,
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
881 PURPLE_CALLBACK(jabber_presence_received), NULL);
27086
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
882
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
883 /* IQ namespace signals */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
884 purple_signal_emit(jabber_handle, "jabber-register-namespace-watcher",
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
885 "bogus_node", "super-duper-namespace");
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
886 /* The above is equivalent to doing:
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
887 int result = GPOINTER_TO_INT(purple_plugin_ipc_call(jabber_handle, "register_namespace_watcher", &ok, "bogus_node", "super-duper-namespace"));
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
888 */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
889
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
890 purple_signal_connect(jabber_handle, "jabber-watched-iq", plugin,
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
891 PURPLE_CALLBACK(jabber_watched_iq), NULL);
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
892 }
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
893
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
894 return TRUE;
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
895 }
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
896
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
897 static gboolean
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
898 plugin_unload(PurplePlugin *plugin)
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
899 {
27086
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
900 void *jabber_handle = purple_plugins_find_with_id("prpl-jabber");
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
901
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
902 purple_signals_disconnect_by_handle(plugin);
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
903
27086
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
904 if (jabber_handle) {
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
905 /* Unregister watched namespaces */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
906 purple_signal_emit(jabber_handle, "jabber-unregister-namespace-watcher",
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
907 "bogus_node", "super-duper-namespace");
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
908 /* The above is equivalent to doing:
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
909 int result = GPOINTER_TO_INT(purple_plugin_ipc_call(jabber_handle, "unregister_namespace_watcher", &ok, "bogus_node", "super-duper-namespace"));
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
910 */
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
911 }
60cb86295f08 Examples for the namespace-(un)registering of IQs and added IPC versions
Paul Aurich <paul@darkrain42.org>
parents: 27019
diff changeset
912
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
913 return TRUE;
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
914 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
915
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
916 static PurplePluginInfo info =
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
917 {
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
918 PURPLE_PLUGIN_MAGIC,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
919 PURPLE_MAJOR_VERSION,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
920 PURPLE_MINOR_VERSION,
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
921 PURPLE_PLUGIN_STANDARD, /**< type */
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
922 NULL, /**< ui_requirement */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
923 0, /**< flags */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
924 NULL, /**< dependencies */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
925 PURPLE_PRIORITY_DEFAULT, /**< priority */
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
926
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
927 SIGNAL_TEST_PLUGIN_ID, /**< id */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
928 N_("Signals Test"), /**< name */
21030
3cc856ca2338 Add a --with-extraversion option to ./configure so packagers can fine tune
Stu Tomlinson <stu@nosnilmot.com>
parents: 19680
diff changeset
929 DISPLAY_VERSION, /**< version */
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
930 /** summary */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
931 N_("Test to see that all signals are working properly."),
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
932 /** description */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
933 N_("Test to see that all signals are working properly."),
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
934 "Christian Hammond <chipx86@gnupdate.org>", /**< author */
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
935 PURPLE_WEBSITE, /**< homepage */
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
936
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
937 plugin_load, /**< load */
27018
e0f6c61ba779 Add the XMPP signals to the signals-test plugin
Paul Aurich <paul@darkrain42.org>
parents: 26878
diff changeset
938 plugin_unload, /**< unload */
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
939 NULL, /**< destroy */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
940
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
941 NULL, /**< ui_info */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
942 NULL, /**< extra_info */
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
943 NULL,
16719
d638845509fd Add padding to structs as necessary to silence compiler warnings
Stu Tomlinson <stu@nosnilmot.com>
parents: 15823
diff changeset
944 NULL,
d638845509fd Add padding to structs as necessary to silence compiler warnings
Stu Tomlinson <stu@nosnilmot.com>
parents: 15823
diff changeset
945 /* Padding */
d638845509fd Add padding to structs as necessary to silence compiler warnings
Stu Tomlinson <stu@nosnilmot.com>
parents: 15823
diff changeset
946 NULL,
d638845509fd Add padding to structs as necessary to silence compiler warnings
Stu Tomlinson <stu@nosnilmot.com>
parents: 15823
diff changeset
947 NULL,
d638845509fd Add padding to structs as necessary to silence compiler warnings
Stu Tomlinson <stu@nosnilmot.com>
parents: 15823
diff changeset
948 NULL,
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
949 NULL
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
950 };
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
951
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
952 static void
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
953 init_plugin(PurplePlugin *plugin)
15374
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
954 {
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
955 }
5fe8042783c1 Rename gtk/ and libgaim/ to pidgin/ and libpurple/
Sean Egan <seanegan@gmail.com>
parents:
diff changeset
956
15823
32c366eeeb99 sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@gmail.com>
parents: 15374
diff changeset
957 PURPLE_INIT_PLUGIN(signalstest, init_plugin, info)