X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=y5QyG2mO4sBZYcGAhMm93gD3X1MGJ64fRYqea8QnPcQ=; b=t6q8H8r6H+FdZ8PDg3Wrd2CBks2UfQc2wZZraUheOwQ06vp7Ab0srj+0F+Ftdb3XgE 2y8ux0jxs1jHYaE2/1FqkWHMuMuJxD4wY1FD9HMDxJ7B8DFcqojquN/9vK5jhu3zJyqp HhifsPb2wJcKhAkUWjC62uNdxnOEoM0foMdkmjT0yhK4bpXCyZQwOEE1GHbYbhwjzP58 ZwnWcr1cQJT/y+q4BYX3Miq2zCMBIl7fJuz27gkaZseFMT1VVIHk59T9ju/hFtLkYW27 KLiVCeXex+SQY8PmWSI08GoOQ8mS0qi94P6H3tYjzUolBkhrLcLfV/Odr1ffg4kZcxi3 3qiA== X-Received: by 10.180.198.234 with SMTP id jf10mr6307934wic.68.1413317954526; Tue, 14 Oct 2014 13:19:14 -0700 (PDT) From: Riccardo Lucchese To: geda-user AT delorie DOT com Cc: paubert AT iram DOT es, Riccardo Lucchese Subject: [geda-user] [PATCH V2 34/43] Remove deprecated use of gtk_widget_ref() Date: Tue, 14 Oct 2014 22:17:26 +0200 Message-Id: <1413317855-10673-35-git-send-email-riccardo.lucchese@gmail.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1413317855-10673-1-git-send-email-riccardo.lucchese@gmail.com> References: <1413317855-10673-1-git-send-email-riccardo DOT lucchese AT gmail DOT com> Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Verbatim from Gtk+ 2 Reference Manual: "gtk_widget_ref has been deprecated since version 2.12 and should not be used in newly-written code. Use g_object_ref() instead." --- gattrib/src/gtksheet_2_2.c | 6 +++--- gschem/src/x_attribedit.c | 14 +++++++------- gschem/src/x_autonumber.c | 2 +- gschem/src/x_dialog.c | 2 +- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/gattrib/src/gtksheet_2_2.c b/gattrib/src/gtksheet_2_2.c index 09bf8fa..051fb7a 100644 --- a/gattrib/src/gtksheet_2_2.c +++ b/gattrib/src/gtksheet_2_2.c @@ -2684,14 +2684,14 @@ gtk_sheet_realize (GtkWidget * widget) GDK_GC_SUBWINDOW); if(sheet->sheet_entry->parent){ - gtk_widget_ref(sheet->sheet_entry); + g_object_ref(sheet->sheet_entry); gtk_widget_unparent(sheet->sheet_entry); } gtk_widget_set_parent_window (sheet->sheet_entry, sheet->sheet_window); gtk_widget_set_parent(sheet->sheet_entry, GTK_WIDGET(sheet)); if(sheet->button && sheet->button->parent){ - gtk_widget_ref(sheet->button); + g_object_ref(sheet->button); gtk_widget_unparent(sheet->button); } gtk_widget_set_parent_window(sheet->button, sheet->sheet_window); @@ -6150,7 +6150,7 @@ create_sheet_entry(GtkSheet *sheet) if(sheet->sheet_entry){ /* avoids warnings */ - gtk_widget_ref(sheet->sheet_entry); + g_object_ref(sheet->sheet_entry); gtk_widget_unparent(sheet->sheet_entry); gtk_widget_destroy(sheet->sheet_entry); } diff --git a/gschem/src/x_attribedit.c b/gschem/src/x_attribedit.c index bc23693..266b2df 100644 --- a/gschem/src/x_attribedit.c +++ b/gschem/src/x_attribedit.c @@ -394,7 +394,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) (GtkAttachOptions) (0), 0, 0); value_entry = gtk_entry_new (); - gtk_widget_ref (value_entry); + g_object_ref(value_entry); g_object_set_data_full(G_OBJECT(aewindow), "value_entry", value_entry, (GtkDestroyNotify)gtk_widget_unref); gtk_table_attach (GTK_TABLE (table), value_entry, 1, 2, 1, 2, @@ -404,7 +404,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) /* Visibility */ visbutton = gtk_check_button_new_with_label (_("Visible")); - gtk_widget_ref (visbutton); + g_object_ref(visbutton); g_object_set_data_full(G_OBJECT(aewindow), "visbutton", visbutton, (GtkDestroyNotify)gtk_widget_unref); @@ -414,7 +414,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) (GtkAttachOptions) (0), 0, 0); show_options = gtk_option_menu_new (); - gtk_widget_ref (show_options); + g_object_ref(show_options); g_object_set_data_full(G_OBJECT(aewindow), "show_options", show_options, (GtkDestroyNotify)gtk_widget_unref); gtk_widget_show (show_options); @@ -450,7 +450,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) addtoallbutton = gtk_radio_button_new_with_label (hbox2_group, _("All")); hbox2_group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(addtoallbutton)); - gtk_widget_ref (addtoallbutton); + g_object_ref(addtoallbutton); g_object_set_data_full(G_OBJECT(aewindow), "addtoallbutton", addtoallbutton, (GtkDestroyNotify)gtk_widget_unref); gtk_table_attach(GTK_TABLE(table), addtoallbutton, 0, 1, 0, 1, @@ -458,7 +458,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) addtocompsbutton = gtk_radio_button_new_with_label (hbox2_group, _("Components")); hbox2_group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(addtocompsbutton)); - gtk_widget_ref (addtocompsbutton); + g_object_ref(addtocompsbutton); g_object_set_data_full(G_OBJECT(aewindow), "addtocompsbutton", addtocompsbutton, (GtkDestroyNotify)gtk_widget_unref); @@ -467,7 +467,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) addtonetsbutton = gtk_radio_button_new_with_label (hbox2_group, _("Nets")); hbox2_group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(addtonetsbutton)); - gtk_widget_ref (addtonetsbutton); + g_object_ref(addtonetsbutton); g_object_set_data_full(G_OBJECT(aewindow), "addtonetsbutton", addtonetsbutton, (GtkDestroyNotify)gtk_widget_unref); @@ -476,7 +476,7 @@ void attrib_edit_dialog (GschemToplevel *w_current, OBJECT *attr_obj, int flag) overwritebutton = gtk_check_button_new_with_label (_("Replace existing attributes")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(overwritebutton), TRUE); - gtk_widget_ref (overwritebutton); + g_object_ref(overwritebutton); g_object_set_data_full(G_OBJECT(aewindow), "overwritebutton", overwritebutton, (GtkDestroyNotify)gtk_widget_unref); diff --git a/gschem/src/x_autonumber.c b/gschem/src/x_autonumber.c index 7a94cc1..0926347 100644 --- a/gschem/src/x_autonumber.c +++ b/gschem/src/x_autonumber.c @@ -34,7 +34,7 @@ #define GLADE_HOOKUP_OBJECT(component,widget,name) \ g_object_set_data_full (G_OBJECT (component), name, \ - gtk_widget_ref (widget), (GDestroyNotify) gtk_widget_unref) + g_object_ref(widget), (GDestroyNotify) gtk_widget_unref) /** @brief How many entries to keep in the "Search text" combo box. */ #define HISTORY_LENGTH 15 diff --git a/gschem/src/x_dialog.c b/gschem/src/x_dialog.c index fcc0381..97120f1 100644 --- a/gschem/src/x_dialog.c +++ b/gschem/src/x_dialog.c @@ -34,7 +34,7 @@ #define GLADE_HOOKUP_OBJECT(component,widget,name) \ g_object_set_data_full (G_OBJECT (component), name, \ - gtk_widget_ref (widget), (GDestroyNotify) gtk_widget_unref) + g_object_ref(widget), (GDestroyNotify) gtk_widget_unref) -- 2.1.0