gegl r3022 - in trunk: . gegl gegl/operation operations/affine operations/common operations/core operations/workshop



Author: martinn
Date: Sat Apr 11 07:50:07 2009
New Revision: 3022
URL: http://svn.gnome.org/viewvc/gegl?rev=3022&view=rev

Log:
Rename gegl_operation_context_set_object() to _take_object()

Rename gegl_operation_context_set_object() to
gegl_operation_context_take_object() so its semantics are reflected in
the name.

Modified:
   trunk/ChangeLog
   trunk/gegl/gegl-plugin.h
   trunk/gegl/operation/gegl-operation-context.c
   trunk/gegl/operation/gegl-operation-context.h
   trunk/gegl/operation/gegl-operation.c
   trunk/operations/affine/affine.c
   trunk/operations/common/buffer-source.c
   trunk/operations/common/introspect.c
   trunk/operations/common/magick-load.c
   trunk/operations/common/open-buffer.c
   trunk/operations/common/raw-load.c
   trunk/operations/core/clone.c
   trunk/operations/core/crop.c
   trunk/operations/core/nop.c
   trunk/operations/workshop/rawbayer-load.c

Modified: trunk/gegl/gegl-plugin.h
==============================================================================
--- trunk/gegl/gegl-plugin.h	(original)
+++ trunk/gegl/gegl-plugin.h	Sat Apr 11 07:50:07 2009
@@ -75,7 +75,7 @@
                                                    const gchar          *padname);
 GeglBuffer     *gegl_operation_context_get_target (GeglOperationContext *self,
                                                    const gchar          *padname);
-void            gegl_operation_context_set_object (GeglOperationContext *context,
+void            gegl_operation_context_take_object(GeglOperationContext *context,
                                                    const gchar          *padname,
                                                    GObject              *data);
 

Modified: trunk/gegl/operation/gegl-operation-context.c
==============================================================================
--- trunk/gegl/operation/gegl-operation-context.c	(original)
+++ trunk/gegl/operation/gegl-operation-context.c	Sat Apr 11 07:50:07 2009
@@ -238,9 +238,9 @@
 
 
 void
-gegl_operation_context_set_object (GeglOperationContext *context,
-                                   const gchar          *padname,
-                                   GObject              *data)
+gegl_operation_context_take_object (GeglOperationContext *context,
+                                    const gchar          *padname,
+                                    GObject              *data)
 {
   GParamSpec *pspec;
 
@@ -379,7 +379,7 @@
       output = gegl_buffer_new_ram (result, format);
     }
 
-  gegl_operation_context_set_object (context, padname, G_OBJECT (output));
+  gegl_operation_context_take_object (context, padname, G_OBJECT (output));
   return output;
 }
 

Modified: trunk/gegl/operation/gegl-operation-context.h
==============================================================================
--- trunk/gegl/operation/gegl-operation-context.h	(original)
+++ trunk/gegl/operation/gegl-operation-context.h	Sat Apr 11 07:50:07 2009
@@ -57,7 +57,7 @@
                                                         const gchar          *padname);
 GObject        *gegl_operation_context_get_object      (GeglOperationContext *context,
                                                         const gchar          *padname);
-void            gegl_operation_context_set_object      (GeglOperationContext *context,
+void            gegl_operation_context_take_object     (GeglOperationContext *context,
                                                         const gchar          *padname,
                                                         GObject              *data);
 void            gegl_operation_context_set_property    (GeglOperationContext *self,

Modified: trunk/gegl/operation/gegl-operation.c
==============================================================================
--- trunk/gegl/operation/gegl-operation.c	(original)
+++ trunk/gegl/operation/gegl-operation.c	Sat Apr 11 07:50:07 2009
@@ -116,7 +116,7 @@
       (result->width == 0 || result->height == 0))
     {
       GeglBuffer *output = gegl_buffer_new (NULL, NULL);
-      gegl_operation_context_set_object (context, "output", G_OBJECT (output));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (output));
       return TRUE;
     }
 

Modified: trunk/operations/affine/affine.c
==============================================================================
--- trunk/operations/affine/affine.c	(original)
+++ trunk/operations/affine/affine.c	Sat Apr 11 07:50:07 2009
@@ -742,7 +742,7 @@
           return FALSE;
         }
 
-      gegl_operation_context_set_object (context, "output", G_OBJECT (input));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (input));
     }
   else if (gegl_matrix3_is_translate (affine->matrix) &&
            (! strcmp (affine->filter, "nearest") ||
@@ -761,7 +761,7 @@
                                                     of source) */
                          NULL);
 
-      gegl_operation_context_set_object (context, "output", G_OBJECT (output));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (output));
 
       if (input != NULL)
         g_object_unref (input);

Modified: trunk/operations/common/buffer-source.c
==============================================================================
--- trunk/operations/common/buffer-source.c	(original)
+++ trunk/operations/common/buffer-source.c	Sat Apr 11 07:50:07 2009
@@ -62,8 +62,8 @@
 				     */
 
       /* override core behaviour, by resetting the buffer in the operation_context */
