pidgin/pidginaccountrow.h

Sun, 03 Nov 2024 00:05:44 -0500

author
Gary Kramlich <grim@reaperworld.com>
date
Sun, 03 Nov 2024 00:05:44 -0500
changeset 43045
308e8d0ce68c
parent 42620
72178a341eb8
child 43177
595a5f31003a
permissions
-rw-r--r--

remove purple3-url-handler.desktop.in.in

The application that did the launching was removed long ago. Also this should
be implemented by the user interfaces and they might provide separate files to
groups schemas as well.

Testing Done:
Called in the turtles.

Reviewed at https://reviews.imfreedom.org/r/3640/

42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
1 /*
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
2 * Pidgin - Internet Messenger
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
3 * Copyright (C) Pidgin Developers <devel@pidgin.im>
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
4 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
5 * Pidgin is the legal property of its developers, whose names are too numerous
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
6 * to list here. Please refer to the COPYRIGHT file distributed with this
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
7 * source distribution.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
8 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
9 * This program is free software; you can redistribute it and/or modify
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
10 * it under the terms of the GNU General Public License as published by
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
11 * the Free Software Foundation; either version 2 of the License, or
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
12 * (at your option) any later version.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
13 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
14 * This program is distributed in the hope that it will be useful,
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
17 * GNU General Public License for more details.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
18 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
19 * You should have received a copy of the GNU General Public License
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
20 * along with this program; if not, see <https://www.gnu.org/licenses/>.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
21 */
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
22
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
23 #if !defined(PIDGIN_GLOBAL_HEADER_INSIDE) && !defined(PIDGIN_COMPILATION)
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
24 # error "only <pidgin.h> may be included directly"
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
25 #endif
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
26
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
27 #ifndef PIDGIN_ACCOUNT_ROW_H
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
28 #define PIDGIN_ACCOUNT_ROW_H
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
29
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
30 #include <glib.h>
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
31
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
32 #include <purple.h>
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
33
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
34 #include <gtk/gtk.h>
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
35
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
36 #include <adwaita.h>
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
37
42465
b7d530551c1b Tag declared Pidgin types with symbol visibility
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42365
diff changeset
38 #include "pidginversion.h"
b7d530551c1b Tag declared Pidgin types with symbol visibility
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42365
diff changeset
39
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
40 G_BEGIN_DECLS
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
41
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
42 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
43 * PidginAccountRow:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
44 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
45 * A [class@Adw.ComboRow] subclass that allows the user to select an
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
46 * [class@Purple.Account].
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
47 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
48 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
49 */
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
50
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
51 #define PIDGIN_TYPE_ACCOUNT_ROW (pidgin_account_row_get_type())
42465
b7d530551c1b Tag declared Pidgin types with symbol visibility
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42365
diff changeset
52
b7d530551c1b Tag declared Pidgin types with symbol visibility
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42365
diff changeset
53 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
54 G_DECLARE_FINAL_TYPE(PidginAccountRow, pidgin_account_row, PIDGIN, ACCOUNT_ROW,
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
55 AdwComboRow)
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
56
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
57 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
58 * pidgin_account_row_new:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
59 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
60 * Creates a new instance.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
61 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
62 * Returns: (transfer full): The new instance.
42467
2b1d9d0770f2 Add Since and symbol visibility on remaining Pidgin API
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42466
diff changeset
63 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
64 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
65 */
42467
2b1d9d0770f2 Add Since and symbol visibility on remaining Pidgin API
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42466
diff changeset
66 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
67 GtkWidget *pidgin_account_row_new(void);
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
68
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
69 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
70 * pidgin_account_row_get_account:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
71 * @row: The instance.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
72 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
73 * Gets the [class@Purple.Account] that is currently selected.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
74 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
75 * Returns: (transfer none): The account if one is selected otherwise %NULL if
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
76 * the model is empty.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
77 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
78 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
79 */
42466
ca3374c1cdba Add visibility to all Pidgin symbols tagged with Since 3.0
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42465
diff changeset
80 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
81 PurpleAccount *pidgin_account_row_get_account(PidginAccountRow *row);
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
82
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
83 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
84 * pidgin_account_row_set_account:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
85 * @row: The instance.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
86 * @account: (transfer none) (nullable): The [class@Purple.Account] to select.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
87 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
88 * Sets the selected account in @row to @account. If @account is %NULL, then
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
89 * the first item if one exists will be selected.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
90 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
91 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
92 */
42466
ca3374c1cdba Add visibility to all Pidgin symbols tagged with Since 3.0
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42465
diff changeset
93 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
94 void pidgin_account_row_set_account(PidginAccountRow *row, PurpleAccount *account);
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
95
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
96 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
97 * pidgin_account_row_get_filter:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
98 * @row: The instance.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
99 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
100 * Gets the filter that is being used to choose which accounts to display in
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
101 * @row.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
102 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
103 * Returns: (transfer none) (nullable): The filter being used or %NULL.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
104 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
105 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
106 */
42466
ca3374c1cdba Add visibility to all Pidgin symbols tagged with Since 3.0
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42465
diff changeset
107 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
108 GtkFilter *pidgin_account_row_get_filter(PidginAccountRow *row);
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
109
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
110 /**
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
111 * pidgin_account_row_set_filter:
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
112 * @row: The instance.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
113 * @filter: (nullable): The new filter.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
114 *
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
115 * Sets the filter for @row to @filter. If @filter is %NULL, any existing
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
116 * filter will be removed.
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
117 *
42620
72178a341eb8 Remove minor versions from Since tags in Pidgin
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42467
diff changeset
118 * Since: 3.0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
119 */
42466
ca3374c1cdba Add visibility to all Pidgin symbols tagged with Since 3.0
Elliott Sales de Andrade <quantum.analyst@gmail.com>
parents: 42465
diff changeset
120 PIDGIN_AVAILABLE_IN_3_0
42365
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
121 void pidgin_account_row_set_filter(PidginAccountRow *row, GtkFilter *filter);
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
122
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
123 G_END_DECLS
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
124
45ce6d3f6386 Create PidginAccountRow which subclasses AdwRow
Gary Kramlich <grim@reaperworld.com>
parents:
diff changeset
125 #endif /* PIDGIN_ACCOUNT_ROW_H */

mercurial