Use faster new G_VALUE_COLLECT_INIT variant instead G_VALUE_COLLECT

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=641621
This commit is contained in:
Javier Jardón 2011-02-05 17:54:02 +00:00 committed by Javier Jardón
parent beb8c290d1
commit db97f8660a
5 changed files with 11 additions and 11 deletions

View File

@ -2671,8 +2671,8 @@ gtk_cell_area_cell_set_valist (GtkCellArea *area,
break;
}
g_value_init (&value, G_PARAM_SPEC_VALUE_TYPE (pspec));
G_VALUE_COLLECT (&value, var_args, 0, &error);
G_VALUE_COLLECT_INIT (&value, G_PARAM_SPEC_VALUE_TYPE (pspec),
var_args, 0, &error);
if (error)
{
g_warning ("%s: %s", G_STRLOC, error);

View File

@ -1004,8 +1004,9 @@ gtk_container_child_set_valist (GtkContainer *container,
G_OBJECT_TYPE_NAME (container));
break;
}
g_value_init (&value, G_PARAM_SPEC_VALUE_TYPE (pspec));
G_VALUE_COLLECT (&value, var_args, 0, &error);
G_VALUE_COLLECT_INIT (&value, G_PARAM_SPEC_VALUE_TYPE (pspec),
var_args, 0, &error);
if (error)
{
g_warning ("%s: %s", G_STRLOC, error);

View File

@ -875,9 +875,9 @@ gtk_list_store_set_valist_internal (GtkListStore *list_store,
g_warning ("%s: Invalid column number %d added to iter (remember to end your list of columns with a -1)", G_STRLOC, column);
break;
}
g_value_init (&value, priv->column_headers[column]);
G_VALUE_COLLECT (&value, var_args, 0, &error);
G_VALUE_COLLECT_INIT (&value, priv->column_headers[column],
var_args, 0, &error);
if (error)
{
g_warning ("%s: %s", G_STRLOC, error);

View File

@ -736,9 +736,8 @@ gtk_style_properties_set_valist (GtkStyleProperties *props,
if (G_IS_VALUE (val))
g_value_unset (val);
g_value_init (val, node->pspec->value_type);
G_VALUE_COLLECT (val, args, 0, &error);
G_VALUE_COLLECT_INIT (val, node->pspec->value_type,
args, 0, &error);
if (error)
{
g_warning ("Could not set style property \"%s\": %s", property_name, error);

View File

@ -1041,9 +1041,9 @@ gtk_tree_store_set_valist_internal (GtkTreeStore *tree_store,
g_warning ("%s: Invalid column number %d added to iter (remember to end your list of columns with a -1)", G_STRLOC, column);
break;
}
g_value_init (&value, priv->column_headers[column]);
G_VALUE_COLLECT (&value, var_args, 0, &error);
G_VALUE_COLLECT_INIT (&value, priv->column_headers[column],
var_args, 0, &error);
if (error)
{
g_warning ("%s: %s", G_STRLOC, error);