-      gegl_operation_context_set_object (context, "output",
-				    G_OBJECT (o->buffer));
+      gegl_operation_context_take_object (context, "output",
+                                          G_OBJECT (o->buffer));
     }
   return TRUE;
 }

Modified: trunk/operations/common/introspect.c
==============================================================================
--- trunk/operations/common/introspect.c	(original)
+++ trunk/operations/common/introspect.c	Sat Apr 11 07:50:07 2009
@@ -128,12 +128,12 @@
 
   gegl_introspect_load_cache (o);
 
-  /* gegl_operation_context_set_object() takes the reference we have,
+  /* gegl_operation_context_take_object() takes the reference we have,
    * so we must increase it since we want to keep the object
    */
   g_object_ref (o->chant_data);
 
-  gegl_operation_context_set_object (context, output_pad, G_OBJECT (o->chant_data));
+  gegl_operation_context_take_object (context, output_pad, G_OBJECT (o->chant_data));
 
   return  TRUE;
 }

Modified: trunk/operations/common/magick-load.c
==============================================================================
--- trunk/operations/common/magick-load.c	(original)
+++ trunk/operations/common/magick-load.c	Sat Apr 11 07:50:07 2009
@@ -122,7 +122,7 @@
     return FALSE;
 
   /* overriding the predefined behavior */
-  gegl_operation_context_set_object (context, "output", G_OBJECT (o->chant_data));
+  gegl_operation_context_take_object (context, "output", G_OBJECT (o->chant_data));
   o->chant_data = NULL;
 
   return  TRUE;

Modified: trunk/operations/common/open-buffer.c
==============================================================================
--- trunk/operations/common/open-buffer.c	(original)
+++ trunk/operations/common/open-buffer.c	Sat Apr 11 07:50:07 2009
@@ -88,7 +88,7 @@
 		              */
 
       /* override core behaviour, by resetting the buffer in the operation_context */
-      gegl_operation_context_set_object (context, "output", G_OBJECT (buffer));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (buffer));
       return TRUE;
     }
   return FALSE;

Modified: trunk/operations/common/raw-load.c
==============================================================================
--- trunk/operations/common/raw-load.c	(original)
+++ trunk/operations/common/raw-load.c	Sat Apr 11 07:50:07 2009
@@ -136,7 +136,7 @@
   g_assert (g_str_equal (output_pad, "output"));
 
   output = GEGL_BUFFER (o->chant_data);
-  gegl_operation_context_set_object (context, "output", G_OBJECT (output));
+  gegl_operation_context_take_object (context, "output", G_OBJECT (output));
 
   o->chant_data = NULL;
   return TRUE;

Modified: trunk/operations/core/clone.c
==============================================================================
--- trunk/operations/core/clone.c	(original)
+++ trunk/operations/core/clone.c	Sat Apr 11 07:50:07 2009
@@ -88,7 +88,7 @@
       g_warning ("clone received NULL input");
       return FALSE;
     }
-  gegl_operation_context_set_object (context, "output", G_OBJECT (input));
+  gegl_operation_context_take_object (context, "output", G_OBJECT (input));
   return TRUE;
 }
 

Modified: trunk/operations/core/crop.c
==============================================================================
--- trunk/operations/core/crop.c	(original)
+++ trunk/operations/core/crop.c	Sat Apr 11 07:50:07 2009
@@ -137,7 +137,7 @@
       GeglBuffer *output;
 
       output = gegl_buffer_create_sub_buffer (input, &extent);
-      gegl_operation_context_set_object (context, "output", G_OBJECT (output));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (output));
       g_object_unref (input);
       success = TRUE;
     }

Modified: trunk/operations/core/nop.c
==============================================================================
--- trunk/operations/core/nop.c	(original)
+++ trunk/operations/core/nop.c	Sat Apr 11 07:50:07 2009
@@ -53,7 +53,7 @@
       return FALSE;
     }
 
-  gegl_operation_context_set_object (context, "output", G_OBJECT (input));
+  gegl_operation_context_take_object (context, "output", G_OBJECT (input));
   return TRUE;
 }
 

Modified: trunk/operations/workshop/rawbayer-load.c
==============================================================================
--- trunk/operations/workshop/rawbayer-load.c	(original)
+++ trunk/operations/workshop/rawbayer-load.c	Sat Apr 11 07:50:07 2009
@@ -118,7 +118,7 @@
   GeglChantO *o = GEGL_CHANT_PROPERTIES (operation);
 #if 1
   g_assert (o->chant_data);
-  gegl_operation_context_set_object (context, "output", G_OBJECT (o->chant_data));
+  gegl_operation_context_take_object (context, "output", G_OBJECT (o->chant_data));
 
   o->chant_data = NULL;
 #else
@@ -129,7 +129,7 @@
                                     */
 
       /* override core behaviour, by resetting the buffer in the operation_context */
-      gegl_operation_context_set_object (context, "output", G_OBJECT (o->chant_data));
+      gegl_operation_context_take_object (context, "output", G_OBJECT (o->chant_data));
     }
 #endif
   return TRUE;



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