summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/gtk+/glade-gtk-grid.c5
-rw-r--r--plugins/gtk+/glade-gtk-notebook.c2
-rw-r--r--plugins/gtk+/glade-gtk-table.c5
3 files changed, 5 insertions, 7 deletions
diff --git a/plugins/gtk+/glade-gtk-grid.c b/plugins/gtk+/glade-gtk-grid.c
index f1760fa0..a851b2e7 100644
--- a/plugins/gtk+/glade-gtk-grid.c
+++ b/plugins/gtk+/glade-gtk-grid.c
@@ -530,7 +530,7 @@ glade_gtk_grid_child_insert_remove_action (GladeWidgetAdaptor *adaptor,
children = glade_widget_adaptor_get_children (adaptor, container);
/* Make sure widgets does not get destroyed */
- g_list_foreach (children, (GFunc) g_object_ref, NULL);
+ glade_util_object_list_ref (children);
glade_widget_property_get (parent, n_row_col, &size);
@@ -612,8 +612,7 @@ glade_gtk_grid_child_insert_remove_action (GladeWidgetAdaptor *adaptor,
size - 1);
}
- g_list_foreach (children, (GFunc) g_object_unref, NULL);
- g_list_free (children);
+ g_list_free_full (children, g_object_unref);
glade_command_pop_group ();
}
diff --git a/plugins/gtk+/glade-gtk-notebook.c b/plugins/gtk+/glade-gtk-notebook.c
index cd5de473..8847e5da 100644
--- a/plugins/gtk+/glade-gtk-notebook.c
+++ b/plugins/gtk+/glade-gtk-notebook.c
@@ -1005,7 +1005,7 @@ glade_gtk_box_notebook_child_insert_remove_action (GladeWidgetAdaptor *adaptor,
/* Make sure widgets does not get destroyed */
children = glade_widget_adaptor_get_children (adaptor, container);
- g_list_foreach (children, (GFunc) g_object_ref, NULL);
+ glade_util_object_list_ref (children);
glade_widget_property_get (parent, size_prop, &size);
diff --git a/plugins/gtk+/glade-gtk-table.c b/plugins/gtk+/glade-gtk-table.c
index dbaa0a28..2c67f338 100644
--- a/plugins/gtk+/glade-gtk-table.c
+++ b/plugins/gtk+/glade-gtk-table.c
@@ -563,7 +563,7 @@ glade_gtk_table_child_insert_remove_action (GladeWidgetAdaptor *adaptor,
children = glade_widget_adaptor_get_children (adaptor, container);
/* Make sure widgets does not get destroyed */
- g_list_foreach (children, (GFunc) g_object_ref, NULL);
+ glade_util_object_list_ref (children);
glade_widget_property_get (parent, n_row_col, &size);
@@ -660,8 +660,7 @@ glade_gtk_table_child_insert_remove_action (GladeWidgetAdaptor *adaptor,
size - 1);
}
- g_list_foreach (children, (GFunc) g_object_unref, NULL);
- g_list_free (children);
+ g_list_free_full (children, g_object_unref);
glade_command_pop_group ();
}