Sat, 29 Oct 2022 01:14:13 -0500
Convert PidginProxyPrefs to Adwaita 1.2
Testing Done:
Set all the values via the ui and the config file and tested bad values in the port in both as well. Bad values in the ui will store whatever atoi returned, but bad values in the config file will fallback to the default.
Reviewed at https://reviews.imfreedom.org/r/1996/
|
41508
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
1 | /* |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
2 | * Pidgin - Internet Messenger |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
3 | * Copyright (C) Pidgin Developers <devel@pidgin.im> |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
4 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
5 | * Pidgin is the legal property of its developers, whose names are too numerous |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
6 | * to list here. Please refer to the COPYRIGHT file distributed with this |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
7 | * source distribution. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
8 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
9 | * This program is free software; you can redistribute it and/or modify |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
10 | * it under the terms of the GNU General Public License as published by |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
11 | * the Free Software Foundation; either version 2 of the License, or |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
12 | * (at your option) any later version. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
13 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
14 | * This program is distributed in the hope that it will be useful, |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
17 | * GNU General Public License for more details. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
18 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
19 | * You should have received a copy of the GNU General Public License |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
20 | * along with this program; if not, see <https://www.gnu.org/licenses/>. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
21 | */ |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
22 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
23 | #if !defined(PIDGIN_GLOBAL_HEADER_INSIDE) && !defined(PIDGIN_COMPILATION) |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
24 | # error "only <pidgin.h> may be included directly" |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
25 | #endif |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
26 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
27 | #ifndef PIDGIN_ADD_CHAT_DIALOG_H |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
28 | #define PIDGIN_ADD_CHAT_DIALOG_H |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
29 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
30 | #include <gtk/gtk.h> |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
31 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
32 | #include <purple.h> |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
33 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
34 | G_BEGIN_DECLS |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
35 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
36 | /** |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
37 | * PidginAddChatDialog: |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
38 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
39 | * A dialog for adding chats to your contact list. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
40 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
41 | * Since: 3.0.0 |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
42 | */ |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
43 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
44 | #define PIDGIN_TYPE_ADD_CHAT_DIALOG (pidgin_add_chat_dialog_get_type()) |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
45 | G_DECLARE_FINAL_TYPE(PidginAddChatDialog, pidgin_add_chat_dialog, PIDGIN, |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
46 | ADD_CHAT_DIALOG, GtkDialog) |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
47 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
48 | /** |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
49 | * pidgin_add_chat_dialog_new: |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
50 | * @account: (nullable): The [class@Purple.Account] to pre-select. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
51 | * @group: (nullable): The [class@Purple.Group] to pre-fill. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
52 | * @alias: (nullable): The alias to pre-fill. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
53 | * @name: (nullable): The name of the chat to pre-fill. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
54 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
55 | * Creates an add chat dialog with the pre-filled optional values. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
56 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
57 | * Returns: (transfer full): The widget. |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
58 | * |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
59 | * Since: 3.0.0 |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
60 | */ |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
61 | GtkWidget *pidgin_add_chat_dialog_new(PurpleAccount *account, PurpleGroup *group, const gchar *alias, const gchar *name); |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
62 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
63 | G_END_DECLS |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
64 | |
|
b248346ee70b
Create a new PidginAddChatDialog widget.
Gary Kramlich <grim@reaperworld.com>
parents:
diff
changeset
|
65 | #endif /* PIDGIN_ADD_CHAT_DIALOG_H */ |