[cairo-commit] cairo/src cairo-gstate.c, 1.139, 1.140 cairoint.h, 1.150, 1.151

Carl Worth commit at pdx.freedesktop.org
Sat Jun 11 01:09:18 PDT 2005


Committed by: cworth

Update of /cvs/cairo/cairo/src
In directory gabe:/tmp/cvs-serv29413/src

Modified Files:
	cairo-gstate.c cairoint.h 
Log Message:

        * src/cairoint.h:
        * src/cairo-gstate.c: (_cairo_gstate_init,
        _cairo_gstate_init_copy, _cairo_gstate_fini): Make these functions
        static, which allows slightly less awkward error handling within
        them.


Index: cairo-gstate.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo-gstate.c,v
retrieving revision 1.139
retrieving revision 1.140
diff -u -d -r1.139 -r1.140
--- cairo-gstate.c	10 Jun 2005 19:18:21 -0000	1.139
+++ cairo-gstate.c	11 Jun 2005 08:09:15 -0000	1.140
@@ -42,6 +42,16 @@
 #include "cairo-gstate-private.h"
 
 static cairo_status_t
+_cairo_gstate_init (cairo_gstate_t  *gstate,
+		    cairo_surface_t *target);
+
+static cairo_status_t
+_cairo_gstate_init_copy (cairo_gstate_t *gstate, cairo_gstate_t *other);
+
+static void
+_cairo_gstate_fini (cairo_gstate_t *gstate);
+
+static cairo_status_t
 _cairo_gstate_clip_and_composite_trapezoids (cairo_gstate_t *gstate,
 					     cairo_pattern_t *src,
 					     cairo_operator_t operator,
@@ -80,7 +90,7 @@
     return gstate;
 }
 
-cairo_status_t
+static cairo_status_t
 _cairo_gstate_init (cairo_gstate_t  *gstate,
 		    cairo_surface_t *target)
 {
@@ -117,16 +127,16 @@
     gstate->target = target;
     cairo_surface_reference (gstate->target);
 
-    gstate->next = NULL;
-
     gstate->source = _cairo_pattern_create_solid (CAIRO_COLOR_BLACK);
-    if (!gstate->source)
-	return CAIRO_STATUS_NO_MEMORY;    
+    if (gstate->source == NULL)
+	return CAIRO_STATUS_NO_MEMORY;
+
+    gstate->next = NULL;
 
     return CAIRO_STATUS_SUCCESS;
 }
 
-cairo_status_t
+static cairo_status_t
 _cairo_gstate_init_copy (cairo_gstate_t *gstate, cairo_gstate_t *other)
 {
     cairo_status_t status;

Index: cairoint.h
===================================================================
RCS file: /cvs/cairo/cairo/src/cairoint.h,v
retrieving revision 1.150
retrieving revision 1.151
diff -u -d -r1.150 -r1.151
--- cairoint.h	11 Jun 2005 07:06:04 -0000	1.150
+++ cairoint.h	11 Jun 2005 08:09:15 -0000	1.151
@@ -932,16 +932,6 @@
 cairo_private cairo_gstate_t *
 _cairo_gstate_create (cairo_surface_t *target);
 
-cairo_private cairo_status_t
-_cairo_gstate_init (cairo_gstate_t  *gstate,
-		    cairo_surface_t *target);
-
-cairo_private cairo_status_t
-_cairo_gstate_init_copy (cairo_gstate_t *gstate, cairo_gstate_t *other);
-
-cairo_private void
-_cairo_gstate_fini (cairo_gstate_t *gstate);
-
 cairo_private void
 _cairo_gstate_destroy (cairo_gstate_t *gstate);
 
@@ -949,9 +939,6 @@
 _cairo_gstate_clone (cairo_gstate_t *gstate);
 
 cairo_private cairo_status_t
-_cairo_gstate_copy (cairo_gstate_t *dest, cairo_gstate_t *src);
-
-cairo_private cairo_status_t
 _cairo_gstate_begin_group (cairo_gstate_t *gstate);
 
 cairo_private cairo_status_t




More information about the cairo-commit mailing list