Make getting items by tattoo work on trees

This commit is contained in:
Michael Natterer 2009-08-02 00:15:53 +02:00
parent 01c77b18d5
commit 227076b6d1
1 changed files with 12 additions and 1 deletions

View File

@ -2918,10 +2918,21 @@ gimp_image_get_item_by_tattoo (GimpContainer *items,
for (list = GIMP_LIST (items)->list; list; list = g_list_next (list))
{
GimpItem *item = list->data;
GimpItem *item = list->data;
GimpContainer *children;
if (gimp_item_get_tattoo (item) == tattoo)
return item;
children = gimp_viewable_get_children (GIMP_VIEWABLE (item));
if (children)
{
item = gimp_image_get_item_by_tattoo (children, tattoo);
if (item)
return item;
}
}
return NULL;