From af2e4b8cfea0e3d901d7bca306c6593b7b55de60 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Mon, 20 Jun 2022 18:50:16 +0300 Subject: [PATCH 48/48] gtk4: Fix Connection Page buttons See osdn #44884 Signed-off-by: Marko Lindqvist --- client/gui-gtk-4.0/pages.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/client/gui-gtk-4.0/pages.c b/client/gui-gtk-4.0/pages.c index 694557b965..73ea21f163 100644 --- a/client/gui-gtk-4.0/pages.c +++ b/client/gui-gtk-4.0/pages.c @@ -810,7 +810,7 @@ static gboolean check_server_scan(gpointer data) Callback function for when there's an error in the server scan. **************************************************************************/ static void server_scan_error(struct server_scan *scan, - const char *message) + const char *message) { output_window_append(ftc_client, message); log_error("%s", message); @@ -1199,7 +1199,6 @@ GtkWidget *create_network_page(void) int box_row = 0; int sbox_row = 0; int grid_col = 0; - int bbox_col = 0; box = gtk_grid_new(); gtk_orientable_set_orientation(GTK_ORIENTABLE(box), @@ -1432,24 +1431,23 @@ GtkWidget *create_network_page(void) gtk_grid_attach(GTK_GRID(sbox), bbox, 0, sbox_row++, 1, 1); button = gtk_button_new_from_icon_name("view-refresh"); - gtk_grid_attach(GTK_GRID(bbox), button, bbox_col++, 0, 1, 1); + gtk_box_append(GTK_BOX(bbox), button); g_signal_connect(button, "clicked", - G_CALLBACK(update_network_lists), NULL); + G_CALLBACK(update_network_lists), NULL); button = gtk_button_new_with_mnemonic(_("_Cancel")); - gtk_grid_attach(GTK_GRID(bbox), button, bbox_col++, 0, 1, 1); + gtk_box_append(GTK_BOX(bbox), button); g_signal_connect(button, "clicked", G_CALLBACK(main_callback), NULL); button = gtk_button_new_with_mnemonic(_("C_onnect")); - gtk_grid_attach(GTK_GRID(bbox), button, bbox_col++, 0, 1, 1); + gtk_box_append(GTK_BOX(bbox), button); g_signal_connect(button, "clicked", - G_CALLBACK(connect_callback), NULL); + G_CALLBACK(connect_callback), NULL); return box; } - /**************************************************************************** START PAGE ****************************************************************************/ -- 2.35.1