[gimp] app: implement GObject::constructed() instead of ::constructor()



commit 5e4eee4653cdb27794d272a4ec9da8041a9cc9c6
Author: Michael Natterer <mitch gimp org>
Date:   Wed Jan 12 22:53:58 2011 +0100

    app: implement GObject::constructed() instead of ::constructor()

 app/core/gimpbrushclipboard.c    |   22 +++-------
 app/core/gimpchannelpropundo.c   |   28 +++++---------
 app/core/gimpchannelundo.c       |   52 ++++++++++---------------
 app/core/gimpcontext.c           |   18 +++------
 app/core/gimpdata.c              |   66 ++++++++++++++------------------
 app/core/gimpdrawablemodundo.c   |   57 ++++++++++++----------------
 app/core/gimpdrawablestack.c     |   78 +++++++++++++++++---------------------
 app/core/gimpdrawableundo.c      |   56 ++++++++++++---------------
 app/core/gimpfilteredcontainer.c |   25 +++---------
 app/core/gimpfloatingselundo.c   |   28 +++++---------
 app/core/gimpgrouplayerundo.c    |   28 +++++---------
 app/core/gimpguideundo.c         |   50 ++++++++++--------------
 app/core/gimpimage.c             |   25 ++++--------
 app/core/gimpimageundo.c         |   56 ++++++++++++---------------
 app/core/gimpitempropundo.c      |   56 ++++++++++++---------------
 app/core/gimpitemstack.c         |   30 +++++---------
 app/core/gimpitemtree.c          |   57 ++++++++++++----------------
 app/core/gimpitemundo.c          |   44 +++++++++-------------
 app/core/gimplayermaskpropundo.c |   26 +++++--------
 app/core/gimplayermaskundo.c     |   56 ++++++++++++---------------
 app/core/gimplayerpropundo.c     |   28 +++++---------
 app/core/gimplayerundo.c         |   52 ++++++++++---------------
 app/core/gimpmaskundo.c          |   36 +++++++-----------
 app/core/gimppatternclipboard.c  |   22 +++-------
 app/core/gimppdbprogress.c       |   22 +++-------
 app/core/gimpsamplepointundo.c   |   50 ++++++++++--------------
 app/core/gimptoolpreset.c        |   22 +++-------
 app/core/gimpundo.c              |   22 +++-------
 28 files changed, 441 insertions(+), 671 deletions(-)
---
diff --git a/app/core/gimpbrushclipboard.c b/app/core/gimpbrushclipboard.c
index c064673..4e5d24e 100644
--- a/app/core/gimpbrushclipboard.c
+++ b/app/core/gimpbrushclipboard.c
@@ -47,9 +47,7 @@ enum
 
 /*  local function prototypes  */
 
-static GObject  * gimp_brush_clipboard_constructor  (GType         type,
-                                                     guint         n_params,
-                                                     GObjectConstructParam *params);
+static void       gimp_brush_clipboard_constructed  (GObject      *object);
 static void       gimp_brush_clipboard_set_property (GObject      *object,
                                                      guint         property_id,
                                                      const GValue *value,
@@ -79,7 +77,7 @@ gimp_brush_clipboard_class_init (GimpBrushClipboardClass *klass)
   GimpDataClass *data_class   = GIMP_DATA_CLASS (klass);
 #endif
 
-  object_class->constructor  = gimp_brush_clipboard_constructor;
+  object_class->constructed  = gimp_brush_clipboard_constructed;
   object_class->set_property = gimp_brush_clipboard_set_property;
   object_class->get_property = gimp_brush_clipboard_get_property;
 
@@ -100,17 +98,13 @@ gimp_brush_clipboard_init (GimpBrushClipboard *brush)
   brush->gimp = NULL;
 }
 
-static GObject *
-gimp_brush_clipboard_constructor (GType                  type,
-                                  guint                  n_params,
-                                  GObjectConstructParam *params)
+static void
+gimp_brush_clipboard_constructed (GObject *object)
 {
-  GObject            *object;
-  GimpBrushClipboard *brush;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpBrushClipboard *brush = GIMP_BRUSH_CLIPBOARD (object);
 
-  brush = GIMP_BRUSH_CLIPBOARD (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GIMP (brush->gimp));
 
@@ -119,8 +113,6 @@ gimp_brush_clipboard_constructor (GType                  type,
                            brush, 0);
 
   gimp_brush_clipboard_buffer_changed (brush->gimp, GIMP_BRUSH (brush));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpchannelpropundo.c b/app/core/gimpchannelpropundo.c
index 43190d9..9400df3 100644
--- a/app/core/gimpchannelpropundo.c
+++ b/app/core/gimpchannelpropundo.c
@@ -28,13 +28,11 @@
 #include "gimpchannelpropundo.h"
 
 
-static GObject * gimp_channel_prop_undo_constructor (GType                  type,
-                                                     guint                  n_params,
-                                                     GObjectConstructParam *params);
+static void   gimp_channel_prop_undo_constructed (GObject             *object);
 
-static void      gimp_channel_prop_undo_pop         (GimpUndo              *undo,
-                                                     GimpUndoMode           undo_mode,
-                                                     GimpUndoAccumulator   *accum);
+static void   gimp_channel_prop_undo_pop         (GimpUndo            *undo,
+                                                  GimpUndoMode         undo_mode,
+                                                  GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpChannelPropUndo, gimp_channel_prop_undo, GIMP_TYPE_ITEM_UNDO)
@@ -48,7 +46,7 @@ gimp_channel_prop_undo_class_init (GimpChannelPropUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor = gimp_channel_prop_undo_constructor;
+  object_class->constructed = gimp_channel_prop_undo_constructed;
 
   undo_class->pop           = gimp_channel_prop_undo_pop;
 }
@@ -58,19 +56,15 @@ gimp_channel_prop_undo_init (GimpChannelPropUndo *undo)
 {
 }
 
-static GObject *
-gimp_channel_prop_undo_constructor (GType                  type,
-                                    guint                  n_params,
-                                    GObjectConstructParam *params)
+static void
+gimp_channel_prop_undo_constructed (GObject *object)
 {
-  GObject             *object;
-  GimpChannelPropUndo *channel_prop_undo;
+  GimpChannelPropUndo *channel_prop_undo = GIMP_CHANNEL_PROP_UNDO (object);
   GimpImage           *image;
   GimpChannel         *channel;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  channel_prop_undo = GIMP_CHANNEL_PROP_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_CHANNEL (GIMP_ITEM_UNDO (object)->item));
 
@@ -86,8 +80,6 @@ gimp_channel_prop_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpchannelundo.c b/app/core/gimpchannelundo.c
index eb410e8..4eff783 100644
--- a/app/core/gimpchannelundo.c
+++ b/app/core/gimpchannelundo.c
@@ -35,24 +35,22 @@ enum
 };
 
 
-static GObject * gimp_channel_undo_constructor  (GType                  type,
-                                                 guint                  n_params,
-                                                 GObjectConstructParam *params);
-static void      gimp_channel_undo_set_property (GObject               *object,
-                                                 guint                  property_id,
-                                                 const GValue          *value,
-                                                 GParamSpec            *pspec);
-static void      gimp_channel_undo_get_property (GObject               *object,
-                                                 guint                  property_id,
-                                                 GValue                *value,
-                                                 GParamSpec            *pspec);
-
-static gint64    gimp_channel_undo_get_memsize  (GimpObject            *object,
-                                                 gint64                *gui_size);
-
-static void      gimp_channel_undo_pop          (GimpUndo              *undo,
-                                                 GimpUndoMode           undo_mode,
-                                                 GimpUndoAccumulator   *accum);
+static void    gimp_channel_undo_constructed  (GObject             *object);
+static void    gimp_channel_undo_set_property (GObject             *object,
+                                               guint                property_id,
+                                               const GValue        *value,
+                                               GParamSpec          *pspec);
+static void    gimp_channel_undo_get_property (GObject             *object,
+                                               guint                property_id,
+                                               GValue              *value,
+                                               GParamSpec          *pspec);
+
+static gint64  gimp_channel_undo_get_memsize  (GimpObject          *object,
+                                               gint64              *gui_size);
+
+static void    gimp_channel_undo_pop          (GimpUndo            *undo,
+                                               GimpUndoMode         undo_mode,
+                                               GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpChannelUndo, gimp_channel_undo, GIMP_TYPE_ITEM_UNDO)
@@ -67,7 +65,7 @@ gimp_channel_undo_class_init (GimpChannelUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_channel_undo_constructor;
+  object_class->constructed      = gimp_channel_undo_constructed;
   object_class->set_property     = gimp_channel_undo_set_property;
   object_class->get_property     = gimp_channel_undo_get_property;
 
@@ -102,21 +100,13 @@ gimp_channel_undo_init (GimpChannelUndo *undo)
 {
 }
 
-static GObject *
-gimp_channel_undo_constructor (GType                  type,
-                               guint                  n_params,
-                               GObjectConstructParam *params)
+static void
+gimp_channel_undo_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpChannelUndo *channel_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  channel_undo = GIMP_CHANNEL_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_CHANNEL (GIMP_ITEM_UNDO (object)->item));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpcontext.c b/app/core/gimpcontext.c
index c90eb77..570e9b7 100644
--- a/app/core/gimpcontext.c
+++ b/app/core/gimpcontext.c
@@ -67,9 +67,7 @@ typedef void (* GimpContextCopyPropFunc) (GimpContext *src,
 
 static void    gimp_context_config_iface_init (GimpConfigInterface   *iface);
 
-static GObject *  gimp_context_constructor    (GType                  type,
-                                               guint                  n_params,
-                                               GObjectConstructParam *params);
+static void       gimp_context_constructed    (GObject               *object);
 static void       gimp_context_dispose        (GObject               *object);
 static void       gimp_context_finalize       (GObject               *object);
 static void       gimp_context_set_property   (GObject               *object,
@@ -553,7 +551,7 @@ gimp_context_class_init (GimpContextClass *klass)
                   G_TYPE_NONE, 1,
                   GIMP_TYPE_TEMPLATE);
 
-  object_class->constructor      = gimp_context_constructor;
+  object_class->constructed      = gimp_context_constructed;
   object_class->set_property     = gimp_context_set_property;
   object_class->get_property     = gimp_context_get_property;
   object_class->dispose          = gimp_context_dispose;
@@ -769,16 +767,14 @@ gimp_context_config_iface_init (GimpConfigInterface *iface)
   iface->deserialize_property = gimp_context_deserialize_property;
 }
 
