# HG changeset patch # User Gary Kramlich # Date 1660549149 18000 # Node ID ac5416e7e4f5a7435118f06ca3221f4f8b62517e # Parent 2579a5138f0c4fd6f40cb3212e2d0fe1c865cc3b Port PidginAddBuddyDialog to GTK4 Testing Done: Compiled Reviewed at https://reviews.imfreedom.org/r/1586/ diff -r 2579a5138f0c -r ac5416e7e4f5 pidgin/pidginaddbuddydialog.c --- a/pidgin/pidginaddbuddydialog.c Fri Aug 12 03:44:34 2022 -0500 +++ b/pidgin/pidginaddbuddydialog.c Mon Aug 15 02:39:09 2022 -0500 @@ -85,7 +85,7 @@ protocol = purple_account_get_protocol(account); if(PURPLE_IS_PROTOCOL(protocol)) { - const gchar *username = gtk_entry_get_text(GTK_ENTRY(dialog->username)); + const gchar *username = gtk_editable_get_text(GTK_EDITABLE(dialog->username)); valid = purple_validate(protocol, username); } @@ -115,9 +115,9 @@ /* Grab all of the values that the user entered. */ account = pidgin_account_chooser_get_selected(PIDGIN_ACCOUNT_CHOOSER(abdialog->account)); - username = gtk_entry_get_text(GTK_ENTRY(abdialog->username)); - alias = gtk_entry_get_text(GTK_ENTRY(abdialog->alias)); - message = gtk_entry_get_text(GTK_ENTRY(abdialog->message)); + username = gtk_editable_get_text(GTK_EDITABLE(abdialog->username)); + alias = gtk_editable_get_text(GTK_EDITABLE(abdialog->alias)); + message = gtk_editable_get_text(GTK_EDITABLE(abdialog->message)); groupname = gtk_combo_box_text_get_active_text(GTK_COMBO_BOX_TEXT(abdialog->group)); /* Make anything that is an empty string NULL. */ @@ -194,7 +194,7 @@ g_free(groupname); } - gtk_widget_destroy(GTK_WIDGET(abdialog)); + gtk_window_destroy(GTK_WINDOW(abdialog)); } static void @@ -304,22 +304,22 @@ } if(username != NULL) { - gtk_entry_set_text(GTK_ENTRY(abdialog->username), username); + gtk_editable_set_text(GTK_EDITABLE(abdialog->username), username); } if(alias != NULL) { - gtk_entry_set_text(GTK_ENTRY(abdialog->alias), alias); + gtk_editable_set_text(GTK_EDITABLE(abdialog->alias), alias); } if(message != NULL) { - gtk_entry_set_text(GTK_ENTRY(abdialog->message), message); + gtk_editable_set_text(GTK_EDITABLE(abdialog->message), message); } if(group != NULL) { GtkWidget *entry = NULL; - entry = gtk_bin_get_child(GTK_BIN(abdialog->group)); - gtk_entry_set_text(GTK_ENTRY(entry), group); + entry = gtk_combo_box_get_child(GTK_COMBO_BOX(abdialog->group)); + gtk_editable_set_text(GTK_EDITABLE(entry), group); } return dialog; diff -r 2579a5138f0c -r ac5416e7e4f5 pidgin/resources/Dialogs/addbuddy.ui --- a/pidgin/resources/Dialogs/addbuddy.ui Fri Aug 12 03:44:34 2022 -0500 +++ b/pidgin/resources/Dialogs/addbuddy.ui Mon Aug 15 02:39:09 2022 -0500 @@ -15,12 +15,11 @@ GNU General Public License for more details. You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +along with this program; if not, see . --> - + @@ -34,302 +33,144 @@ account_filter_connected