Thu, 25 Aug 2022 20:28:29 -0500
Port the AccountChooser to GTK4
Testing Done:
Open the new im dialog and verified the account chooser worked as expected.
Reviewed at https://reviews.imfreedom.org/r/1645/
|
40526
c8cc1a4c4a02
Add support for message attachments
Gary Kramlich <grim@reaperworld.com>
parents:
40502
diff
changeset
|
1 | /* |
|
40951
c83bf354d142
Add support for the author-name-color property to PidginMessage and wire it up in PurpleMessage as well
Gary Kramlich <grim@reaperworld.com>
parents:
40526
diff
changeset
|
2 | * Pidgin - Internet Messenger |
|
c83bf354d142
Add support for the author-name-color property to PidginMessage and wire it up in PurpleMessage as well
Gary Kramlich <grim@reaperworld.com>
parents:
40526
diff
changeset
|
3 | * Copyright (C) Pidgin Developers <devel@pidgin.im> |
|
39702
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
4 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
5 | * Pidgin is the legal property of its developers, whose names are too numerous |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
6 | * to list here. Please refer to the COPYRIGHT file distributed with this |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
7 | * source distribution. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
8 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
9 | * This program is free software; you can redistribute it and/or modify |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
10 | * it under the terms of the GNU General Public License as published by |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
11 | * the Free Software Foundation; either version 2 of the License, or |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
12 | * (at your option) any later version. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
13 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
14 | * This program is distributed in the hope that it will be useful, |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
17 | * GNU General Public License for more details. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
18 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
19 | * You should have received a copy of the GNU General Public License |
|
40526
c8cc1a4c4a02
Add support for message attachments
Gary Kramlich <grim@reaperworld.com>
parents:
40502
diff
changeset
|
20 | * along with this program; if not, see <https://www.gnu.org/licenses/>. |
|
39702
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
21 | */ |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
22 | |
|
40502
875489636847
pidgin.h phase3: create pidgin.h and force its usage
Gary Kramlich <grim@reaperworld.com>
parents:
39702
diff
changeset
|
23 | #if !defined(PIDGIN_GLOBAL_HEADER_INSIDE) && !defined(PIDGIN_COMPILATION) |
|
875489636847
pidgin.h phase3: create pidgin.h and force its usage
Gary Kramlich <grim@reaperworld.com>
parents:
39702
diff
changeset
|
24 | # error "only <pidgin.h> may be included directly" |
|
875489636847
pidgin.h phase3: create pidgin.h and force its usage
Gary Kramlich <grim@reaperworld.com>
parents:
39702
diff
changeset
|
25 | #endif |
|
875489636847
pidgin.h phase3: create pidgin.h and force its usage
Gary Kramlich <grim@reaperworld.com>
parents:
39702
diff
changeset
|
26 | |
|
39702
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
27 | #ifndef PIDGIN_MESSAGE_H |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
28 | #define PIDGIN_MESSAGE_H |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
29 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
30 | #include <purple.h> |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
31 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
32 | #include <talkatu.h> |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
33 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
34 | G_BEGIN_DECLS |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
35 | |
|
41124
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
36 | /** |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
37 | * PidginMessage: |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
38 | * |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
39 | * #PidginMessage maps a #PurpleMessage to a #TalkatuMessage. |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
40 | * |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
41 | * Since: 3.0.0 |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
42 | */ |
|
95555046173e
Convert pidgin from gtk-doc to gi-docgen
Gary Kramlich <grim@reaperworld.com>
parents:
40951
diff
changeset
|
43 | |
|
39702
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
44 | #define PIDGIN_TYPE_MESSAGE (pidgin_message_get_type()) |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
45 | G_DECLARE_FINAL_TYPE(PidginMessage, pidgin_message, PIDGIN, MESSAGE, GObject) |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
46 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
47 | /** |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
48 | * pidgin_message_new: |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
49 | * @msg: The #PurpleMessage to wrap. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
50 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
51 | * Wraps @msg so that it can be used as a #TalkatuMessage. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
52 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
53 | * Returns: (transfer full): The new #PidginMessage instance. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
54 | */ |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
55 | PidginMessage *pidgin_message_new(PurpleMessage *msg); |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
56 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
57 | /** |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
58 | * pidgin_message_get_message: |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
59 | * @msg: The #PidginMessage instance. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
60 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
61 | * Gets the #PurpleMessage that @msg is wrapping. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
62 | * |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
63 | * Returns: (transfer none): The #PurpleMessage that @msg is wrapping. |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
64 | */ |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
65 | PurpleMessage *pidgin_message_get_message(PidginMessage *msg); |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
66 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
67 | G_END_DECLS |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
68 | |
|
8102041c0288
Replace gtkconv->webview with a TalkatuHistory
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
69 | #endif /* PIDGIN_MESSAGE_H */ |