-static GObject *
-gimp_context_constructor (GType                  type,
-                          guint                  n_params,
-                          GObjectConstructParam *params)
+static void
+gimp_context_constructed (GObject *object)
 {
-  GObject       *object;
   Gimp          *gimp;
   GimpContainer *container;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   gimp = GIMP_CONTEXT (object)->gimp;
 
@@ -882,8 +878,6 @@ gimp_context_constructor (GType                  type,
   g_signal_connect_object (gimp->templates, "thaw",
                            G_CALLBACK (gimp_context_template_list_thaw),
                            object, 0);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpdata.c b/app/core/gimpdata.c
index b48088b..81705ea 100644
--- a/app/core/gimpdata.c
+++ b/app/core/gimpdata.c
@@ -88,38 +88,35 @@ struct _GimpDataPrivate
         G_TYPE_INSTANCE_GET_PRIVATE (data, GIMP_TYPE_DATA, GimpDataPrivate)
 
 
-static void      gimp_data_class_init        (GimpDataClass         *klass);
-static void      gimp_data_tagged_iface_init (GimpTaggedInterface   *iface);
+static void      gimp_data_class_init        (GimpDataClass       *klass);
+static void      gimp_data_tagged_iface_init (GimpTaggedInterface *iface);
 
-static void      gimp_data_init              (GimpData              *data,
-                                              GimpDataClass         *data_class);
+static void      gimp_data_init              (GimpData            *data,
+                                              GimpDataClass       *data_class);
 
-static GObject * gimp_data_constructor       (GType                  type,
-                                              guint                  n_params,
-                                              GObjectConstructParam *params);
+static void      gimp_data_constructed       (GObject             *object);
+static void      gimp_data_finalize          (GObject             *object);
+static void      gimp_data_set_property      (GObject             *object,
+                                              guint                property_id,
+                                              const GValue        *value,
+                                              GParamSpec          *pspec);
+static void      gimp_data_get_property      (GObject             *object,
+                                              guint                property_id,
+                                              GValue              *value,
+                                              GParamSpec          *pspec);
 
-static void      gimp_data_finalize          (GObject               *object);
-static void      gimp_data_set_property      (GObject               *object,
-                                              guint                  property_id,
-                                              const GValue          *value,
-                                              GParamSpec            *pspec);
-static void      gimp_data_get_property      (GObject               *object,
-                                              guint                  property_id,
-                                              GValue                *value,
-                                              GParamSpec            *pspec);
+static gint64    gimp_data_get_memsize       (GimpObject          *object,
+                                              gint64              *gui_size);
 
-static gint64    gimp_data_get_memsize       (GimpObject            *object,
-                                              gint64                *gui_size);
+static void      gimp_data_real_dirty        (GimpData            *data);
 
-static void      gimp_data_real_dirty        (GimpData              *data);
-
-static gboolean  gimp_data_add_tag           (GimpTagged            *tagged,
-                                              GimpTag               *tag);
-static gboolean  gimp_data_remove_tag        (GimpTagged            *tagged,
-                                              GimpTag               *tag);
-static GList *   gimp_data_get_tags          (GimpTagged            *tagged);
-static gchar *   gimp_data_get_identifier    (GimpTagged            *tagged);
-static gchar *   gimp_data_get_checksum      (GimpTagged            *tagged);
+static gboolean  gimp_data_add_tag           (GimpTagged          *tagged,
+                                              GimpTag             *tag);
+static gboolean  gimp_data_remove_tag        (GimpTagged          *tagged,
+                                              GimpTag             *tag);
+static GList *   gimp_data_get_tags          (GimpTagged          *tagged);
+static gchar *   gimp_data_get_identifier    (GimpTagged          *tagged);
+static gchar *   gimp_data_get_checksum      (GimpTagged          *tagged);
 
 
 static guint data_signals[LAST_SIGNAL] = { 0 };
@@ -181,7 +178,7 @@ gimp_data_class_init (GimpDataClass *klass)
                   gimp_marshal_VOID__VOID,
                   G_TYPE_NONE, 0);
 
-  object_class->constructor       = gimp_data_constructor;
+  object_class->constructed       = gimp_data_constructed;
   object_class->finalize          = gimp_data_finalize;
   object_class->set_property      = gimp_data_set_property;
   object_class->get_property      = gimp_data_get_property;
@@ -247,18 +244,13 @@ gimp_data_init (GimpData      *data,
   gimp_data_freeze (data);
 }
 
-static GObject *
-gimp_data_constructor (GType                  type,
-                       guint                  n_params,
-                       GObjectConstructParam *params)
+static void
+gimp_data_constructed (GObject *object)
 {
-  GObject *object;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   gimp_data_thaw (GIMP_DATA (object));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpdrawablemodundo.c b/app/core/gimpdrawablemodundo.c
index 12b24fb..f1b68f0 100644
--- a/app/core/gimpdrawablemodundo.c
+++ b/app/core/gimpdrawablemodundo.c
@@ -35,27 +35,24 @@ enum
 };
 
 
-static GObject * gimp_drawable_mod_undo_constructor  (GType                  type,
-                                                      guint                  n_params,
-                                                      GObjectConstructParam *params);
-static void      gimp_drawable_mod_undo_set_property (GObject               *object,
-                                                      guint                  property_id,
-                                                      const GValue          *value,
-                                                      GParamSpec            *pspec);
-static void      gimp_drawable_mod_undo_get_property (GObject               *object,
-                                                      guint                  property_id,
-                                                      GValue                *value,
-                                                      GParamSpec            *pspec);
-
-
-static gint64    gimp_drawable_mod_undo_get_memsize  (GimpObject            *object,
-                                                      gint64                *gui_size);
-
-static void      gimp_drawable_mod_undo_pop          (GimpUndo              *undo,
-                                                      GimpUndoMode           undo_mode,
-                                                      GimpUndoAccumulator   *accum);
-static void      gimp_drawable_mod_undo_free         (GimpUndo              *undo,
-                                                      GimpUndoMode           undo_mode);
+static void     gimp_drawable_mod_undo_constructed  (GObject             *object);
+static void     gimp_drawable_mod_undo_set_property (GObject             *object,
+                                                     guint                property_id,
+                                                     const GValue        *value,
+                                                     GParamSpec          *pspec);
+static void     gimp_drawable_mod_undo_get_property (GObject             *object,
+                                                     guint                property_id,
+                                                     GValue              *value,
+                                                     GParamSpec          *pspec);
+
+static gint64   gimp_drawable_mod_undo_get_memsize  (GimpObject          *object,
+                                                     gint64              *gui_size);
+
+static void     gimp_drawable_mod_undo_pop          (GimpUndo            *undo,
+                                                     GimpUndoMode         undo_mode,
+                                                     GimpUndoAccumulator *accum);
+static void     gimp_drawable_mod_undo_free         (GimpUndo            *undo,
+                                                     GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpDrawableModUndo, gimp_drawable_mod_undo, GIMP_TYPE_ITEM_UNDO)
@@ -70,7 +67,7 @@ gimp_drawable_mod_undo_class_init (GimpDrawableModUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_drawable_mod_undo_constructor;
+  object_class->constructed      = gimp_drawable_mod_undo_constructed;
   object_class->set_property     = gimp_drawable_mod_undo_set_property;
   object_class->get_property     = gimp_drawable_mod_undo_get_property;
 
@@ -91,19 +88,15 @@ gimp_drawable_mod_undo_init (GimpDrawableModUndo *undo)
 {
 }
 
-static GObject *
-gimp_drawable_mod_undo_constructor (GType                  type,
-                                    guint                  n_params,
-                                    GObjectConstructParam *params)
+static void
+gimp_drawable_mod_undo_constructed (GObject *object)
 {
-  GObject             *object;
-  GimpDrawableModUndo *drawable_mod_undo;
+  GimpDrawableModUndo *drawable_mod_undo = GIMP_DRAWABLE_MOD_UNDO (object);
   GimpItem            *item;
   GimpDrawable        *drawable;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  drawable_mod_undo = GIMP_DRAWABLE_MOD_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_DRAWABLE (GIMP_ITEM_UNDO (object)->item));
 
@@ -126,8 +119,6 @@ gimp_drawable_mod_undo_constructor (GType                  type,
   gimp_item_get_offset (item,
                         &drawable_mod_undo->offset_x,
                         &drawable_mod_undo->offset_y);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpdrawablestack.c b/app/core/gimpdrawablestack.c
index 685e07b..0d12a1f 100644
--- a/app/core/gimpdrawablestack.c
+++ b/app/core/gimpdrawablestack.c
@@ -38,37 +38,35 @@ enum
 
 /*  local function prototypes  */
 
-static GObject * gimp_drawable_stack_constructor      (GType              type,
-                                                       guint              n_params,
-                                                       GObjectConstructParam *params);
-static void      gimp_drawable_stack_finalize         (GObject           *object);
-
-static void      gimp_drawable_stack_add              (GimpContainer     *container,
-                                                       GimpObject        *object);
-static void      gimp_drawable_stack_remove           (GimpContainer     *container,
-                                                       GimpObject        *object);
-static void      gimp_drawable_stack_reorder          (GimpContainer     *container,
-                                                       GimpObject        *object,
-                                                       gint               new_index);
-
-static void      gimp_drawable_stack_add_node         (GimpDrawableStack *stack,
-                                                       GimpDrawable      *drawable);
-static void      gimp_drawable_stack_remove_node      (GimpDrawableStack *stack,
-                                                       GimpDrawable      *drawable);
-
-static void      gimp_drawable_stack_update           (GimpDrawableStack *stack,
-                                                       gint               x,
-                                                       gint               y,
-                                                       gint               width,
-                                                       gint               height);
-static void      gimp_drawable_stack_drawable_update  (GimpItem          *item,
-                                                       gint               x,
-                                                       gint               y,
-                                                       gint               width,
-                                                       gint               height,
-                                                       GimpDrawableStack *stack);
-static void      gimp_drawable_stack_drawable_visible (GimpItem          *item,
-                                                       GimpDrawableStack *stack);
+static void   gimp_drawable_stack_constructed      (GObject           *object);
+static void   gimp_drawable_stack_finalize         (GObject           *object);
+
+static void   gimp_drawable_stack_add              (GimpContainer     *container,
+                                                    GimpObject        *object);
+static void   gimp_drawable_stack_remove           (GimpContainer     *container,
+                                                    GimpObject        *object);
+static void   gimp_drawable_stack_reorder          (GimpContainer     *container,
+                                                    GimpObject        *object,
+                                                    gint               new_index);
+
+static void   gimp_drawable_stack_add_node         (GimpDrawableStack *stack,
+                                                    GimpDrawable      *drawable);
+static void   gimp_drawable_stack_remove_node      (GimpDrawableStack *stack,
+                                                    GimpDrawable      *drawable);
+
+static void   gimp_drawable_stack_update           (GimpDrawableStack *stack,
+                                                    gint               x,
+                                                    gint               y,
+                                                    gint               width,
+                                                    gint               height);
+static void   gimp_drawable_stack_drawable_update  (GimpItem          *item,
+                                                    gint               x,
+                                                    gint               y,
+                                                    gint               width,
+                                                    gint               height,
+                                                    GimpDrawableStack *stack);
+static void   gimp_drawable_stack_drawable_visible (GimpItem          *item,
+                                                    GimpDrawableStack *stack);
 
 
 G_DEFINE_TYPE (GimpDrawableStack, gimp_drawable_stack, GIMP_TYPE_ITEM_STACK)
@@ -97,7 +95,7 @@ gimp_drawable_stack_class_init (GimpDrawableStackClass *klass)
                   G_TYPE_INT,
                   G_TYPE_INT);
 
-  object_class->constructor = gimp_drawable_stack_constructor;
+  object_class->constructed = gimp_drawable_stack_constructed;
   object_class->finalize    = gimp_drawable_stack_finalize;
 
   container_class->add      = gimp_drawable_stack_add;
@@ -110,17 +108,13 @@ gimp_drawable_stack_init (GimpDrawableStack *stack)
 {
 }
 
-static GObject *
-gimp_drawable_stack_constructor (GType                  type,
-                                 guint                  n_params,
-                                 GObjectConstructParam *params)
+static void
+gimp_drawable_stack_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpContainer *container;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpContainer *container = GIMP_CONTAINER (object);
 
-  container = GIMP_CONTAINER (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (g_type_is_a (gimp_container_get_children_type (container),
                          GIMP_TYPE_DRAWABLE));
@@ -131,8 +125,6 @@ gimp_drawable_stack_constructor (GType                  type,
   gimp_container_add_handler (container, "visibility-changed",
                               G_CALLBACK (gimp_drawable_stack_drawable_visible),
                               container);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpdrawableundo.c b/app/core/gimpdrawableundo.c
index ad7cf0b..231f42d 100644
--- a/app/core/gimpdrawableundo.c
+++ b/app/core/gimpdrawableundo.c
@@ -42,26 +42,24 @@ enum
 };
 
 
-static GObject * gimp_drawable_undo_constructor  (GType                  type,
-                                                  guint                  n_params,
-                                                  GObjectConstructParam *params);
-static void      gimp_drawable_undo_set_property (GObject               *object,
-                                                  guint                  property_id,
-                                                  const GValue          *value,
-                                                  GParamSpec            *pspec);
-static void      gimp_drawable_undo_get_property (GObject               *object,
-                                                  guint                  property_id,
-                                                  GValue                *value,
-                                                  GParamSpec            *pspec);
-
-static gint64    gimp_drawable_undo_get_memsize  (GimpObject            *object,
-                                                  gint64                *gui_size);
-
-static void      gimp_drawable_undo_pop          (GimpUndo              *undo,
-                                                  GimpUndoMode           undo_mode,
-                                                  GimpUndoAccumulator   *accum);
-static void      gimp_drawable_undo_free         (GimpUndo              *undo,
-                                                  GimpUndoMode           undo_mode);
+static void     gimp_drawable_undo_constructed  (GObject             *object);
+static void     gimp_drawable_undo_set_property (GObject             *object,
+                                                 guint                property_id,
+                                                 const GValue        *value,
+                                                 GParamSpec          *pspec);
+static void     gimp_drawable_undo_get_property (GObject             *object,
+                                                 guint                property_id,
+                                                 GValue              *value,
+                                                 GParamSpec          *pspec);
+
+static gint64   gimp_drawable_undo_get_memsize  (GimpObject          *object,
+                                                 gint64              *gui_size);
+
+static void     gimp_drawable_undo_pop          (GimpUndo            *undo,
+                                                 GimpUndoMode         undo_mode,
+                                                 GimpUndoAccumulator *accum);
+static void     gimp_drawable_undo_free         (GimpUndo            *undo,
+                                                 GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpDrawableUndo, gimp_drawable_undo, GIMP_TYPE_ITEM_UNDO)
@@ -76,7 +74,7 @@ gimp_drawable_undo_class_init (GimpDrawableUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_drawable_undo_constructor;
+  object_class->constructed      = gimp_drawable_undo_constructed;
   object_class->set_property     = gimp_drawable_undo_set_property;
   object_class->get_property     = gimp_drawable_undo_get_property;
 
@@ -127,22 +125,16 @@ gimp_drawable_undo_init (GimpDrawableUndo *undo)
 {
 }
 
-static GObject *
-gimp_drawable_undo_constructor (GType                  type,
-                                guint                  n_params,
-                                GObjectConstructParam *params)
+static void
+gimp_drawable_undo_constructed (GObject *object)
 {
-  GObject          *object;
-  GimpDrawableUndo *drawable_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpDrawableUndo *drawable_undo = GIMP_DRAWABLE_UNDO (object);
 
-  drawable_undo = GIMP_DRAWABLE_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_DRAWABLE (GIMP_ITEM_UNDO (object)->item));
   g_assert (drawable_undo->tiles != NULL);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpfilteredcontainer.c b/app/core/gimpfilteredcontainer.c
index 32e6d29..99cd874 100644
--- a/app/core/gimpfilteredcontainer.c
+++ b/app/core/gimpfilteredcontainer.c
@@ -52,10 +52,7 @@ typedef struct _MatchParams
 } MatchParams;
 
 
-static GObject * gimp_filtered_container_constructor        (GType                  type,
-                                                             guint                  n_construct_params,
-                                                             GObjectConstructParam *construct_params);
-
+static void      gimp_filtered_container_constructed        (GObject               *object);
 static void      gimp_filtered_container_dispose            (GObject               *object);
 static void      gimp_filtered_container_set_property       (GObject               *object,
                                                              guint                  property_id,
@@ -111,7 +108,7 @@ gimp_filtered_container_class_init (GimpFilteredContainerClass *klass)
   GObjectClass    *g_object_class    = G_OBJECT_CLASS (klass);
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
 
-  g_object_class->constructor    = gimp_filtered_container_constructor;
+  g_object_class->constructed    = gimp_filtered_container_constructed;
   g_object_class->dispose        = gimp_filtered_container_dispose;
   g_object_class->set_property   = gimp_filtered_container_set_property;
   g_object_class->get_property   = gimp_filtered_container_get_property;
@@ -147,19 +144,13 @@ gimp_filtered_container_init (GimpFilteredContainer *filtered_container)
   filtered_container->tag_count      = 0;
 }
 
-static GObject*
-gimp_filtered_container_constructor (GType                   type,
-                                     guint                   n_construct_params,
-                                     GObjectConstructParam  *construct_params)
+static void
+gimp_filtered_container_constructed (GObject *object)
 {
-  GObject               *object;
-  GimpFilteredContainer *filtered_container;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type,
-                                                       n_construct_params,
-                                                       construct_params);
+  GimpFilteredContainer *filtered_container = GIMP_FILTERED_CONTAINER (object);
 
-  filtered_container = GIMP_FILTERED_CONTAINER (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   filtered_container->tag_ref_counts =
     g_hash_table_new ((GHashFunc) gimp_tag_get_hash,
@@ -169,8 +160,6 @@ gimp_filtered_container_constructor (GType                   type,
                           (GFunc) gimp_filtered_container_tagged_item_added,
                           filtered_container);
   gimp_filtered_container_filter (filtered_container);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpfloatingselundo.c b/app/core/gimpfloatingselundo.c
index 2ea7cee..fb57731 100644
--- a/app/core/gimpfloatingselundo.c
+++ b/app/core/gimpfloatingselundo.c
@@ -29,13 +29,11 @@
 #include "gimplayer-floating-sel.h"
 
 
-static GObject * gimp_floating_sel_undo_constructor (GType                  type,
-                                                     guint                  n_params,
-                                                     GObjectConstructParam *params);
+static void   gimp_floating_sel_undo_constructed (GObject             *object);
 
-static void      gimp_floating_sel_undo_pop         (GimpUndo              *undo,
-                                                     GimpUndoMode           undo_mode,
-                                                     GimpUndoAccumulator   *accum);
+static void   gimp_floating_sel_undo_pop         (GimpUndo            *undo,
+                                                  GimpUndoMode         undo_mode,
+                                                  GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpFloatingSelUndo, gimp_floating_sel_undo, GIMP_TYPE_ITEM_UNDO)
@@ -49,7 +47,7 @@ gimp_floating_sel_undo_class_init (GimpFloatingSelUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor = gimp_floating_sel_undo_constructor;
+  object_class->constructed = gimp_floating_sel_undo_constructed;
 
   undo_class->pop           = gimp_floating_sel_undo_pop;
 }
@@ -59,18 +57,14 @@ gimp_floating_sel_undo_init (GimpFloatingSelUndo *undo)
 {
 }
 
-static GObject *
-gimp_floating_sel_undo_constructor (GType                  type,
-                                    guint                  n_params,
-                                    GObjectConstructParam *params)
+static void
+gimp_floating_sel_undo_constructed (GObject *object)
 {
-  GObject             *object;
-  GimpFloatingSelUndo *floating_sel_undo;
+  GimpFloatingSelUndo *floating_sel_undo = GIMP_FLOATING_SEL_UNDO (object);
   GimpLayer           *layer;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  floating_sel_undo = GIMP_FLOATING_SEL_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_LAYER (GIMP_ITEM_UNDO (object)->item));
 
@@ -85,8 +79,6 @@ gimp_floating_sel_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpgrouplayerundo.c b/app/core/gimpgrouplayerundo.c
index b7c199b..6256e06 100644
--- a/app/core/gimpgrouplayerundo.c
+++ b/app/core/gimpgrouplayerundo.c
@@ -26,13 +26,11 @@
 #include "gimpgrouplayerundo.h"
 
 
-static GObject * gimp_group_layer_undo_constructor (GType                  type,
-                                                    guint                  n_params,
-                                                    GObjectConstructParam *params);
+static void   gimp_group_layer_undo_constructed (GObject             *object);
 
-static void      gimp_group_layer_undo_pop         (GimpUndo              *undo,
-                                                    GimpUndoMode           undo_mode,
-                                                    GimpUndoAccumulator   *accum);
+static void   gimp_group_layer_undo_pop         (GimpUndo            *undo,
+                                                 GimpUndoMode         undo_mode,
+                                                 GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpGroupLayerUndo, gimp_group_layer_undo, GIMP_TYPE_ITEM_UNDO)
@@ -46,7 +44,7 @@ gimp_group_layer_undo_class_init (GimpGroupLayerUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor   = gimp_group_layer_undo_constructor;
+  object_class->constructed   = gimp_group_layer_undo_constructed;
 
   undo_class->pop             = gimp_group_layer_undo_pop;
 }
@@ -56,18 +54,14 @@ gimp_group_layer_undo_init (GimpGroupLayerUndo *undo)
 {
 }
 
-static GObject *
-gimp_group_layer_undo_constructor (GType                  type,
-                                   guint                  n_params,
-                                   GObjectConstructParam *params)
+static void
+gimp_group_layer_undo_constructed (GObject *object)
 {
-  GObject            *object;
-  GimpGroupLayerUndo *group_layer_undo;
+  GimpGroupLayerUndo *group_layer_undo = GIMP_GROUP_LAYER_UNDO (object);
   GimpGroupLayer     *group;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  group_layer_undo = GIMP_GROUP_LAYER_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GROUP_LAYER (GIMP_ITEM_UNDO (object)->item));
 
@@ -86,8 +80,6 @@ gimp_group_layer_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpguideundo.c b/app/core/gimpguideundo.c
index 6e16b75..c07d49b 100644
--- a/app/core/gimpguideundo.c
+++ b/app/core/gimpguideundo.c
@@ -34,23 +34,21 @@ enum
 };
 
 
-static GObject * gimp_guide_undo_constructor  (GType                  type,
-                                               guint                  n_params,
-                                               GObjectConstructParam *params);
-static void      gimp_guide_undo_set_property (GObject               *object,
-                                               guint                  property_id,
-                                               const GValue          *value,
-                                               GParamSpec            *pspec);
-static void      gimp_guide_undo_get_property (GObject               *object,
-                                               guint                  property_id,
-                                               GValue                *value,
-                                               GParamSpec            *pspec);
-
-static void      gimp_guide_undo_pop          (GimpUndo              *undo,
-                                               GimpUndoMode           undo_mode,
-                                               GimpUndoAccumulator   *accum);
-static void      gimp_guide_undo_free         (GimpUndo              *undo,
-                                               GimpUndoMode           undo_mode);
+static void   gimp_guide_undo_constructed  (GObject            *object);
+static void   gimp_guide_undo_set_property (GObject             *object,
+                                            guint                property_id,
+                                            const GValue        *value,
+                                            GParamSpec          *pspec);
+static void   gimp_guide_undo_get_property (GObject             *object,
+                                            guint                property_id,
+                                            GValue              *value,
+                                            GParamSpec          *pspec);
+
+static void   gimp_guide_undo_pop          (GimpUndo            *undo,
+                                            GimpUndoMode         undo_mode,
+                                            GimpUndoAccumulator *accum);
+static void   gimp_guide_undo_free         (GimpUndo            *undo,
+                                            GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpGuideUndo, gimp_guide_undo, GIMP_TYPE_UNDO)
@@ -64,7 +62,7 @@ gimp_guide_undo_class_init (GimpGuideUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor  = gimp_guide_undo_constructor;
+  object_class->constructed  = gimp_guide_undo_constructed;
   object_class->set_property = gimp_guide_undo_set_property;
   object_class->get_property = gimp_guide_undo_get_property;
 
@@ -83,24 +81,18 @@ gimp_guide_undo_init (GimpGuideUndo *undo)
 {
 }
 
-static GObject *
-gimp_guide_undo_constructor (GType                  type,
-                             guint                  n_params,
-                             GObjectConstructParam *params)
+static void
+gimp_guide_undo_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpGuideUndo *guide_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpGuideUndo *guide_undo = GIMP_GUIDE_UNDO (object);
 
-  guide_undo = GIMP_GUIDE_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GUIDE (guide_undo->guide));
 
   guide_undo->orientation = gimp_guide_get_orientation (guide_undo->guide);
   guide_undo->position    = gimp_guide_get_position (guide_undo->guide);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpimage.c b/app/core/gimpimage.c
index b9cb133..011ac74 100644
--- a/app/core/gimpimage.c
+++ b/app/core/gimpimage.c
@@ -128,9 +128,7 @@ enum
 static void     gimp_color_managed_iface_init    (GimpColorManagedInterface *iface);
 static void     gimp_projectable_iface_init      (GimpProjectableInterface  *iface);
 
-static GObject *gimp_image_constructor           (GType              type,
-                                                  guint              n_params,
-                                                  GObjectConstructParam *params);
+static void     gimp_image_constructed           (GObject           *object);
 static void     gimp_image_set_property          (GObject           *object,
                                                   guint              property_id,
                                                   const GValue      *value,
@@ -510,7 +508,7 @@ gimp_image_class_init (GimpImageClass *klass)
                   GIMP_TYPE_UNDO_EVENT,
                   GIMP_TYPE_UNDO);
 
-  object_class->constructor           = gimp_image_constructor;
+  object_class->constructed           = gimp_image_constructed;
   object_class->set_property          = gimp_image_set_property;
   object_class->get_property          = gimp_image_get_property;
   object_class->dispose               = gimp_image_dispose;
@@ -730,20 +728,15 @@ gimp_image_init (GimpImage *image)
   private->flush_accum.preview_invalidated        = FALSE;
 }
 
-static GObject *
-gimp_image_constructor (GType                  type,
-                        guint                  n_params,
-                        GObjectConstructParam *params)
+static void
+gimp_image_constructed (GObject *object)
 {
-  GObject          *object;
-  GimpImage        *image;
-  GimpImagePrivate *private;
+  GimpImage        *image   = GIMP_IMAGE (object);
+  GimpImagePrivate *private = GIMP_IMAGE_GET_PRIVATE (image);
   GimpCoreConfig   *config;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  image   = GIMP_IMAGE (object);
-  private = GIMP_IMAGE_GET_PRIVATE (image);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GIMP (image->gimp));
 
@@ -793,8 +786,6 @@ gimp_image_constructor (GType                  type,
                            image, G_CONNECT_SWAPPED);
 
   gimp_container_add (image->gimp->images, GIMP_OBJECT (image));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpimageundo.c b/app/core/gimpimageundo.c
index e2d7841..74b69b7 100644
--- a/app/core/gimpimageundo.c
+++ b/app/core/gimpimageundo.c
@@ -50,26 +50,24 @@ enum
 };
 
 
-static GObject * gimp_image_undo_constructor  (GType                  type,
-                                               guint                  n_params,
-                                               GObjectConstructParam *params);
-static void      gimp_image_undo_set_property (GObject               *object,
-                                               guint                  property_id,
-                                               const GValue          *value,
-                                               GParamSpec            *pspec);
-static void      gimp_image_undo_get_property (GObject               *object,
-                                               guint                  property_id,
-                                               GValue                *value,
-                                               GParamSpec            *pspec);
-
-static gint64    gimp_image_undo_get_memsize  (GimpObject            *object,
-                                               gint64                *gui_size);
-
-static void      gimp_image_undo_pop          (GimpUndo              *undo,
-                                               GimpUndoMode           undo_mode,
-                                               GimpUndoAccumulator   *accum);
-static void      gimp_image_undo_free         (GimpUndo              *undo,
-                                               GimpUndoMode           undo_mode);
+static void     gimp_image_undo_constructed  (GObject             *object);
+static void     gimp_image_undo_set_property (GObject             *object,
+                                              guint                property_id,
+                                              const GValue        *value,
+                                              GParamSpec          *pspec);
+static void     gimp_image_undo_get_property (GObject             *object,
+                                              guint                property_id,
+                                              GValue              *value,
+                                              GParamSpec          *pspec);
+
+static gint64   gimp_image_undo_get_memsize  (GimpObject          *object,
+                                              gint64              *gui_size);
+
+static void     gimp_image_undo_pop          (GimpUndo            *undo,
+                                              GimpUndoMode         undo_mode,
+                                              GimpUndoAccumulator *accum);
+static void     gimp_image_undo_free         (GimpUndo            *undo,
+                                              GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpImageUndo, gimp_image_undo, GIMP_TYPE_UNDO)
@@ -84,7 +82,7 @@ gimp_image_undo_class_init (GimpImageUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_image_undo_constructor;
+  object_class->constructed      = gimp_image_undo_constructed;
   object_class->set_property     = gimp_image_undo_set_property;
   object_class->get_property     = gimp_image_undo_get_property;
 
@@ -144,18 +142,14 @@ gimp_image_undo_init (GimpImageUndo *undo)
 {
 }
 
-static GObject *
-gimp_image_undo_constructor (GType                  type,
-                             guint                  n_params,
-                             GObjectConstructParam *params)
+static void
+gimp_image_undo_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpImageUndo *image_undo;
+  GimpImageUndo *image_undo = GIMP_IMAGE_UNDO (object);
   GimpImage     *image;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  image_undo = GIMP_IMAGE_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   image = GIMP_UNDO (object)->image;
 
@@ -198,8 +192,6 @@ gimp_image_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpitempropundo.c b/app/core/gimpitempropundo.c
index 9a07905..8dd1b92 100644
--- a/app/core/gimpitempropundo.c
+++ b/app/core/gimpitempropundo.c
@@ -37,26 +37,24 @@ enum
 };
 
 
-static GObject * gimp_item_prop_undo_constructor  (GType                  type,
-                                                   guint                  n_params,
-                                                   GObjectConstructParam *params);
-static void      gimp_item_prop_undo_set_property (GObject               *object,
-                                                   guint                  property_id,
-                                                   const GValue          *value,
-                                                   GParamSpec            *pspec);
-static void      gimp_item_prop_undo_get_property (GObject               *object,
-                                                   guint                  property_id,
-                                                   GValue                *value,
-                                                   GParamSpec            *pspec);
-
-static gint64    gimp_item_prop_undo_get_memsize  (GimpObject            *object,
-                                                   gint64                *gui_size);
-
-static void      gimp_item_prop_undo_pop          (GimpUndo              *undo,
-                                                   GimpUndoMode           undo_mode,
-                                                   GimpUndoAccumulator   *accum);
-static void      gimp_item_prop_undo_free         (GimpUndo              *undo,
-                                                   GimpUndoMode           undo_mode);
+static void     gimp_item_prop_undo_constructed  (GObject             *object);
+static void     gimp_item_prop_undo_set_property (GObject             *object,
+                                                  guint                property_id,
+                                                  const GValue        *value,
+                                                  GParamSpec          *pspec);
+static void     gimp_item_prop_undo_get_property (GObject             *object,
+                                                  guint                property_id,
+                                                  GValue              *value,
+                                                  GParamSpec          *pspec);
+
+static gint64   gimp_item_prop_undo_get_memsize  (GimpObject          *object,
+                                                  gint64              *gui_size);
+
+static void     gimp_item_prop_undo_pop          (GimpUndo            *undo,
+                                                  GimpUndoMode         undo_mode,
+                                                  GimpUndoAccumulator *accum);
+static void     gimp_item_prop_undo_free         (GimpUndo            *undo,
+                                                  GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpItemPropUndo, gimp_item_prop_undo, GIMP_TYPE_ITEM_UNDO)
@@ -71,7 +69,7 @@ gimp_item_prop_undo_class_init (GimpItemPropUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_item_prop_undo_constructor;
+  object_class->constructed      = gimp_item_prop_undo_constructed;
   object_class->set_property     = gimp_item_prop_undo_set_property;
   object_class->get_property     = gimp_item_prop_undo_get_property;
 
@@ -93,18 +91,14 @@ gimp_item_prop_undo_init (GimpItemPropUndo *undo)
 {
 }
 
-static GObject *
-gimp_item_prop_undo_constructor (GType                  type,
-                                 guint                  n_params,
-                                 GObjectConstructParam *params)
+static void
+gimp_item_prop_undo_constructed (GObject *object)
 {
-  GObject          *object;
-  GimpItemPropUndo *item_prop_undo;
+  GimpItemPropUndo *item_prop_undo = GIMP_ITEM_PROP_UNDO (object);
   GimpItem         *item;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  item_prop_undo = GIMP_ITEM_PROP_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   item = GIMP_ITEM_UNDO (object)->item;
 
@@ -144,8 +138,6 @@ gimp_item_prop_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpitemstack.c b/app/core/gimpitemstack.c
index 0da89da..0277cbb 100644
--- a/app/core/gimpitemstack.c
+++ b/app/core/gimpitemstack.c
@@ -32,14 +32,12 @@
 
 /*  local function prototypes  */
 
-static GObject * gimp_item_stack_constructor (GType                  type,
-                                              guint                  n_params,
-                                              GObjectConstructParam *params);
+static void   gimp_item_stack_constructed (GObject       *object);
 
-static void      gimp_item_stack_add         (GimpContainer         *container,
-                                              GimpObject            *object);
-static void      gimp_item_stack_remove      (GimpContainer         *container,
-                                              GimpObject            *object);
+static void   gimp_item_stack_add         (GimpContainer *container,
+                                           GimpObject    *object);
+static void   gimp_item_stack_remove      (GimpContainer *container,
+                                           GimpObject    *object);
 
 
 G_DEFINE_TYPE (GimpItemStack, gimp_item_stack, GIMP_TYPE_LIST)
@@ -53,7 +51,7 @@ gimp_item_stack_class_init (GimpItemStackClass *klass)
   GObjectClass       *object_class    = G_OBJECT_CLASS (klass);
   GimpContainerClass *container_class = GIMP_CONTAINER_CLASS (klass);
 
-  object_class->constructor = gimp_item_stack_constructor;
+  object_class->constructed = gimp_item_stack_constructed;
 
   container_class->add      = gimp_item_stack_add;
   container_class->remove   = gimp_item_stack_remove;
@@ -64,22 +62,16 @@ gimp_item_stack_init (GimpItemStack *stack)
 {
 }
 
-static GObject *
-gimp_item_stack_constructor (GType                  type,
-                             guint                  n_params,
-                             GObjectConstructParam *params)
+static void
+gimp_item_stack_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpContainer *container;
+  GimpContainer *container = GIMP_CONTAINER (object);
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  container = GIMP_CONTAINER (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (g_type_is_a (gimp_container_get_children_type (container),
                          GIMP_TYPE_ITEM));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpitemtree.c b/app/core/gimpitemtree.c
index 78295e4..6000e82 100644
--- a/app/core/gimpitemtree.c
+++ b/app/core/gimpitemtree.c
@@ -66,25 +66,23 @@ struct _GimpItemTreePrivate
 
 /*  local function prototypes  */
 
-static GObject * gimp_item_tree_constructor   (GType                  type,
-                                               guint                  n_params,
-                                               GObjectConstructParam *params);
-static void      gimp_item_tree_finalize      (GObject               *object);
-static void      gimp_item_tree_set_property  (GObject               *object,
-                                               guint                  property_id,
-                                               const GValue          *value,
-                                               GParamSpec            *pspec);
-static void      gimp_item_tree_get_property  (GObject               *object,
-                                               guint                  property_id,
-                                               GValue                *value,
-                                               GParamSpec            *pspec);
-
-static gint64    gimp_item_tree_get_memsize   (GimpObject            *object,
-                                               gint64                *gui_size);
-
-static void      gimp_item_tree_uniquefy_name (GimpItemTree          *tree,
-                                               GimpItem              *item,
-                                               const gchar           *new_name);
+static void     gimp_item_tree_constructed   (GObject      *object);
+static void     gimp_item_tree_finalize      (GObject      *object);
+static void     gimp_item_tree_set_property  (GObject      *object,
+                                              guint         property_id,
+                                              const GValue *value,
+                                              GParamSpec   *pspec);
+static void     gimp_item_tree_get_property  (GObject      *object,
+                                              guint         property_id,
+                                              GValue       *value,
+                                              GParamSpec   *pspec);
+
+static gint64   gimp_item_tree_get_memsize   (GimpObject   *object,
+                                              gint64       *gui_size);
+
+static void     gimp_item_tree_uniquefy_name (GimpItemTree *tree,
+                                              GimpItem     *item,
+                                              const gchar  *new_name);
 
 
 G_DEFINE_TYPE (GimpItemTree, gimp_item_tree, GIMP_TYPE_OBJECT)
@@ -98,7 +96,7 @@ gimp_item_tree_class_init (GimpItemTreeClass *klass)
   GObjectClass    *object_class      = G_OBJECT_CLASS (klass);
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
 
-  object_class->constructor      = gimp_item_tree_constructor;
+  object_class->constructed      = gimp_item_tree_constructed;
   object_class->finalize         = gimp_item_tree_finalize;
   object_class->set_property     = gimp_item_tree_set_property;
   object_class->get_property     = gimp_item_tree_get_property;
@@ -143,19 +141,14 @@ gimp_item_tree_init (GimpItemTree *tree)
   private->name_hash = g_hash_table_new (g_str_hash, g_str_equal);
 }
 
-static GObject *
-gimp_item_tree_constructor (GType                  type,
-                            guint                  n_params,
-                            GObjectConstructParam *params)
+static void
+gimp_item_tree_constructed (GObject *object)
 {
-  GObject             *object;
-  GimpItemTree        *tree;
-  GimpItemTreePrivate *private;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpItemTree        *tree    = GIMP_ITEM_TREE (object);
+  GimpItemTreePrivate *private = GIMP_ITEM_TREE_GET_PRIVATE (tree);
 
-  tree    = GIMP_ITEM_TREE (object);
-  private = GIMP_ITEM_TREE_GET_PRIVATE (tree);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_IMAGE (private->image));
   g_assert (g_type_is_a (private->container_type, GIMP_TYPE_ITEM_STACK));
@@ -167,8 +160,6 @@ gimp_item_tree_constructor (GType                  type,
                                   "children-type", private->item_type,
                                   "policy",        GIMP_CONTAINER_POLICY_STRONG,
                                   NULL);
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpitemundo.c b/app/core/gimpitemundo.c
index 0a1f08c..e022b96 100644
--- a/app/core/gimpitemundo.c
+++ b/app/core/gimpitemundo.c
@@ -33,20 +33,18 @@ enum
 };
 
 
-static GObject * gimp_item_undo_constructor  (GType                  type,
-                                              guint                  n_params,
-                                              GObjectConstructParam *params);
-static void      gimp_item_undo_set_property (GObject               *object,
-                                              guint                  property_id,
-                                              const GValue          *value,
-                                              GParamSpec            *pspec);
-static void      gimp_item_undo_get_property (GObject               *object,
-                                              guint                  property_id,
-                                              GValue                *value,
-                                              GParamSpec            *pspec);
-
-static void      gimp_item_undo_free         (GimpUndo              *undo,
-                                              GimpUndoMode           undo_mode);
+static void   gimp_item_undo_constructed  (GObject      *object);
+static void   gimp_item_undo_set_property (GObject      *object,
+                                           guint         property_id,
+                                           const GValue *value,
+                                           GParamSpec   *pspec);
+static void   gimp_item_undo_get_property (GObject      *object,
+                                           guint         property_id,
+                                           GValue       *value,
+                                           GParamSpec   *pspec);
+
+static void   gimp_item_undo_free         (GimpUndo     *undo,
+                                           GimpUndoMode  undo_mode);
 
 
 G_DEFINE_TYPE (GimpItemUndo, gimp_item_undo, GIMP_TYPE_UNDO)
@@ -60,7 +58,7 @@ gimp_item_undo_class_init (GimpItemUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor  = gimp_item_undo_constructor;
+  object_class->constructed  = gimp_item_undo_constructed;
   object_class->set_property = gimp_item_undo_set_property;
   object_class->get_property = gimp_item_undo_get_property;
 
@@ -78,21 +76,15 @@ gimp_item_undo_init (GimpItemUndo *undo)
 {
 }
 
-static GObject *
-gimp_item_undo_constructor (GType                  type,
-                            guint                  n_params,
-                            GObjectConstructParam *params)
+static void
+gimp_item_undo_constructed (GObject *object)
 {
-  GObject      *object;
-  GimpItemUndo *item_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpItemUndo *item_undo = GIMP_ITEM_UNDO (object);
 
-  item_undo = GIMP_ITEM_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_ITEM (item_undo->item));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimplayermaskpropundo.c b/app/core/gimplayermaskpropundo.c
index b827c17..87bdd1d 100644
--- a/app/core/gimplayermaskpropundo.c
+++ b/app/core/gimplayermaskpropundo.c
@@ -25,13 +25,11 @@
 #include "gimplayermaskpropundo.h"
 
 
-static GObject * gimp_layer_mask_prop_undo_constructor (GType                  type,
-                                                        guint                  n_params,
-                                                        GObjectConstructParam *params);
+static void   gimp_layer_mask_prop_undo_constructed (GObject             *object);
 
-static void      gimp_layer_mask_prop_undo_pop         (GimpUndo              *undo,
-                                                        GimpUndoMode           undo_mode,
-                                                        GimpUndoAccumulator   *accum);
+static void   gimp_layer_mask_prop_undo_pop         (GimpUndo            *undo,
+                                                     GimpUndoMode         undo_mode,
+                                                     GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpLayerMaskPropUndo, gimp_layer_mask_prop_undo,
@@ -46,7 +44,7 @@ gimp_layer_mask_prop_undo_class_init (GimpLayerMaskPropUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor = gimp_layer_mask_prop_undo_constructor;
+  object_class->constructed = gimp_layer_mask_prop_undo_constructed;
 
   undo_class->pop           = gimp_layer_mask_prop_undo_pop;
 }
@@ -56,19 +54,17 @@ gimp_layer_mask_prop_undo_init (GimpLayerMaskPropUndo *undo)
 {
 }
 
-static GObject *
-gimp_layer_mask_prop_undo_constructor (GType                  type,
-                                       guint                  n_params,
-                                       GObjectConstructParam *params)
+static void
+gimp_layer_mask_prop_undo_constructed (GObject *object)
 {
-  GObject               *object;
   GimpLayerMaskPropUndo *layer_mask_prop_undo;
   GimpLayerMask         *layer_mask;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
   layer_mask_prop_undo = GIMP_LAYER_MASK_PROP_UNDO (object);
 
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
+
   g_assert (GIMP_IS_LAYER_MASK (GIMP_ITEM_UNDO (object)->item));
 
   layer_mask = GIMP_LAYER_MASK (GIMP_ITEM_UNDO (object)->item);
@@ -86,8 +82,6 @@ gimp_layer_mask_prop_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimplayermaskundo.c b/app/core/gimplayermaskundo.c
index c791bff..df88c45 100644
--- a/app/core/gimplayermaskundo.c
+++ b/app/core/gimplayermaskundo.c
@@ -34,26 +34,24 @@ enum
 };
 
 
-static GObject * gimp_layer_mask_undo_constructor  (GType                  type,
-                                                    guint                  n_params,
-                                                    GObjectConstructParam *params);
-static void      gimp_layer_mask_undo_set_property (GObject               *object,
-                                                    guint                  property_id,
-                                                    const GValue          *value,
-                                                    GParamSpec            *pspec);
-static void      gimp_layer_mask_undo_get_property (GObject               *object,
-                                                    guint                  property_id,
-                                                    GValue                *value,
-                                                    GParamSpec            *pspec);
-
-static gint64    gimp_layer_mask_undo_get_memsize  (GimpObject            *object,
-                                                    gint64                *gui_size);
-
-static void      gimp_layer_mask_undo_pop          (GimpUndo              *undo,
-                                                    GimpUndoMode           undo_mode,
-                                                    GimpUndoAccumulator   *accum);
-static void      gimp_layer_mask_undo_free         (GimpUndo              *undo,
-                                                    GimpUndoMode           undo_mode);
+static void     gimp_layer_mask_undo_constructed  (GObject             *object);
+static void     gimp_layer_mask_undo_set_property (GObject             *object,
+                                                   guint                property_id,
+                                                   const GValue        *value,
+                                                   GParamSpec          *pspec);
+static void     gimp_layer_mask_undo_get_property (GObject             *object,
+                                                   guint                property_id,
+                                                   GValue              *value,
+                                                   GParamSpec          *pspec);
+
+static gint64   gimp_layer_mask_undo_get_memsize  (GimpObject          *object,
+                                                   gint64              *gui_size);
+
+static void     gimp_layer_mask_undo_pop          (GimpUndo            *undo,
+                                                   GimpUndoMode         undo_mode,
+                                                   GimpUndoAccumulator *accum);
+static void     gimp_layer_mask_undo_free         (GimpUndo            *undo,
+                                                   GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpLayerMaskUndo, gimp_layer_mask_undo, GIMP_TYPE_ITEM_UNDO)
@@ -68,7 +66,7 @@ gimp_layer_mask_undo_class_init (GimpLayerMaskUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_layer_mask_undo_constructor;
+  object_class->constructed      = gimp_layer_mask_undo_constructed;
   object_class->set_property     = gimp_layer_mask_undo_set_property;
   object_class->get_property     = gimp_layer_mask_undo_get_property;
 
@@ -89,22 +87,16 @@ gimp_layer_mask_undo_init (GimpLayerMaskUndo *undo)
 {
 }
 
-static GObject *
-gimp_layer_mask_undo_constructor (GType                  type,
-                                  guint                  n_params,
-                                  GObjectConstructParam *params)
+static void
+gimp_layer_mask_undo_constructed (GObject *object)
 {
-  GObject           *object;
-  GimpLayerMaskUndo *layer_mask_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpLayerMaskUndo *layer_mask_undo = GIMP_LAYER_MASK_UNDO (object);
 
-  layer_mask_undo = GIMP_LAYER_MASK_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_LAYER (GIMP_ITEM_UNDO (object)->item));
   g_assert (GIMP_IS_LAYER_MASK (layer_mask_undo->layer_mask));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimplayerpropundo.c b/app/core/gimplayerpropundo.c
index 8326466..d27876c 100644
--- a/app/core/gimplayerpropundo.c
+++ b/app/core/gimplayerpropundo.c
@@ -28,13 +28,11 @@
 #include "gimplayerpropundo.h"
 
 
-static GObject * gimp_layer_prop_undo_constructor (GType                  type,
-                                                   guint                  n_params,
-                                                   GObjectConstructParam *params);
+static void   gimp_layer_prop_undo_constructed (GObject             *object);
 
-static void      gimp_layer_prop_undo_pop         (GimpUndo              *undo,
-                                                   GimpUndoMode           undo_mode,
-                                                   GimpUndoAccumulator   *accum);
+static void   gimp_layer_prop_undo_pop         (GimpUndo            *undo,
+                                                GimpUndoMode         undo_mode,
+                                                GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpLayerPropUndo, gimp_layer_prop_undo, GIMP_TYPE_ITEM_UNDO)
@@ -48,7 +46,7 @@ gimp_layer_prop_undo_class_init (GimpLayerPropUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor = gimp_layer_prop_undo_constructor;
+  object_class->constructed = gimp_layer_prop_undo_constructed;
 
   undo_class->pop           = gimp_layer_prop_undo_pop;
 }
@@ -58,19 +56,15 @@ gimp_layer_prop_undo_init (GimpLayerPropUndo *undo)
 {
 }
 
-static GObject *
-gimp_layer_prop_undo_constructor (GType                  type,
-                                  guint                  n_params,
-                                  GObjectConstructParam *params)
+static void
+gimp_layer_prop_undo_constructed (GObject *object)
 {
-  GObject           *object;
-  GimpLayerPropUndo *layer_prop_undo;
+  GimpLayerPropUndo *layer_prop_undo = GIMP_LAYER_PROP_UNDO (object);
   GimpImage         *image;
   GimpLayer         *layer;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  layer_prop_undo = GIMP_LAYER_PROP_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_LAYER (GIMP_ITEM_UNDO (object)->item));
 
@@ -94,8 +88,6 @@ gimp_layer_prop_undo_constructor (GType                  type,
     default:
       g_assert_not_reached ();
     }
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimplayerundo.c b/app/core/gimplayerundo.c
index c817ac7..3525d88 100644
--- a/app/core/gimplayerundo.c
+++ b/app/core/gimplayerundo.c
@@ -35,24 +35,22 @@ enum
 };
 
 
-static GObject * gimp_layer_undo_constructor  (GType                  type,
-                                               guint                  n_params,
-                                               GObjectConstructParam *params);
-static void      gimp_layer_undo_set_property (GObject               *object,
-                                               guint                  property_id,
-                                               const GValue          *value,
-                                               GParamSpec            *pspec);
-static void      gimp_layer_undo_get_property (GObject               *object,
-                                               guint                  property_id,
-                                               GValue                *value,
-                                               GParamSpec            *pspec);
-
-static gint64    gimp_layer_undo_get_memsize  (GimpObject            *object,
-                                               gint64                *gui_size);
-
-static void      gimp_layer_undo_pop          (GimpUndo              *undo,
-                                               GimpUndoMode           undo_mode,
-                                               GimpUndoAccumulator   *accum);
+static void     gimp_layer_undo_constructed  (GObject             *object);
+static void     gimp_layer_undo_set_property (GObject             *object,
+                                              guint                property_id,
+                                              const GValue        *value,
+                                              GParamSpec          *pspec);
+static void     gimp_layer_undo_get_property (GObject             *object,
+                                              guint                property_id,
+                                              GValue              *value,
+                                              GParamSpec          *pspec);
+
+static gint64   gimp_layer_undo_get_memsize  (GimpObject          *object,
+                                              gint64              *gui_size);
+
+static void     gimp_layer_undo_pop          (GimpUndo            *undo,
+                                              GimpUndoMode         undo_mode,
+                                              GimpUndoAccumulator *accum);
 
 
 G_DEFINE_TYPE (GimpLayerUndo, gimp_layer_undo, GIMP_TYPE_ITEM_UNDO)
@@ -67,7 +65,7 @@ gimp_layer_undo_class_init (GimpLayerUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_layer_undo_constructor;
+  object_class->constructed      = gimp_layer_undo_constructed;
   object_class->set_property     = gimp_layer_undo_set_property;
   object_class->get_property     = gimp_layer_undo_get_property;
 
@@ -100,21 +98,13 @@ gimp_layer_undo_init (GimpLayerUndo *undo)
 {
 }
 
-static GObject *
-gimp_layer_undo_constructor (GType                  type,
-                             guint                  n_params,
-                             GObjectConstructParam *params)
+static void
+gimp_layer_undo_constructed (GObject *object)
 {
-  GObject       *object;
-  GimpLayerUndo *layer_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  layer_undo = GIMP_LAYER_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_LAYER (GIMP_ITEM_UNDO (object)->item));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpmaskundo.c b/app/core/gimpmaskundo.c
index 11739d7..c77a95f 100644
--- a/app/core/gimpmaskundo.c
+++ b/app/core/gimpmaskundo.c
@@ -30,18 +30,16 @@
 #include "gimpmaskundo.h"
 
 
-static GObject * gimp_mask_undo_constructor (GType                  type,
-                                             guint                  n_params,
-                                             GObjectConstructParam *params);
+static void     gimp_mask_undo_constructed (GObject             *object);
 
-static gint64    gimp_mask_undo_get_memsize (GimpObject            *object,
-                                             gint64                *gui_size);
+static gint64   gimp_mask_undo_get_memsize (GimpObject          *object,
+                                            gint64              *gui_size);
 
-static void      gimp_mask_undo_pop         (GimpUndo              *undo,
-                                             GimpUndoMode           undo_mode,
-                                             GimpUndoAccumulator   *accum);
-static void      gimp_mask_undo_free        (GimpUndo              *undo,
-                                             GimpUndoMode           undo_mode);
+static void     gimp_mask_undo_pop         (GimpUndo            *undo,
+                                            GimpUndoMode         undo_mode,
+                                            GimpUndoAccumulator *accum);
+static void     gimp_mask_undo_free        (GimpUndo            *undo,
+                                            GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpMaskUndo, gimp_mask_undo, GIMP_TYPE_ITEM_UNDO)
@@ -56,7 +54,7 @@ gimp_mask_undo_class_init (GimpMaskUndoClass *klass)
   GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
   GimpUndoClass   *undo_class        = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor      = gimp_mask_undo_constructor;
+  object_class->constructed      = gimp_mask_undo_constructed;
 
   gimp_object_class->get_memsize = gimp_mask_undo_get_memsize;
 
@@ -69,19 +67,15 @@ gimp_mask_undo_init (GimpMaskUndo *undo)
 {
 }
 
-static GObject *
-gimp_mask_undo_constructor (GType                  type,
-                            guint                  n_params,
-                            GObjectConstructParam *params)
+static void
+gimp_mask_undo_constructed (GObject *object)
 {
-  GObject      *object;
-  GimpMaskUndo *mask_undo;
+  GimpMaskUndo *mask_undo = GIMP_MASK_UNDO (object);
   GimpChannel  *channel;
   gint          x1, y1, x2, y2;
 
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
-
-  mask_undo = GIMP_MASK_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_CHANNEL (GIMP_ITEM_UNDO (object)->item));
 
@@ -104,8 +98,6 @@ gimp_mask_undo_constructor (GType                  type,
 
       copy_region (&srcPR, &destPR);
     }
-
-  return object;
 }
 
 static gint64
diff --git a/app/core/gimppatternclipboard.c b/app/core/gimppatternclipboard.c
index 0e5a99b..990a50d 100644
--- a/app/core/gimppatternclipboard.c
+++ b/app/core/gimppatternclipboard.c
@@ -47,9 +47,7 @@ enum
 
 /*  local function prototypes  */
 
-static GObject  * gimp_pattern_clipboard_constructor  (GType         type,
-                                                       guint         n_params,
-                                                       GObjectConstructParam *params);
+static void       gimp_pattern_clipboard_constructed  (GObject      *object);
 static void       gimp_pattern_clipboard_set_property (GObject      *object,
                                                        guint         property_id,
                                                        const GValue *value,
@@ -79,7 +77,7 @@ gimp_pattern_clipboard_class_init (GimpPatternClipboardClass *klass)
   GimpDataClass *data_class   = GIMP_DATA_CLASS (klass);
 #endif
 
-  object_class->constructor  = gimp_pattern_clipboard_constructor;
+  object_class->constructed  = gimp_pattern_clipboard_constructed;
   object_class->set_property = gimp_pattern_clipboard_set_property;
   object_class->get_property = gimp_pattern_clipboard_get_property;
 
@@ -100,17 +98,13 @@ gimp_pattern_clipboard_init (GimpPatternClipboard *pattern)
   pattern->gimp = NULL;
 }
 
-static GObject *
-gimp_pattern_clipboard_constructor (GType                  type,
-                                    guint                  n_params,
-                                    GObjectConstructParam *params)
+static void
+gimp_pattern_clipboard_constructed (GObject *object)
 {
-  GObject              *object;
-  GimpPatternClipboard *pattern;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpPatternClipboard *pattern = GIMP_PATTERN_CLIPBOARD (object);
 
-  pattern = GIMP_PATTERN_CLIPBOARD (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GIMP (pattern->gimp));
 
@@ -119,8 +113,6 @@ gimp_pattern_clipboard_constructor (GType                  type,
                            pattern, 0);
 
   gimp_pattern_clipboard_buffer_changed (pattern->gimp, GIMP_PATTERN (pattern));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimppdbprogress.c b/app/core/gimppdbprogress.c
index 0e4c89a..269826c 100644
--- a/app/core/gimppdbprogress.c
+++ b/app/core/gimppdbprogress.c
@@ -52,9 +52,7 @@ static void      gimp_pdb_progress_init           (GimpPdbProgress      *progres
                                                    GimpPdbProgressClass *klass);
 static void gimp_pdb_progress_progress_iface_init (GimpProgressInterface *iface);
 
-static GObject * gimp_pdb_progress_constructor    (GType               type,
-                                                   guint               n_params,
-                                                   GObjectConstructParam *params);
+static void      gimp_pdb_progress_constructed    (GObject            *object);
 static void      gimp_pdb_progress_dispose        (GObject            *object);
 static void      gimp_pdb_progress_finalize       (GObject            *object);
 static void      gimp_pdb_progress_set_property   (GObject            *object,
@@ -124,7 +122,7 @@ gimp_pdb_progress_class_init (GimpPdbProgressClass *klass)
 
   parent_class = g_type_class_peek_parent (klass);
 
-  object_class->constructor  = gimp_pdb_progress_constructor;
+  object_class->constructed  = gimp_pdb_progress_constructed;
   object_class->dispose      = gimp_pdb_progress_dispose;
   object_class->finalize     = gimp_pdb_progress_finalize;
   object_class->set_property = gimp_pdb_progress_set_property;
@@ -169,22 +167,16 @@ gimp_pdb_progress_progress_iface_init (GimpProgressInterface *iface)
   iface->get_window = gimp_pdb_progress_progress_get_window;
 }
 
-static GObject *
-gimp_pdb_progress_constructor (GType                  type,
-                               guint                  n_params,
-                               GObjectConstructParam *params)
+static void
+gimp_pdb_progress_constructed (GObject *object)
 {
-  GObject         *object;
-  GimpPdbProgress *progress;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpPdbProgress *progress = GIMP_PDB_PROGRESS (object);
 
-  progress = GIMP_PDB_PROGRESS (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_PDB (progress->pdb));
   g_assert (GIMP_IS_CONTEXT (progress->context));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpsamplepointundo.c b/app/core/gimpsamplepointundo.c
index a2a426a..7cc4f80 100644
--- a/app/core/gimpsamplepointundo.c
+++ b/app/core/gimpsamplepointundo.c
@@ -34,23 +34,21 @@ enum
 };
 
 
-static GObject * gimp_sample_point_undo_constructor  (GType                  type,
-                                                      guint                  n_params,
-                                                      GObjectConstructParam *params);
-static void      gimp_sample_point_undo_set_property (GObject               *object,
-                                                      guint                  property_id,
-                                                      const GValue          *value,
-                                                      GParamSpec            *pspec);
-static void      gimp_sample_point_undo_get_property (GObject               *object,
-                                                      guint                  property_id,
-                                                      GValue                *value,
-                                                      GParamSpec            *pspec);
-
-static void      gimp_sample_point_undo_pop          (GimpUndo              *undo,
-                                                      GimpUndoMode           undo_mode,
-                                                      GimpUndoAccumulator   *accum);
-static void      gimp_sample_point_undo_free         (GimpUndo              *undo,
-                                                      GimpUndoMode           undo_mode);
+static void   gimp_sample_point_undo_constructed  (GObject             *object);
+static void   gimp_sample_point_undo_set_property (GObject             *object,
+                                                   guint                property_id,
+                                                   const GValue        *value,
+                                                   GParamSpec          *pspec);
+static void   gimp_sample_point_undo_get_property (GObject             *object,
+                                                   guint                property_id,
+                                                   GValue              *value,
+                                                   GParamSpec          *pspec);
+
+static void   gimp_sample_point_undo_pop          (GimpUndo            *undo,
+                                                   GimpUndoMode         undo_mode,
+                                                   GimpUndoAccumulator *accum);
+static void   gimp_sample_point_undo_free         (GimpUndo            *undo,
+                                                   GimpUndoMode         undo_mode);
 
 
 G_DEFINE_TYPE (GimpSamplePointUndo, gimp_sample_point_undo, GIMP_TYPE_UNDO)
@@ -64,7 +62,7 @@ gimp_sample_point_undo_class_init (GimpSamplePointUndoClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpUndoClass *undo_class   = GIMP_UNDO_CLASS (klass);
 
-  object_class->constructor  = gimp_sample_point_undo_constructor;
+  object_class->constructed  = gimp_sample_point_undo_constructed;
   object_class->set_property = gimp_sample_point_undo_set_property;
   object_class->get_property = gimp_sample_point_undo_get_property;
 
@@ -83,24 +81,18 @@ gimp_sample_point_undo_init (GimpSamplePointUndo *undo)
 {
 }
 
-static GObject *
-gimp_sample_point_undo_constructor (GType                  type,
-                                    guint                  n_params,
-                                    GObjectConstructParam *params)
+static void
+gimp_sample_point_undo_constructed (GObject *object)
 {
-  GObject             *object;
-  GimpSamplePointUndo *sample_point_undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpSamplePointUndo *sample_point_undo = GIMP_SAMPLE_POINT_UNDO (object);
 
-  sample_point_undo = GIMP_SAMPLE_POINT_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (sample_point_undo->sample_point != NULL);
 
   sample_point_undo->x = sample_point_undo->sample_point->x;
   sample_point_undo->y = sample_point_undo->sample_point->y;
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimptoolpreset.c b/app/core/gimptoolpreset.c
index 42221d5..edc88b6 100644
--- a/app/core/gimptoolpreset.c
+++ b/app/core/gimptoolpreset.c
@@ -60,9 +60,7 @@ enum
 
 static void        gimp_tool_preset_config_iface_init (GimpConfigInterface *iface);
 
-static GObject       * gimp_tool_preset_constructor   (GType         type,
-                                                       guint         n_params,
-                                                       GObjectConstructParam *params);
+static void            gimp_tool_preset_constructed   (GObject      *object);
 static void            gimp_tool_preset_finalize      (GObject      *object);
 static void            gimp_tool_preset_set_property  (GObject      *object,
                                                        guint         property_id,
@@ -100,7 +98,7 @@ gimp_tool_preset_class_init (GimpToolPresetClass *klass)
   GObjectClass  *object_class = G_OBJECT_CLASS (klass);
   GimpDataClass *data_class   = GIMP_DATA_CLASS (klass);
 
-  object_class->constructor                 = gimp_tool_preset_constructor;
+  object_class->constructed                 = gimp_tool_preset_constructed;
   object_class->finalize                    = gimp_tool_preset_finalize;
   object_class->set_property                = gimp_tool_preset_set_property;
   object_class->get_property                = gimp_tool_preset_get_property;
@@ -168,21 +166,15 @@ gimp_tool_preset_init (GimpToolPreset *tool_preset)
   tool_preset->tool_options = NULL;
 }
 
-static GObject *
-gimp_tool_preset_constructor (GType                  type,
-                              guint                  n_params,
-                              GObjectConstructParam *params)
+static void
+gimp_tool_preset_constructed (GObject *object)
 {
-  GObject        *object;
-  GimpToolPreset *preset;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpToolPreset *preset = GIMP_TOOL_PRESET (object);
 
-  preset = GIMP_TOOL_PRESET (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_GIMP (preset->gimp));
-
-  return object;
 }
 
 static void
diff --git a/app/core/gimpundo.c b/app/core/gimpundo.c
index 7ccf636..79af2d7 100644
--- a/app/core/gimpundo.c
+++ b/app/core/gimpundo.c
@@ -57,9 +57,7 @@ enum
 };
 
 
-static GObject * gimp_undo_constructor         (GType                type,
-                                                guint                n_params,
-                                                GObjectConstructParam *params);
+static void      gimp_undo_constructed         (GObject             *object);
 static void      gimp_undo_finalize            (GObject             *object);
 static void      gimp_undo_set_property        (GObject             *object,
                                                 guint                property_id,
@@ -130,7 +128,7 @@ gimp_undo_class_init (GimpUndoClass *klass)
                   G_TYPE_NONE, 1,
                   GIMP_TYPE_UNDO_MODE);
 
-  object_class->constructor        = gimp_undo_constructor;
+  object_class->constructed        = gimp_undo_constructed;
   object_class->finalize           = gimp_undo_finalize;
   object_class->set_property       = gimp_undo_set_property;
   object_class->get_property       = gimp_undo_get_property;
@@ -177,21 +175,15 @@ gimp_undo_init (GimpUndo *undo)
   undo->time = time (NULL);
 }
 
-static GObject *
-gimp_undo_constructor (GType                  type,
-                       guint                  n_params,
-                       GObjectConstructParam *params)
+static void
+gimp_undo_constructed (GObject *object)
 {
-  GObject  *object;
-  GimpUndo *undo;
-
-  object = G_OBJECT_CLASS (parent_class)->constructor (type, n_params, params);
+  GimpUndo *undo = GIMP_UNDO (object);
 
-  undo = GIMP_UNDO (object);
+  if (G_OBJECT_CLASS (parent_class)->constructed)
+    G_OBJECT_CLASS (parent_class)->constructed (object);
 
   g_assert (GIMP_IS_IMAGE (undo->image));
-
-  return object;
 }
 
 static void



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]