Using GSlice for GtkTreePath

2007-12-31  Philip Van Hoof  <pvanhoof@gnome.org>

        * gtk/gtktreemodel.c: Using GSlice for GtkTreePath


svn path=/trunk/; revision=19292
This commit is contained in:
Philip Van Hoof
2007-12-31 11:26:55 +00:00
committed by Philip Van Hoof
parent 88e5b9d26e
commit 89017e8452
2 changed files with 7 additions and 3 deletions

View File

@ -1,3 +1,7 @@
2007-12-31 Philip Van Hoof <pvanhoof@gnome.org>
* gtk/gtktreemodel.c: Using GSlice for GtkTreePath
2007-12-31 Christian Persch <chpe@gnome.org>
* gtk/gtkprintunixdialog.c: (gtk_print_unix_dialog_get_property):

View File

@ -389,7 +389,7 @@ GtkTreePath *
gtk_tree_path_new (void)
{
GtkTreePath *retval;
retval = g_new (GtkTreePath, 1);
retval = g_slice_new (GtkTreePath);
retval->depth = 0;
retval->indices = NULL;
@ -632,7 +632,7 @@ gtk_tree_path_free (GtkTreePath *path)
return;
g_free (path->indices);
g_free (path);
g_slice_free (GtkTreePath, path);
}
/**
@ -650,7 +650,7 @@ gtk_tree_path_copy (const GtkTreePath *path)
g_return_val_if_fail (path != NULL, NULL);
retval = g_new (GtkTreePath, 1);
retval = g_slice_new (GtkTreePath);
retval->depth = path->depth;
retval->indices = g_new (gint, path->depth);
memcpy (retval->indices, path->indices, path->depth * sizeof (gint));