Fri, 11 Mar 2022 03:29:48 -0600
Add an echo user to the demo protocol
Testing Done:
Opened a conversation and typed a few message.
Reviewed at https://reviews.imfreedom.org/r/1328/
|
40537
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
1 | /* |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
2 | * purple |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
3 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
4 | * Purple is the legal property of its developers, whose names are too numerous |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
5 | * to list here. Please refer to the COPYRIGHT file distributed with this |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
6 | * source distribution. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
7 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
8 | * This program is free software; you can redistribute it and/or modify |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
9 | * it under the terms of the GNU General Public License as published by |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
10 | * the Free Software Foundation; either version 2 of the License, or |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
11 | * (at your option) any later version. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
12 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
13 | * This program is distributed in the hope that it will be useful, |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
16 | * GNU General Public License for more details. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
17 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
18 | * You should have received a copy of the GNU General Public License |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
19 | * along with this program; if not, see <https://www.gnu.org/licenses/>. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
20 | */ |
|
41276
03f98ece6b26
Fix a ton of missing and incorrect global header guards
Gary Kramlich <grim@reaperworld.com>
parents:
41207
diff
changeset
|
21 | |
|
03f98ece6b26
Fix a ton of missing and incorrect global header guards
Gary Kramlich <grim@reaperworld.com>
parents:
41207
diff
changeset
|
22 | #if !defined(PURPLE_GLOBAL_HEADER_INSIDE) && !defined(PURPLE_COMPILATION) |
|
03f98ece6b26
Fix a ton of missing and incorrect global header guards
Gary Kramlich <grim@reaperworld.com>
parents:
41207
diff
changeset
|
23 | # error "only <purple.h> may be included directly" |
|
03f98ece6b26
Fix a ton of missing and incorrect global header guards
Gary Kramlich <grim@reaperworld.com>
parents:
41207
diff
changeset
|
24 | #endif |
|
03f98ece6b26
Fix a ton of missing and incorrect global header guards
Gary Kramlich <grim@reaperworld.com>
parents:
41207
diff
changeset
|
25 | |
|
40537
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
26 | #ifndef PURPLE_ACCOUNT_PRESENCE_H |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
27 | #define PURPLE_ACCOUNT_PRESENCE_H |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
28 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
29 | #include "account.h" |
|
40575
b82c365e04e8
Rename presence.[ch] to purplepresence.[ch], fix some docs, and other tweaks.
Gary Kramlich <grim@reaperworld.com>
parents:
40537
diff
changeset
|
30 | #include "purplepresence.h" |
|
40537
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
31 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
32 | G_BEGIN_DECLS |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
33 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
34 | /** |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
35 | * PurpleAccountPresence: |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
36 | * |
|
41207
d91e963b0a1c
Remove unnecessary gtk-doc comments and move them where possible from libpurple/purple[a-n]*.h
Gary Kramlich <grim@reaperworld.com>
parents:
40575
diff
changeset
|
37 | * A #PurpleAccountPresence represent the #PurplePresence for a specific |
|
d91e963b0a1c
Remove unnecessary gtk-doc comments and move them where possible from libpurple/purple[a-n]*.h
Gary Kramlich <grim@reaperworld.com>
parents:
40575
diff
changeset
|
38 | * #PurpleAccount. |
|
40537
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
39 | */ |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
40 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
41 | /** |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
42 | * PURPLE_TYPE_ACCOUNT_PRESENCE: |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
43 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
44 | * The standard _get_type macro for #PurpleAccountPresence. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
45 | */ |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
46 | #define PURPLE_TYPE_ACCOUNT_PRESENCE (purple_account_presence_get_type()) |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
47 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
48 | /** |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
49 | * purple_account_presence_get_type: |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
50 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
51 | * Returns: The #GType for the #PurpleAccountPresence object. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
52 | */ |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
53 | G_DECLARE_FINAL_TYPE(PurpleAccountPresence, purple_account_presence, PURPLE, |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
54 | ACCOUNT_PRESENCE, PurplePresence) |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
55 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
56 | /** |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
57 | * purple_account_presence_new: |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
58 | * @account: The account to associate with the presence. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
59 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
60 | * Creates a presence for an account. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
61 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
62 | * Returns: The new presence. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
63 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
64 | * Since: 3.0.0 |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
65 | */ |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
66 | PurpleAccountPresence *purple_account_presence_new(PurpleAccount *account); |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
67 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
68 | /** |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
69 | * purple_account_presence_get_account: |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
70 | * @presence: The presence. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
71 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
72 | * Returns an account presence's account. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
73 | * |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
74 | * Returns: (transfer none): The presence's account. |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
75 | */ |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
76 | PurpleAccount *purple_account_presence_get_account(PurpleAccountPresence *presence); |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
77 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
78 | G_END_DECLS |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
79 | |
|
fbf29150c28c
Move PurpleAccountPresence and PurpleBuddyPresence to their own files
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
80 | #endif /* PURPLE_ACCOUNT_PRESENCE_H */ |