diff options
Diffstat (limited to 'src/ui')
-rw-r--r-- | src/ui/accounts.c | 5 | ||||
-rw-r--r-- | src/ui/chat.c | 50 | ||||
-rw-r--r-- | src/ui/chat.h | 2 | ||||
-rw-r--r-- | src/ui/contacts.c | 7 | ||||
-rw-r--r-- | src/ui/delete_messages.c | 152 | ||||
-rw-r--r-- | src/ui/delete_messages.h | 65 | ||||
-rw-r--r-- | src/ui/invite_contact.c | 7 | ||||
-rw-r--r-- | src/ui/messenger.c | 2 | ||||
-rw-r--r-- | src/ui/new_account.c | 5 | ||||
-rw-r--r-- | src/ui/new_contact.c | 5 | ||||
-rw-r--r-- | src/ui/new_group.c | 7 | ||||
-rw-r--r-- | src/ui/new_platform.c | 7 |
12 files changed, 262 insertions, 52 deletions
diff --git a/src/ui/accounts.c b/src/ui/accounts.c index f89244f..1817180 100644 --- a/src/ui/accounts.c +++ b/src/ui/accounts.c | |||
@@ -148,11 +148,6 @@ ui_accounts_dialog_init(MESSENGER_Application *app, | |||
148 | gtk_builder_get_object(handle->builder, "accounts_dialog") | 148 | gtk_builder_get_object(handle->builder, "accounts_dialog") |
149 | ); | 149 | ); |
150 | 150 | ||
151 | gtk_window_set_title( | ||
152 | GTK_WINDOW(handle->dialog), | ||
153 | _("Accounts") | ||
154 | ); | ||
155 | |||
156 | gtk_window_set_transient_for( | 151 | gtk_window_set_transient_for( |
157 | GTK_WINDOW(handle->dialog), | 152 | GTK_WINDOW(handle->dialog), |
158 | GTK_WINDOW(app->ui.messenger.main_window) | 153 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/chat.c b/src/ui/chat.c index 72d75b0..4fe4735 100644 --- a/src/ui/chat.c +++ b/src/ui/chat.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include "../application.h" | 33 | #include "../application.h" |
34 | #include "../contact.h" | 34 | #include "../contact.h" |
35 | #include "account_entry.h" | 35 | #include "account_entry.h" |
36 | #include "delete_messages.h" | ||
36 | 37 | ||
37 | static gboolean | 38 | static gboolean |
38 | _flap_reveal_switch(gpointer user_data) | 39 | _flap_reveal_switch(gpointer user_data) |
@@ -214,13 +215,11 @@ handle_chat_selection_close_button_click(UNUSED GtkButton *button, | |||
214 | gtk_list_box_unselect_all(listbox); | 215 | gtk_list_box_unselect_all(listbox); |
215 | } | 216 | } |
216 | 217 | ||
217 | static void | 218 | void |
218 | handle_chat_selection_delete_button_click(UNUSED GtkButton *button, | 219 | _delete_messages_callback(GHashTable *bindings, |
219 | gpointer user_data) | 220 | GList *selected, |
221 | gulong delay) | ||
220 | { | 222 | { |
221 | UI_CHAT_Handle *handle = (UI_CHAT_Handle*) user_data; | ||
222 | |||
223 | GList *selected = gtk_list_box_get_selected_rows(handle->messages_listbox); | ||
224 | UI_MESSAGE_Handle *message; | 223 | UI_MESSAGE_Handle *message; |
225 | 224 | ||
226 | while (selected) | 225 | while (selected) |
@@ -230,14 +229,17 @@ handle_chat_selection_delete_button_click(UNUSED GtkButton *button, | |||
230 | if (!row) | 229 | if (!row) |
231 | goto skip_row; | 230 | goto skip_row; |
232 | 231 | ||
233 | message = g_hash_table_lookup(handle->bindings, row); | 232 | message = g_hash_table_lookup(bindings, row); |
234 | 233 | ||
235 | if ((!message) || (!(message->msg))) | 234 | if ((!message) || (!(message->msg))) |
236 | goto skip_row; | 235 | goto skip_row; |
237 | 236 | ||
238 | GNUNET_CHAT_message_delete( | 237 | GNUNET_CHAT_message_delete( |
239 | message->msg, | 238 | message->msg, |
240 | GNUNET_TIME_relative_get_zero_() | 239 | GNUNET_TIME_relative_multiply( |
240 | GNUNET_TIME_relative_get_second_(), | ||
241 | delay | ||
242 | ) | ||
241 | ); | 243 | ); |
242 | 244 | ||
243 | skip_row: | 245 | skip_row: |
@@ -246,6 +248,32 @@ handle_chat_selection_delete_button_click(UNUSED GtkButton *button, | |||
246 | } | 248 | } |
247 | 249 | ||
248 | static void | 250 | static void |
251 | handle_chat_selection_delete_button_click(UNUSED GtkButton *button, | ||
252 | gpointer user_data) | ||
253 | { | ||
254 | UI_CHAT_Handle *handle = (UI_CHAT_Handle*) user_data; | ||
255 | |||
256 | MESSENGER_Application *app = handle->app; | ||
257 | |||
258 | GList *selected = gtk_list_box_get_selected_rows(handle->messages_listbox); | ||
259 | |||
260 | if (app->settings.hide_delete_dialog) | ||
261 | _delete_messages_callback(app->ui.bindings, selected, 0); | ||
262 | else | ||
263 | { | ||
264 | ui_delete_messages_dialog_init(app, &(app->ui.delete_messages)); | ||
265 | |||
266 | ui_delete_messages_dialog_link( | ||
267 | &(app->ui.delete_messages), | ||
268 | _delete_messages_callback, | ||
269 | selected | ||
270 | ); | ||
271 | |||
272 | gtk_widget_show(GTK_WIDGET(app->ui.delete_messages.dialog)); | ||
273 | } | ||
274 | } | ||
275 | |||
276 | static void | ||
249 | handle_attach_file_button_click(GtkButton *button, | 277 | handle_attach_file_button_click(GtkButton *button, |
250 | gpointer user_data) | 278 | gpointer user_data) |
251 | { | 279 | { |
@@ -366,7 +394,7 @@ handle_send_text_key_press (GtkWidget *widget, | |||
366 | { | 394 | { |
367 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; | 395 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; |
368 | 396 | ||
369 | if ((app->ui.mobile) || | 397 | if ((app->settings.mobile_design) || |
370 | (event->state & GDK_SHIFT_MASK) || | 398 | (event->state & GDK_SHIFT_MASK) || |
371 | ((event->keyval != GDK_KEY_Return) && | 399 | ((event->keyval != GDK_KEY_Return) && |
372 | (event->keyval != GDK_KEY_KP_Enter))) | 400 | (event->keyval != GDK_KEY_KP_Enter))) |
@@ -393,7 +421,7 @@ ui_chat_new(MESSENGER_Application *app) | |||
393 | UI_CHAT_Handle *handle = g_malloc(sizeof(UI_CHAT_Handle)); | 421 | UI_CHAT_Handle *handle = g_malloc(sizeof(UI_CHAT_Handle)); |
394 | UI_MESSENGER_Handle *messenger = &(app->ui.messenger); | 422 | UI_MESSENGER_Handle *messenger = &(app->ui.messenger); |
395 | 423 | ||
396 | handle->bindings = app->ui.bindings; | 424 | handle->app = app; |
397 | 425 | ||
398 | handle->messages = NULL; | 426 | handle->messages = NULL; |
399 | handle->edge_value = 0; | 427 | handle->edge_value = 0; |
diff --git a/src/ui/chat.h b/src/ui/chat.h index b27f829..2c33789 100644 --- a/src/ui/chat.h +++ b/src/ui/chat.h | |||
@@ -38,7 +38,7 @@ typedef struct UI_FILE_LOAD_ENTRY_Handle UI_FILE_LOAD_ENTRY_Handle; | |||
38 | 38 | ||
39 | typedef struct UI_CHAT_Handle | 39 | typedef struct UI_CHAT_Handle |
40 | { | 40 | { |
41 | GHashTable *bindings; | 41 | MESSENGER_Application *app; |
42 | 42 | ||
43 | GList *messages; | 43 | GList *messages; |
44 | gdouble edge_value; | 44 | gdouble edge_value; |
diff --git a/src/ui/contacts.c b/src/ui/contacts.c index ad46773..2e3b0ec 100644 --- a/src/ui/contacts.c +++ b/src/ui/contacts.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2021 GNUnet e.V. | 3 | Copyright (C) 2021--2022 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 5 | GNUnet is free software: you can redistribute it and/or modify it |
6 | under the terms of the GNU Affero General Public License as published | 6 | under the terms of the GNU Affero General Public License as published |
@@ -188,11 +188,6 @@ ui_contacts_dialog_init(MESSENGER_Application *app, | |||
188 | gtk_builder_get_object(handle->builder, "contacts_dialog") | 188 | gtk_builder_get_object(handle->builder, "contacts_dialog") |
189 | ); | 189 | ); |
190 | 190 | ||
191 | gtk_window_set_title( | ||
192 | GTK_WINDOW(handle->dialog), | ||
193 | _("Contacts") | ||
194 | ); | ||
195 | |||
196 | gtk_window_set_transient_for( | 191 | gtk_window_set_transient_for( |
197 | GTK_WINDOW(handle->dialog), | 192 | GTK_WINDOW(handle->dialog), |
198 | GTK_WINDOW(app->ui.messenger.main_window) | 193 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/delete_messages.c b/src/ui/delete_messages.c new file mode 100644 index 0000000..df75484 --- /dev/null +++ b/src/ui/delete_messages.c | |||
@@ -0,0 +1,152 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | /* | ||
21 | * @author Tobias Frisch | ||
22 | * @file ui/delete_messages.c | ||
23 | */ | ||
24 | |||
25 | #include "delete_messages.h" | ||
26 | |||
27 | #include "../application.h" | ||
28 | |||
29 | static void | ||
30 | handle_cancel_button_click(UNUSED GtkButton *button, | ||
31 | gpointer user_data) | ||
32 | { | ||
33 | GtkDialog *dialog = GTK_DIALOG(user_data); | ||
34 | gtk_window_close(GTK_WINDOW(dialog)); | ||
35 | } | ||
36 | |||
37 | static void | ||
38 | handle_confirm_button_click(UNUSED GtkButton *button, | ||
39 | gpointer user_data) | ||
40 | { | ||
41 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; | ||
42 | |||
43 | app->settings.hide_delete_dialog = gtk_toggle_button_get_active( | ||
44 | GTK_TOGGLE_BUTTON(app->ui.delete_messages.hide_checkbox) | ||
45 | ); | ||
46 | |||
47 | GtkTreeModel *model = gtk_combo_box_get_model( | ||
48 | app->ui.delete_messages.delay_combobox | ||
49 | ); | ||
50 | |||
51 | gulong delay = 0; | ||
52 | |||
53 | GtkTreeIter iter; | ||
54 | if (gtk_combo_box_get_active_iter(app->ui.delete_messages.delay_combobox, | ||
55 | &iter)) | ||
56 | gtk_tree_model_get(model, &iter, 1, &delay, -1); | ||
57 | |||
58 | if (app->ui.delete_messages.callback) | ||
59 | app->ui.delete_messages.callback( | ||
60 | app->ui.bindings, | ||
61 | app->ui.delete_messages.selected, | ||
62 | delay | ||
63 | ); | ||
64 | |||
65 | gtk_window_close(GTK_WINDOW(app->ui.delete_messages.dialog)); | ||
66 | } | ||
67 | |||
68 | static void | ||
69 | handle_dialog_destroy(UNUSED GtkWidget *window, | ||
70 | gpointer user_data) | ||
71 | { | ||
72 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; | ||
73 | |||
74 | ui_delete_messages_dialog_cleanup(&(app->ui.delete_messages)); | ||
75 | } | ||
76 | |||
77 | void | ||
78 | ui_delete_messages_dialog_init(MESSENGER_Application *app, | ||
79 | UI_DELETE_MESSAGES_Handle *handle) | ||
80 | { | ||
81 | handle->selected = NULL; | ||
82 | handle->callback = NULL; | ||
83 | |||
84 | handle->builder = gtk_builder_new_from_resource( | ||
85 | application_get_resource_path(app, "ui/delete_messages.ui") | ||
86 | ); | ||
87 | |||
88 | handle->dialog = GTK_DIALOG( | ||
89 | gtk_builder_get_object(handle->builder, "delete_messages_dialog") | ||
90 | ); | ||
91 | |||
92 | gtk_window_set_transient_for( | ||
93 | GTK_WINDOW(handle->dialog), | ||
94 | GTK_WINDOW(app->ui.messenger.main_window) | ||
95 | ); | ||
96 | |||
97 | handle->delay_store = GTK_LIST_STORE( | ||
98 | gtk_builder_get_object(handle->builder, "delay_store") | ||
99 | ); | ||
100 | |||
101 | handle->delay_combobox = GTK_COMBO_BOX( | ||
102 | gtk_builder_get_object(handle->builder, "delay_combobox") | ||
103 | ); | ||
104 | |||
105 | handle->hide_checkbox = GTK_CHECK_BUTTON( | ||
106 | gtk_builder_get_object(handle->builder, "hide_checkbox") | ||
107 | ); | ||
108 | |||
109 | handle->cancel_button = GTK_BUTTON( | ||
110 | gtk_builder_get_object(handle->builder, "cancel_button") | ||
111 | ); | ||
112 | |||
113 | g_signal_connect( | ||
114 | handle->cancel_button, | ||
115 | "clicked", | ||
116 | G_CALLBACK(handle_cancel_button_click), | ||
117 | handle->dialog | ||
118 | ); | ||
119 | |||
120 | handle->confirm_button = GTK_BUTTON( | ||
121 | gtk_builder_get_object(handle->builder, "confirm_button") | ||
122 | ); | ||
123 | |||
124 | g_signal_connect( | ||
125 | handle->confirm_button, | ||
126 | "clicked", | ||
127 | G_CALLBACK(handle_confirm_button_click), | ||
128 | app | ||
129 | ); | ||
130 | |||
131 | g_signal_connect( | ||
132 | handle->dialog, | ||
133 | "destroy", | ||
134 | G_CALLBACK(handle_dialog_destroy), | ||
135 | app | ||
136 | ); | ||
137 | } | ||
138 | |||
139 | void | ||
140 | ui_delete_messages_dialog_link(UI_DELETE_MESSAGES_Handle *handle, | ||
141 | UI_DELETE_MESSAGES_Callback callback, | ||
142 | GList *selected) | ||
143 | { | ||
144 | handle->selected = selected; | ||
145 | handle->callback = callback; | ||
146 | } | ||
147 | |||
148 | void | ||
149 | ui_delete_messages_dialog_cleanup(UI_DELETE_MESSAGES_Handle *handle) | ||
150 | { | ||
151 | g_object_unref(handle->builder); | ||
152 | } | ||
diff --git a/src/ui/delete_messages.h b/src/ui/delete_messages.h new file mode 100644 index 0000000..9cf9949 --- /dev/null +++ b/src/ui/delete_messages.h | |||
@@ -0,0 +1,65 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | /* | ||
21 | * @author Tobias Frisch | ||
22 | * @file ui/delete_messages.h | ||
23 | */ | ||
24 | |||
25 | #ifndef UI_DELETE_MESSAGES_H_ | ||
26 | #define UI_DELETE_MESSAGES_H_ | ||
27 | |||
28 | #include "messenger.h" | ||
29 | |||
30 | typedef void | ||
31 | (*UI_DELETE_MESSAGES_Callback) (GHashTable *bindings, | ||
32 | GList *selected, | ||
33 | gulong delay); | ||
34 | |||
35 | typedef struct UI_DELETE_MESSAGES_Handle | ||
36 | { | ||
37 | GList *selected; | ||
38 | |||
39 | UI_DELETE_MESSAGES_Callback callback; | ||
40 | |||
41 | GtkBuilder *builder; | ||
42 | GtkDialog *dialog; | ||
43 | |||
44 | GtkListStore *delay_store; | ||
45 | |||
46 | GtkComboBox *delay_combobox; | ||
47 | GtkCheckButton *hide_checkbox; | ||
48 | |||
49 | GtkButton *cancel_button; | ||
50 | GtkButton *confirm_button; | ||
51 | } UI_DELETE_MESSAGES_Handle; | ||
52 | |||
53 | void | ||
54 | ui_delete_messages_dialog_init(MESSENGER_Application *app, | ||
55 | UI_DELETE_MESSAGES_Handle *handle); | ||
56 | |||
57 | void | ||
58 | ui_delete_messages_dialog_link(UI_DELETE_MESSAGES_Handle *handle, | ||
59 | UI_DELETE_MESSAGES_Callback callback, | ||
60 | GList *selected); | ||
61 | |||
62 | void | ||
63 | ui_delete_messages_dialog_cleanup(UI_DELETE_MESSAGES_Handle *handle); | ||
64 | |||
65 | #endif /* UI_DELETE_MESSAGES_H_ */ | ||
diff --git a/src/ui/invite_contact.c b/src/ui/invite_contact.c index 8e18860..3afeee0 100644 --- a/src/ui/invite_contact.c +++ b/src/ui/invite_contact.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2021 GNUnet e.V. | 3 | Copyright (C) 2021--2022 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 5 | GNUnet is free software: you can redistribute it and/or modify it |
6 | under the terms of the GNU Affero General Public License as published | 6 | under the terms of the GNU Affero General Public License as published |
@@ -180,11 +180,6 @@ ui_invite_contact_dialog_init(MESSENGER_Application *app, | |||
180 | gtk_builder_get_object(handle->builder, "invite_contact_dialog") | 180 | gtk_builder_get_object(handle->builder, "invite_contact_dialog") |
181 | ); | 181 | ); |
182 | 182 | ||
183 | gtk_window_set_title( | ||
184 | GTK_WINDOW(handle->dialog), | ||
185 | _("Invite Contact") | ||
186 | ); | ||
187 | |||
188 | gtk_window_set_transient_for( | 183 | gtk_window_set_transient_for( |
189 | GTK_WINDOW(handle->dialog), | 184 | GTK_WINDOW(handle->dialog), |
190 | GTK_WINDOW(app->ui.messenger.main_window) | 185 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/messenger.c b/src/ui/messenger.c index 058fcbf..c031b1b 100644 --- a/src/ui/messenger.c +++ b/src/ui/messenger.c | |||
@@ -308,7 +308,7 @@ ui_messenger_init(MESSENGER_Application *app, | |||
308 | G_BINDING_INVERT_BOOLEAN | 308 | G_BINDING_INVERT_BOOLEAN |
309 | ); | 309 | ); |
310 | 310 | ||
311 | if (app->ui.mobile) | 311 | if (app->settings.mobile_design) |
312 | g_object_bind_property( | 312 | g_object_bind_property( |
313 | handle->leaflet_chat, | 313 | handle->leaflet_chat, |
314 | "folded", | 314 | "folded", |
diff --git a/src/ui/new_account.c b/src/ui/new_account.c index fdc53ff..6642261 100644 --- a/src/ui/new_account.c +++ b/src/ui/new_account.c | |||
@@ -123,11 +123,6 @@ ui_new_account_dialog_init(MESSENGER_Application *app, | |||
123 | gtk_builder_get_object(handle->builder, "new_account_dialog") | 123 | gtk_builder_get_object(handle->builder, "new_account_dialog") |
124 | ); | 124 | ); |
125 | 125 | ||
126 | gtk_window_set_title( | ||
127 | GTK_WINDOW(handle->dialog), | ||
128 | _("New Account") | ||
129 | ); | ||
130 | |||
131 | gtk_window_set_transient_for( | 126 | gtk_window_set_transient_for( |
132 | GTK_WINDOW(handle->dialog), | 127 | GTK_WINDOW(handle->dialog), |
133 | GTK_WINDOW(app->ui.messenger.main_window) | 128 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/new_contact.c b/src/ui/new_contact.c index 0713aa9..8188740 100644 --- a/src/ui/new_contact.c +++ b/src/ui/new_contact.c | |||
@@ -295,11 +295,6 @@ ui_new_contact_dialog_init(MESSENGER_Application *app, | |||
295 | gtk_builder_get_object(handle->builder, "new_contact_dialog") | 295 | gtk_builder_get_object(handle->builder, "new_contact_dialog") |
296 | ); | 296 | ); |
297 | 297 | ||
298 | gtk_window_set_title( | ||
299 | GTK_WINDOW(handle->dialog), | ||
300 | _("New Contact") | ||
301 | ); | ||
302 | |||
303 | gtk_window_set_transient_for( | 298 | gtk_window_set_transient_for( |
304 | GTK_WINDOW(handle->dialog), | 299 | GTK_WINDOW(handle->dialog), |
305 | GTK_WINDOW(app->ui.messenger.main_window) | 300 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/new_group.c b/src/ui/new_group.c index dbad66b..59199dc 100644 --- a/src/ui/new_group.c +++ b/src/ui/new_group.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2021 GNUnet e.V. | 3 | Copyright (C) 2021--2022 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 5 | GNUnet is free software: you can redistribute it and/or modify it |
6 | under the terms of the GNU Affero General Public License as published | 6 | under the terms of the GNU Affero General Public License as published |
@@ -206,11 +206,6 @@ ui_new_group_dialog_init(MESSENGER_Application *app, | |||
206 | gtk_builder_get_object(handle->builder, "new_group_dialog") | 206 | gtk_builder_get_object(handle->builder, "new_group_dialog") |
207 | ); | 207 | ); |
208 | 208 | ||
209 | gtk_window_set_title( | ||
210 | GTK_WINDOW(handle->dialog), | ||
211 | _("New Group") | ||
212 | ); | ||
213 | |||
214 | gtk_window_set_transient_for( | 209 | gtk_window_set_transient_for( |
215 | GTK_WINDOW(handle->dialog), | 210 | GTK_WINDOW(handle->dialog), |
216 | GTK_WINDOW(app->ui.messenger.main_window) | 211 | GTK_WINDOW(app->ui.messenger.main_window) |
diff --git a/src/ui/new_platform.c b/src/ui/new_platform.c index 544b7c7..8611432 100644 --- a/src/ui/new_platform.c +++ b/src/ui/new_platform.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2021 GNUnet e.V. | 3 | Copyright (C) 2021--2022 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 5 | GNUnet is free software: you can redistribute it and/or modify it |
6 | under the terms of the GNU Affero General Public License as published | 6 | under the terms of the GNU Affero General Public License as published |
@@ -108,11 +108,6 @@ ui_new_platform_dialog_init(MESSENGER_Application *app, | |||
108 | gtk_builder_get_object(handle->builder, "new_platform_dialog") | 108 | gtk_builder_get_object(handle->builder, "new_platform_dialog") |
109 | ); | 109 | ); |
110 | 110 | ||
111 | gtk_window_set_title( | ||
112 | GTK_WINDOW(handle->dialog), | ||
113 | _("New Platform") | ||
114 | ); | ||
115 | |||
116 | gtk_window_set_transient_for( | 111 | gtk_window_set_transient_for( |
117 | GTK_WINDOW(handle->dialog), | 112 | GTK_WINDOW(handle->dialog), |
118 | GTK_WINDOW(app->ui.messenger.main_window) | 113 | GTK_WINDOW(app->ui.messenger.main_window) |