add new functions gimp_image_get_layer_iter(), channel_iter() and

2008-11-02  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage.[ch]: add new functions
	gimp_image_get_layer_iter(), channel_iter() and vectors_iter()
	which return the GList inside the resp. GimpList.

	* app/actions/channels-actions.c
	* app/actions/layers-actions.c
	* app/actions/vectors-actions.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-flip.c
	* app/core/gimpimage-item-list.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-resize.c
	* app/core/gimpimage-rotate.c
	* app/core/gimpimage-scale.c
	* app/core/gimpimage.c
	* app/core/gimpimage.h
	* app/core/gimpprojection-construct.c
	* app/display/gimpdisplayshell-draw.c
	* app/file/file-open.c
	* app/tools/gimpaligntool.c
	* app/tools/gimpdrawtool.c
	* app/vectors/gimpvectors-compat.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimplayertreeview.c
	* app/xcf/xcf-save.c
	* tools/pdbgen/pdb/image.pdb: use the new functions instead of
	peeking both into the image and the list. Remove inclusions of
	"gimplist.h" or change them into "gimpcontainer.h" if needed.

	* app/pdb/image-cmds.c: regenerated.


svn path=/trunk/; revision=27524
This commit is contained in:
Michael Natterer
2008-11-02 20:46:57 +00:00
committed by Michael Natterer
parent c14c84ba63
commit d1ca165b4e
26 changed files with 154 additions and 98 deletions

View File

@ -27,7 +27,6 @@
#include "gimpimage-item-list.h"
#include "gimpimage-undo.h"
#include "gimpitem.h"
#include "gimplist.h"
#include "gimpprogress.h"
#include "gimp-intl.h"
@ -172,7 +171,7 @@ gimp_image_item_list_get_list (const GimpImage *image,
if (type & GIMP_ITEM_TYPE_LAYERS)
{
for (list = GIMP_LIST (image->layers)->list;
for (list = gimp_image_get_layer_iter (image);
list;
list = g_list_next (list))
{
@ -185,7 +184,7 @@ gimp_image_item_list_get_list (const GimpImage *image,
if (type & GIMP_ITEM_TYPE_CHANNELS)
{
for (list = GIMP_LIST (image->channels)->list;
for (list = gimp_image_get_channel_iter (image);
list;
list = g_list_next (list))
{
@ -198,7 +197,7 @@ gimp_image_item_list_get_list (const GimpImage *image,
if (type & GIMP_ITEM_TYPE_VECTORS)
{
for (list = GIMP_LIST (image->vectors)->list;
for (list = gimp_image_get_vectors_iter (image);
list;
list = g_list_next (list))
{