[gimp] app: remove GimpProjectable::get_layers() and ::get_channels()
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: remove GimpProjectable::get_layers() and ::get_channels()
- Date: Sun, 20 May 2012 18:28:53 +0000 (UTC)
commit 759b71b8e9f657ef20e026955176c7e42d0a08d1
Author: Michael Natterer <mitch gimp org>
Date: Sun May 20 20:28:27 2012 +0200
app: remove GimpProjectable::get_layers() and ::get_channels()
app/core/gimpgrouplayer.c | 11 ------
app/core/gimpimage.c | 2 -
app/core/gimpprojectable.c | 30 ---------------
app/core/gimpprojectable.h | 86 ++++++++++++++++++++------------------------
4 files changed, 39 insertions(+), 90 deletions(-)
---
diff --git a/app/core/gimpgrouplayer.c b/app/core/gimpgrouplayer.c
index 60a8dd8..8d3bc3e 100644
--- a/app/core/gimpgrouplayer.c
+++ b/app/core/gimpgrouplayer.c
@@ -139,7 +139,6 @@ static void gimp_group_layer_convert_type (GimpDrawable *drawabl
static const Babl * gimp_group_layer_get_format (GimpProjectable *projectable);
static GeglNode * gimp_group_layer_get_graph (GimpProjectable *projectable);
-static GList * gimp_group_layer_get_layers (GimpProjectable *projectable);
static gdouble gimp_group_layer_get_opacity_at (GimpPickable *pickable,
gint x,
gint y);
@@ -239,8 +238,6 @@ gimp_projectable_iface_init (GimpProjectableInterface *iface)
iface->get_size = (void (*) (GimpProjectable*, gint*, gint*)) gimp_viewable_get_size;
iface->get_graph = gimp_group_layer_get_graph;
iface->invalidate_preview = (void (*) (GimpProjectable*)) gimp_viewable_invalidate_preview;
- iface->get_layers = gimp_group_layer_get_layers;
- iface->get_channels = NULL;
}
static void
@@ -948,14 +945,6 @@ gimp_group_layer_get_graph (GimpProjectable *projectable)
return private->graph;
}
-static GList *
-gimp_group_layer_get_layers (GimpProjectable *projectable)
-{
- GimpGroupLayerPrivate *private = GET_PRIVATE (projectable);
-
- return gimp_item_stack_get_item_iter (GIMP_ITEM_STACK (private->children));
-}
-
static gdouble
gimp_group_layer_get_opacity_at (GimpPickable *pickable,
gint x,
diff --git a/app/core/gimpimage.c b/app/core/gimpimage.c
index 32fc4b7..a9ad5e5 100644
--- a/app/core/gimpimage.c
+++ b/app/core/gimpimage.c
@@ -616,8 +616,6 @@ gimp_projectable_iface_init (GimpProjectableInterface *iface)
iface->get_size = (void (*) (GimpProjectable*, gint*, gint*)) gimp_image_get_size;
iface->get_graph = gimp_image_get_graph;
iface->invalidate_preview = (void (*) (GimpProjectable*)) gimp_viewable_invalidate_preview;
- iface->get_layers = (GList * (*) (GimpProjectable*)) gimp_image_get_layer_iter;
- iface->get_channels = (GList * (*) (GimpProjectable*)) gimp_image_get_channel_iter;
}
static void
diff --git a/app/core/gimpprojectable.c b/app/core/gimpprojectable.c
index 05f979b..03f9543 100644
--- a/app/core/gimpprojectable.c
+++ b/app/core/gimpprojectable.c
@@ -246,33 +246,3 @@ gimp_projectable_invalidate_preview (GimpProjectable *projectable)
if (iface->invalidate_preview)
iface->invalidate_preview (projectable);
}
-
-GList *
-gimp_projectable_get_layers (GimpProjectable *projectable)
-{
- GimpProjectableInterface *iface;
-
- g_return_val_if_fail (GIMP_IS_PROJECTABLE (projectable), NULL);
-
- iface = GIMP_PROJECTABLE_GET_INTERFACE (projectable);
-
- if (iface->get_layers)
- return iface->get_layers (projectable);
-
- return NULL;
-}
-
-GList *
-gimp_projectable_get_channels (GimpProjectable *projectable)
-{
- GimpProjectableInterface *iface;
-
- g_return_val_if_fail (GIMP_IS_PROJECTABLE (projectable), NULL);
-
- iface = GIMP_PROJECTABLE_GET_INTERFACE (projectable);
-
- if (iface->get_channels)
- return iface->get_channels (projectable);
-
- return NULL;
-}
diff --git a/app/core/gimpprojectable.h b/app/core/gimpprojectable.h
index 11f70c1..09bcc29 100644
--- a/app/core/gimpprojectable.h
+++ b/app/core/gimpprojectable.h
@@ -35,58 +35,50 @@ struct _GimpProjectableInterface
GTypeInterface base_iface;
/* signals */
- void (* invalidate) (GimpProjectable *projectable,
- gint x,
- gint y,
- gint width,
- gint height);
- void (* flush) (GimpProjectable *projectable,
- gboolean invalidate_preview);
- void (* structure_changed) (GimpProjectable *projectable);
+ void (* invalidate) (GimpProjectable *projectable,
+ gint x,
+ gint y,
+ gint width,
+ gint height);
+ void (* flush) (GimpProjectable *projectable,
+ gboolean invalidate_preview);
+ void (* structure_changed) (GimpProjectable *projectable);
/* virtual functions */
- GimpImage * (* get_image) (GimpProjectable *projectable);
- const Babl * (* get_format) (GimpProjectable *projectable);
- void (* get_offset) (GimpProjectable *projectable,
- gint *x,
- gint *y);
- void (* get_size) (GimpProjectable *projectable,
- gint *width,
- gint *height);
- GeglNode * (* get_graph) (GimpProjectable *projectable);
- void (* invalidate_preview) (GimpProjectable *projectable);
-
- /* legacy API virtual functions */
- GList * (* get_layers) (GimpProjectable *projectable);
- GList * (* get_channels) (GimpProjectable *projectable);
+ GimpImage * (* get_image) (GimpProjectable *projectable);
+ const Babl * (* get_format) (GimpProjectable *projectable);
+ void (* get_offset) (GimpProjectable *projectable,
+ gint *x,
+ gint *y);
+ void (* get_size) (GimpProjectable *projectable,
+ gint *width,
+ gint *height);
+ GeglNode * (* get_graph) (GimpProjectable *projectable);
+ void (* invalidate_preview) (GimpProjectable *projectable);
};
-GType gimp_projectable_interface_get_type (void) G_GNUC_CONST;
-
-void gimp_projectable_invalidate (GimpProjectable *projectable,
- gint x,
- gint y,
- gint width,
- gint height);
-void gimp_projectable_flush (GimpProjectable *projectable,
- gboolean preview_invalidated);
-void gimp_projectable_structure_changed (GimpProjectable *projectable);
-
-GimpImage * gimp_projectable_get_image (GimpProjectable *projectable);
-const Babl * gimp_projectable_get_format (GimpProjectable *projectable);
-void gimp_projectable_get_offset (GimpProjectable *projectable,
- gint *x,
- gint *y);
-void gimp_projectable_get_size (GimpProjectable *projectable,
- gint *width,
- gint *height);
-GeglNode * gimp_projectable_get_graph (GimpProjectable *projectable);
-void gimp_projectable_invalidate_preview (GimpProjectable *projectable);
-
-/* legacy API */
-GList * gimp_projectable_get_layers (GimpProjectable *projectable);
-GList * gimp_projectable_get_channels (GimpProjectable *projectable);
+GType gimp_projectable_interface_get_type (void) G_GNUC_CONST;
+
+void gimp_projectable_invalidate (GimpProjectable *projectable,
+ gint x,
+ gint y,
+ gint width,
+ gint height);
+void gimp_projectable_flush (GimpProjectable *projectable,
+ gboolean preview_invalidated);
+void gimp_projectable_structure_changed (GimpProjectable *projectable);
+
+GimpImage * gimp_projectable_get_image (GimpProjectable *projectable);
+const Babl * gimp_projectable_get_format (GimpProjectable *projectable);
+void gimp_projectable_get_offset (GimpProjectable *projectable,
+ gint *x,
+ gint *y);
+void gimp_projectable_get_size (GimpProjectable *projectable,
+ gint *width,
+ gint *height);
+GeglNode * gimp_projectable_get_graph (GimpProjectable *projectable);
+void gimp_projectable_invalidate_preview (GimpProjectable *projectable);
#endif /* __GIMP_PROJECTABLE_H__ */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]