Commit c9b152ec authored by Matthias Clasen's avatar Matthias Clasen

Remove a leaking get_name implementation

This was leaking a lot of memory; just rely on atk_object_get_name.
parent 91b8417d
......@@ -8172,26 +8172,6 @@ gtk_icon_view_item_accessible_finalize (GObject *object)
G_OBJECT_CLASS (accessible_item_parent_class)->finalize (object);
}
static G_CONST_RETURN gchar*
gtk_icon_view_item_accessible_get_name (AtkObject *obj)
{
if (obj->name)
return obj->name;
else
{
GtkIconViewItemAccessible *item;
GtkTextIter start_iter;
GtkTextIter end_iter;
item = GTK_ICON_VIEW_ITEM_ACCESSIBLE (obj);
gtk_text_buffer_get_start_iter (item->text_buffer, &start_iter);
gtk_text_buffer_get_end_iter (item->text_buffer, &end_iter);
return gtk_text_buffer_get_text (item->text_buffer, &start_iter, &end_iter, FALSE);
}
}
static AtkObject*
gtk_icon_view_item_accessible_get_parent (AtkObject *obj)
{
......@@ -8253,10 +8233,9 @@ gtk_icon_view_item_accessible_class_init (AtkObjectClass *klass)
gobject_class->finalize = gtk_icon_view_item_accessible_finalize;
klass->get_index_in_parent = gtk_icon_view_item_accessible_get_index_in_parent;
klass->get_name = gtk_icon_view_item_accessible_get_name;
klass->get_parent = gtk_icon_view_item_accessible_get_parent;
klass->ref_state_set = gtk_icon_view_item_accessible_ref_state_set;
klass->get_index_in_parent = gtk_icon_view_item_accessible_get_index_in_parent;
klass->get_parent = gtk_icon_view_item_accessible_get_parent;
klass->ref_state_set = gtk_icon_view_item_accessible_ref_state_set;
}
static GType
......@@ -8592,7 +8571,7 @@ gtk_icon_view_accessible_model_row_changed (GtkTreeModel *tree_model,
icon_view = GTK_ICON_VIEW (widget);
item = a11y_item->item;
name = gtk_icon_view_item_accessible_get_name (ATK_OBJECT (a11y_item));
name = atk_object_get_name (ATK_OBJECT (a11y_item));
if (!name || strcmp (name, "") == 0)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment