Commit 94e7e1e5 authored by Sven Neumann's avatar Sven Neumann Committed by Sven Neumann
Browse files

app/config/gimpconfig-deserialize.h fixed typos.

2001-12-13  Sven Neumann  <sven@gimp.org>

	* app/config/gimpconfig-deserialize.h
	* app/config/gimpconfig-serialize.c: fixed typos.

	* app/core/core-enums.h
	* app/core/core-types.h: converted ChannelType enum to GimpChannelType
	and moved it to core-enums.h.

	* app/core/gimpimage.[ch]
	* app/widgets/gimpchannellistview.c
	* app/widgets/gimpcomponentlistitem.[ch]
	* tools/pdbgen/pdb/image.pdb: changed accordingly.

	* app/pdb/image_cmds.c
	* libgimp/gimpenums.h
	* plug-ins/script-fu/script-fu-constants.c
	* tools/pdbgen/enums.pl: regenerated.
parent 1e5888d4
2001-12-13 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-deserialize.h
* app/config/gimpconfig-serialize.c: fixed typos.
* app/core/core-enums.h
* app/core/core-types.h: converted ChannelType enum to GimpChannelType
and moved it to core-enums.h.
* app/core/gimpimage.[ch]
* app/widgets/gimpchannellistview.c
* app/widgets/gimpcomponentlistitem.[ch]
* tools/pdbgen/pdb/image.pdb: changed accordingly.
* app/pdb/image_cmds.c
* libgimp/gimpenums.h
* plug-ins/script-fu/script-fu-constants.c
* tools/pdbgen/enums.pl: regenerated.
2001-12-13 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-deserialize.c
......
/* The GIMP -- an image manipulation program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* Object peoperties deserialization routines
* Object properties deserialization routines
* Copyright (C) 2001 Sven Neumann <sven@gimp.org>
*
* This program is free software; you can redistribute it and/or modify
......
/* The GIMP -- an image manipulation program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* Object propoerties serialization routines
* Object properties serialization routines
* Copyright (C) 2001 Sven Neumann <sven@gimp.org>
*
* This program is free software; you can redistribute it and/or modify
......
......@@ -71,6 +71,16 @@ typedef enum /*< pdb-skip >*/
* non-registered enums; register them if needed
*/
typedef enum /*< skip >*/
{
GIMP_RED_CHANNEL,
GIMP_GREEN_CHANNEL,
GIMP_BLUE_CHANNEL,
GIMP_GRAY_CHANNEL,
GIMP_INDEXED_CHANNEL,
GIMP_ALPHA_CHANNEL
} GimpChannelType;
typedef enum /*< skip >*/
{
GIMP_LINEAR,
......
......@@ -34,16 +34,6 @@
/* enums */
typedef enum
{
RED_CHANNEL,
GREEN_CHANNEL,
BLUE_CHANNEL,
GRAY_CHANNEL,
INDEXED_CHANNEL,
ALPHA_CHANNEL
} ChannelType;
typedef enum /*< chop=ADD_ >*/
{
ADD_WHITE_MASK,
......
......@@ -906,7 +906,7 @@ gimp_image_get_combination_mode (GimpImageType dest_type,
}
gint
gimp_image_get_ID (GimpImage *gimage)
gimp_image_get_ID (const GimpImage *gimage)
{
g_return_val_if_fail (GIMP_IS_IMAGE (gimage), -1);
......@@ -1119,9 +1119,9 @@ gimp_image_mask_changed (GimpImage *gimage)
}
void
gimp_image_set_component_active (GimpImage *gimage,
ChannelType type,
gboolean active)
gimp_image_set_component_active (GimpImage *gimage,
GimpChannelType type,
gboolean active)
{
gint pixel = -1;
......@@ -1129,12 +1129,12 @@ gimp_image_set_component_active (GimpImage *gimage,
switch (type)
{
case RED_CHANNEL: pixel = RED_PIX; break;
case GREEN_CHANNEL: pixel = GREEN_PIX; break;
case BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GRAY_CHANNEL: pixel = GRAY_PIX; break;
case INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case ALPHA_CHANNEL:
case GIMP_RED_CHANNEL: pixel = RED_PIX; break;
case GIMP_GREEN_CHANNEL: pixel = GREEN_PIX; break;
case GIMP_BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GIMP_GRAY_CHANNEL: pixel = GRAY_PIX; break;
case GIMP_INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case GIMP_ALPHA_CHANNEL:
switch (gimp_image_base_type (gimage))
{
case GIMP_RGB: pixel = ALPHA_PIX; break;
......@@ -1164,17 +1164,17 @@ gimp_image_set_component_active (GimpImage *gimage,
gboolean
gimp_image_get_component_active (const GimpImage *gimage,
ChannelType type)
GimpChannelType type)
{
/* No sanity checking here... */
switch (type)
{
case RED_CHANNEL: return gimage->active[RED_PIX]; break;
case GREEN_CHANNEL: return gimage->active[GREEN_PIX]; break;
case BLUE_CHANNEL: return gimage->active[BLUE_PIX]; break;
case GRAY_CHANNEL: return gimage->active[GRAY_PIX]; break;
case INDEXED_CHANNEL: return gimage->active[INDEXED_PIX]; break;
case ALPHA_CHANNEL:
case GIMP_RED_CHANNEL: return gimage->active[RED_PIX]; break;
case GIMP_GREEN_CHANNEL: return gimage->active[GREEN_PIX]; break;
case GIMP_BLUE_CHANNEL: return gimage->active[BLUE_PIX]; break;
case GIMP_GRAY_CHANNEL: return gimage->active[GRAY_PIX]; break;
case GIMP_INDEXED_CHANNEL: return gimage->active[INDEXED_PIX]; break;
case GIMP_ALPHA_CHANNEL:
switch (gimp_image_base_type (gimage))
{
case GIMP_RGB: return gimage->active[ALPHA_PIX]; break;
......@@ -1191,9 +1191,9 @@ gimp_image_get_component_active (const GimpImage *gimage,
}
void
gimp_image_get_active_components (GimpImage *gimage,
GimpDrawable *drawable,
gint *active)
gimp_image_get_active_components (const GimpImage *gimage,
const GimpDrawable *drawable,
gint *active)
{
GimpLayer *layer;
gint i;
......@@ -1224,9 +1224,9 @@ gimp_image_get_active_components (GimpImage *gimage,
}
void
gimp_image_set_component_visible (GimpImage *gimage,
ChannelType type,
gboolean visible)
gimp_image_set_component_visible (GimpImage *gimage,
GimpChannelType type,
gboolean visible)
{
gint pixel = -1;
......@@ -1234,12 +1234,12 @@ gimp_image_set_component_visible (GimpImage *gimage,
switch (type)
{
case RED_CHANNEL: pixel = RED_PIX; break;
case GREEN_CHANNEL: pixel = GREEN_PIX; break;
case BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GRAY_CHANNEL: pixel = GRAY_PIX; break;
case INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case ALPHA_CHANNEL:
case GIMP_RED_CHANNEL: pixel = RED_PIX; break;
case GIMP_GREEN_CHANNEL: pixel = GREEN_PIX; break;
case GIMP_BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GIMP_GRAY_CHANNEL: pixel = GRAY_PIX; break;
case GIMP_INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case GIMP_ALPHA_CHANNEL:
switch (gimp_image_base_type (gimage))
{
case GIMP_RGB: pixel = ALPHA_PIX; break;
......@@ -1266,17 +1266,17 @@ gimp_image_set_component_visible (GimpImage *gimage,
gboolean
gimp_image_get_component_visible (const GimpImage *gimage,
ChannelType type)
GimpChannelType type)
{
/* No sanity checking here... */
switch (type)
{
case RED_CHANNEL: return gimage->visible[RED_PIX]; break;
case GREEN_CHANNEL: return gimage->visible[GREEN_PIX]; break;
case BLUE_CHANNEL: return gimage->visible[BLUE_PIX]; break;
case GRAY_CHANNEL: return gimage->visible[GRAY_PIX]; break;
case INDEXED_CHANNEL: return gimage->visible[INDEXED_PIX]; break;
case ALPHA_CHANNEL:
case GIMP_RED_CHANNEL: return gimage->visible[RED_PIX]; break;
case GIMP_GREEN_CHANNEL: return gimage->visible[GREEN_PIX]; break;
case GIMP_BLUE_CHANNEL: return gimage->visible[BLUE_PIX]; break;
case GIMP_GRAY_CHANNEL: return gimage->visible[GRAY_PIX]; break;
case GIMP_INDEXED_CHANNEL: return gimage->visible[INDEXED_PIX]; break;
case GIMP_ALPHA_CHANNEL:
switch (gimp_image_base_type (gimage))
{
case GIMP_RGB: return gimage->visible[ALPHA_PIX]; break;
......
......@@ -158,9 +158,9 @@ struct _GimpImageClass
void (* active_layer_changed) (GimpImage *gimage);
void (* active_channel_changed) (GimpImage *gimage);
void (* component_visibility_changed) (GimpImage *gimage,
ChannelType channel);
GimpChannelType channel);
void (* component_active_changed) (GimpImage *gimage,
ChannelType channel);
GimpChannelType channel);
void (* mask_changed) (GimpImage *gimage);
void (* resolution_changed) (GimpImage *gimage);
void (* unit_changed) (GimpImage *gimage);
......@@ -199,7 +199,7 @@ GimpImageType gimp_image_base_type_with_alpha (const GimpImage *gimage);
CombinationMode gimp_image_get_combination_mode (GimpImageType dest_type,
gint src_bytes);
gint gimp_image_get_ID (GimpImage *gimage);
gint gimp_image_get_ID (const GimpImage *gimage);
GimpImage * gimp_image_get_by_ID (Gimp *gimp,
gint id);
......@@ -240,19 +240,19 @@ GimpChannel * gimp_image_get_mask (const GimpImage *gimage);
void gimp_image_mask_changed (GimpImage *gimage);
void gimp_image_set_component_active (GimpImage *gimage,
ChannelType type,
GimpChannelType type,
gboolean active);
gboolean gimp_image_get_component_active (const GimpImage *gimage,
ChannelType type);
void gimp_image_get_active_components (GimpImage *gimage,
GimpDrawable *drawable,
GimpChannelType type);
void gimp_image_get_active_components (const GimpImage *gimage,
const GimpDrawable *drawable,
gint *active);
void gimp_image_set_component_visible (GimpImage *gimage,
ChannelType type,
GimpChannelType type,
gboolean visible);
gboolean gimp_image_get_component_visible (const GimpImage *gimage,
ChannelType type);
GimpChannelType type);
void gimp_image_mode_changed (GimpImage *gimage);
void gimp_image_alpha_changed (GimpImage *gimage);
......
......@@ -3213,14 +3213,14 @@ image_get_component_active_invoker (Gimp *gimp,
success = FALSE;
component = args[1].value.pdb_int;
if (component < GREEN_CHANNEL || component > ALPHA_CHANNEL)
if (component < GIMP_GREEN_CHANNEL || component > GIMP_ALPHA_CHANNEL)
success = FALSE;
if (success)
{
if (component == GRAY_CHANNEL)
if (component == GIMP_GRAY_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_GRAY;
else if (component == INDEXED_CHANNEL)
else if (component == GIMP_INDEXED_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_INDEXED;
else
success = gimp_image_base_type (gimage) == GIMP_RGB;
......@@ -3244,7 +3244,7 @@ static ProcArg image_get_component_active_inargs[] =
{
GIMP_PDB_INT32,
"component",
"The image component: { RED_CHANNEL (0), GREEN_CHANNEL (1), BLUE_CHANNEL (2), GRAY_CHANNEL (3), INDEXED_CHANNEL (4), ALPHA_CHANNEL (5) }"
"The image component: { GIMP_RED_CHANNEL (0), GIMP_GREEN_CHANNEL (1), GIMP_BLUE_CHANNEL (2), GIMP_GRAY_CHANNEL (3), GIMP_INDEXED_CHANNEL (4), GIMP_ALPHA_CHANNEL (5) }"
}
};
......@@ -3287,16 +3287,16 @@ image_set_component_active_invoker (Gimp *gimp,
success = FALSE;
component = args[1].value.pdb_int;
if (component < GREEN_CHANNEL || component > ALPHA_CHANNEL)
if (component < GIMP_GREEN_CHANNEL || component > GIMP_ALPHA_CHANNEL)
success = FALSE;
active = args[2].value.pdb_int ? TRUE : FALSE;
if (success)
{
if (component == GRAY_CHANNEL)
if (component == GIMP_GRAY_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_GRAY;
else if (component == INDEXED_CHANNEL)
else if (component == GIMP_INDEXED_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_INDEXED;
else
success = gimp_image_base_type (gimage) == GIMP_RGB;
......@@ -3318,7 +3318,7 @@ static ProcArg image_set_component_active_inargs[] =
{
GIMP_PDB_INT32,
"component",
"The image component: { RED_CHANNEL (0), GREEN_CHANNEL (1), BLUE_CHANNEL (2), GRAY_CHANNEL (3), INDEXED_CHANNEL (4), ALPHA_CHANNEL (5) }"
"The image component: { GIMP_RED_CHANNEL (0), GIMP_GREEN_CHANNEL (1), GIMP_BLUE_CHANNEL (2), GIMP_GRAY_CHANNEL (3), GIMP_INDEXED_CHANNEL (4), GIMP_ALPHA_CHANNEL (5) }"
},
{
GIMP_PDB_INT32,
......@@ -3357,14 +3357,14 @@ image_get_component_visible_invoker (Gimp *gimp,
success = FALSE;
component = args[1].value.pdb_int;
if (component < GREEN_CHANNEL || component > ALPHA_CHANNEL)
if (component < GIMP_GREEN_CHANNEL || component > GIMP_ALPHA_CHANNEL)
success = FALSE;
if (success)
{
if (component == GRAY_CHANNEL)
if (component == GIMP_GRAY_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_GRAY;
else if (component == INDEXED_CHANNEL)
else if (component == GIMP_INDEXED_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_INDEXED;
else
success = gimp_image_base_type (gimage) == GIMP_RGB;
......@@ -3388,7 +3388,7 @@ static ProcArg image_get_component_visible_inargs[] =
{
GIMP_PDB_INT32,
"component",
"The image component: { RED_CHANNEL (0), GREEN_CHANNEL (1), BLUE_CHANNEL (2), GRAY_CHANNEL (3), INDEXED_CHANNEL (4), ALPHA_CHANNEL (5) }"
"The image component: { GIMP_RED_CHANNEL (0), GIMP_GREEN_CHANNEL (1), GIMP_BLUE_CHANNEL (2), GIMP_GRAY_CHANNEL (3), GIMP_INDEXED_CHANNEL (4), GIMP_ALPHA_CHANNEL (5) }"
}
};
......@@ -3431,16 +3431,16 @@ image_set_component_visible_invoker (Gimp *gimp,
success = FALSE;
component = args[1].value.pdb_int;
if (component < GREEN_CHANNEL || component > ALPHA_CHANNEL)
if (component < GIMP_GREEN_CHANNEL || component > GIMP_ALPHA_CHANNEL)
success = FALSE;
visible = args[2].value.pdb_int ? TRUE : FALSE;
if (success)
{
if (component == GRAY_CHANNEL)
if (component == GIMP_GRAY_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_GRAY;
else if (component == INDEXED_CHANNEL)
else if (component == GIMP_INDEXED_CHANNEL)
success = gimp_image_base_type (gimage) == GIMP_INDEXED;
else
success = gimp_image_base_type (gimage) == GIMP_RGB;
......@@ -3462,7 +3462,7 @@ static ProcArg image_set_component_visible_inargs[] =
{
GIMP_PDB_INT32,
"component",
"The image component: { RED_CHANNEL (0), GREEN_CHANNEL (1), BLUE_CHANNEL (2), GRAY_CHANNEL (3), INDEXED_CHANNEL (4), ALPHA_CHANNEL (5) }"
"The image component: { GIMP_RED_CHANNEL (0), GIMP_GREEN_CHANNEL (1), GIMP_BLUE_CHANNEL (2), GIMP_GRAY_CHANNEL (3), GIMP_INDEXED_CHANNEL (4), GIMP_ALPHA_CHANNEL (5) }"
},
{
GIMP_PDB_INT32,
......
......@@ -372,12 +372,12 @@ gimp_channel_list_view_toselection_extended_clicked (GtkWidget *widget
static void
gimp_channel_list_view_create_components (GimpChannelListView *view)
{
GimpImage *gimage;
GtkWidget *list_item;
gint n_components = 0;
ChannelType components[MAX_CHANNELS];
GList *list = NULL;
gint i;
GimpImage *gimage;
GtkWidget *list_item;
gint n_components = 0;
GimpChannelType components[MAX_CHANNELS];
GList *list = NULL;
gint i;
gimage = GIMP_DRAWABLE_LIST_VIEW (view)->gimage;
......@@ -385,23 +385,23 @@ gimp_channel_list_view_create_components (GimpChannelListView *view)
{
case GIMP_RGB:
n_components = 3;
components[0] = RED_CHANNEL;
components[1] = GREEN_CHANNEL;
components[2] = BLUE_CHANNEL;
components[0] = GIMP_RED_CHANNEL;
components[1] = GIMP_GREEN_CHANNEL;
components[2] = GIMP_BLUE_CHANNEL;
break;
case GIMP_GRAY:
n_components = 1;
components[0] = GRAY_CHANNEL;
components[0] = GIMP_GRAY_CHANNEL;
break;
case GIMP_INDEXED:
n_components = 1;
components[0] = INDEXED_CHANNEL;
components[0] = GIMP_INDEXED_CHANNEL;
break;
}
components[n_components++] = ALPHA_CHANNEL;
components[n_components++] = GIMP_ALPHA_CHANNEL;
for (i = 0; i < n_components; i++)
{
......
......@@ -372,12 +372,12 @@ gimp_channel_list_view_toselection_extended_clicked (GtkWidget *widget
static void
gimp_channel_list_view_create_components (GimpChannelListView *view)
{
GimpImage *gimage;
GtkWidget *list_item;
gint n_components = 0;
ChannelType components[MAX_CHANNELS];
GList *list = NULL;
gint i;
GimpImage *gimage;
GtkWidget *list_item;
gint n_components = 0;
GimpChannelType components[MAX_CHANNELS];
GList *list = NULL;
gint i;
gimage = GIMP_DRAWABLE_LIST_VIEW (view)->gimage;
......@@ -385,23 +385,23 @@ gimp_channel_list_view_create_components (GimpChannelListView *view)
{
case GIMP_RGB:
n_components = 3;
components[0] = RED_CHANNEL;
components[1] = GREEN_CHANNEL;
components[2] = BLUE_CHANNEL;
components[0] = GIMP_RED_CHANNEL;
components[1] = GIMP_GREEN_CHANNEL;
components[2] = GIMP_BLUE_CHANNEL;
break;
case GIMP_GRAY:
n_components = 1;
components[0] = GRAY_CHANNEL;
components[0] = GIMP_GRAY_CHANNEL;
break;
case GIMP_INDEXED:
n_components = 1;
components[0] = INDEXED_CHANNEL;
components[0] = GIMP_INDEXED_CHANNEL;
break;
}
components[n_components++] = ALPHA_CHANNEL;
components[n_components++] = GIMP_ALPHA_CHANNEL;
for (i = 0; i < n_components; i++)
{
......
......@@ -43,22 +43,24 @@
static void gimp_component_list_item_class_init (GimpComponentListItemClass *klass);
static void gimp_component_list_item_init (GimpComponentListItem *list_item);
static void gimp_component_list_item_set_viewable (GimpListItem *list_item,
GimpViewable *viewable);
static void gimp_component_list_item_set_viewable (GimpListItem *list_item,
GimpViewable *viewable);
static void gimp_component_list_item_eye_toggled (GtkWidget *widget,
gpointer data);
static void gimp_component_list_item_eye_toggled (GtkWidget *widget,
gpointer data);
static void gimp_component_list_item_visibility_changed (GimpImage *gimage,
ChannelType channel,
gpointer data);
static void gimp_component_list_item_visibility_changed
(GimpImage *gimage,
GimpChannelType channel,
gpointer data);
static void gimp_component_list_item_active_changed (GimpImage *gimage,
ChannelType channel,
gpointer data);
static void gimp_component_list_item_active_changed
(GimpImage *gimage,
GimpChannelType channel,
gpointer data);
static gchar * gimp_component_list_item_get_name (GtkWidget *widget,
gchar **tooltip);
static gchar * gimp_component_list_item_get_name (GtkWidget *widget,
gchar **tooltip);
static GimpListItemClass *parent_class = NULL;
......@@ -137,17 +139,15 @@ gimp_component_list_item_init (GimpComponentListItem *list_item)
}
GtkWidget *
gimp_component_list_item_new (GimpImage *gimage,
gint preview_size,
ChannelType channel)
gimp_component_list_item_new (GimpImage *gimage,
gint preview_size,
GimpChannelType channel)
{
GimpListItem *list_item;
g_return_val_if_fail (GIMP_IS_IMAGE (gimage), NULL);
g_return_val_if_fail (preview_size > 0 && preview_size <= 256, NULL);
g_return_val_if_fail (channel >= RED_CHANNEL && channel <= ALPHA_CHANNEL,
NULL);
list_item = g_object_new (GIMP_TYPE_COMPONENT_LIST_ITEM, NULL);
list_item->preview_size = preview_size;
......@@ -185,15 +185,16 @@ gimp_component_list_item_set_viewable (GimpListItem *list_item,
switch (component_item->channel)
{
case RED_CHANNEL: pixel = RED_PIX; break;
case GREEN_CHANNEL: pixel = GREEN_PIX; break;
case BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GRAY_CHANNEL: pixel = GRAY_PIX; break;
case INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case ALPHA_CHANNEL: pixel = ALPHA_PIX; break;
case GIMP_RED_CHANNEL: pixel = RED_PIX; break;
case GIMP_GREEN_CHANNEL: pixel = GREEN_PIX; break;
case GIMP_BLUE_CHANNEL: pixel = BLUE_PIX; break;
case GIMP_GRAY_CHANNEL: pixel = GRAY_PIX; break;
case GIMP_INDEXED_CHANNEL: pixel = INDEXED_PIX; break;
case GIMP_ALPHA_CHANNEL: pixel = ALPHA_PIX; break;
default:
pixel = 0;
g_assert_not_reached ();
}
GIMP_IMAGE_PREVIEW (list_item->preview)->channel = pixel;
......@@ -277,9 +278,9 @@ gimp_component_list_item_eye_toggled (GtkWidget *widget,
}
static void
gimp_component_list_item_visibility_changed (GimpImage *gimage,
ChannelType channel,
gpointer data)
gimp_component_list_item_visibility_changed (GimpImage *gimage,
GimpChannelType channel,
gpointer data)
{
GimpComponentListItem *component_item;
GimpListItem *list_item;
......@@ -293,7 +294,8 @@ gimp_component_list_item_visibility_changed (GimpImage *gimage,
list_item = GIMP_LIST_ITEM (data);
toggle = GTK_TOGGLE_BUTTON (component_item->eye_button);
visible = gimp_image_get_component_visible (gimage, component_item->channel);
visible = gimp_image_get_component_visible (gimage,
component_item->channel);
if (visible != toggle->active)
{
......@@ -323,9 +325,9 @@ gimp_component_list_item_visibility_changed (GimpImage *gimage,
}
static void
gimp_component_list_item_active_changed (GimpImage *gimage,
ChannelType channel,
gpointer data)
gimp_component_list_item_active_changed (GimpImage *gimage,
GimpChannelType channel,
gpointer data)
{
GimpComponentListItem *component_item;
gboolean active;
......@@ -356,12 +358,14 @@ gimp_component_list_item_get_name (GtkWidget *widget,
switch (component_item->channel)
{
case RED_CHANNEL: return g_strdup (_("Red")); break;
case GREEN_CHANNEL: return g_strdup (_("Green")); break;
case BLUE_CHANNEL: return g_strdup (_("Blue")); break;
case GRAY_CHANNEL: return g_strdup (_("Gray")); break;
case INDEXED_CHANNEL: return g_strdup (_("Indexed")); break;
case ALPHA_CHANNEL: return g_strdup (_("Alpha")); break;
default: return g_strdup ("EEK"); break;
case GIMP_RED_CHANNEL: return g_strdup (_("Red")); break;
case GIMP_GREEN_CHANNEL: return g_strdup (_("Green")); break;
case GIMP_BLUE_CHANNEL: return g_strdup (_("Blue")); break;
case GIMP_GRAY_CHANNEL: return g_strdup (_("Gray")); break;
case GIMP_INDEXED_CHANNEL: return g_strdup (_("Indexed")); break;
case GIMP_ALPHA_CHANNEL: return g_strdup (_("Alpha")); break;
default:
return g_strdup (_("EEEEK"));
}
}
......@@ -37,11 +37,10 @@ typedef struct _GimpComponentListItemClass GimpComponentListItemClass;
struct _GimpComponentListItem
{
GimpListItem parent_instance;
GimpListItem parent_instance;
ChannelType channel;
GtkWidget *eye_button;