[cairo-commit] 2 commits - src/cairo-quartz-private.h src/cairo-quartz-surface.c

Bryce Harrington bryce at kemper.freedesktop.org
Fri Oct 3 11:39:48 PDT 2014


 src/cairo-quartz-private.h |    3 +++
 src/cairo-quartz-surface.c |   27 +++++++++------------------
 2 files changed, 12 insertions(+), 18 deletions(-)

New commits:
commit 03756e042a2916e6c5334e2a00ec503a38e172d4
Author: Andrea Canciani <ranma42 at gmail.com>
Date:   Fri Oct 3 09:56:24 2014 +0200

    quartz-image: Fix build
    
    The quartz-image backend uses _cairo_surface_is_quartz(), which
    therefore needs to be made available to it. Fixed as suggested by
    Bryce in the referenced bugreport.
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=84569
    Signed-off-by: Andrea Canciani <ranma42 at gmail.com>

diff --git a/src/cairo-quartz-private.h b/src/cairo-quartz-private.h
index f841a49..3ef14c3 100644
--- a/src/cairo-quartz-private.h
+++ b/src/cairo-quartz-private.h
@@ -83,6 +83,9 @@ typedef struct cairo_quartz_image_surface {
 cairo_private cairo_bool_t
 _cairo_quartz_verify_surface_size(int width, int height);
 
+cairo_private cairo_bool_t
+_cairo_surface_is_quartz (const cairo_surface_t *surface);
+
 cairo_private CGImageRef
 CairoQuartzCreateCGImage (cairo_format_t format,
 			      unsigned int width,
diff --git a/src/cairo-quartz-surface.c b/src/cairo-quartz-surface.c
index 667828b..1116ff9 100644
--- a/src/cairo-quartz-surface.c
+++ b/src/cairo-quartz-surface.c
@@ -140,9 +140,6 @@ _cairo_quartz_surface_create_internal (CGContextRef cgContext,
 				       unsigned int width,
 				       unsigned int height);
 
-static cairo_bool_t
-_cairo_surface_is_quartz (const cairo_surface_t *surface);
-
 /* Load all extra symbols */
 static void quartz_ensure_symbols (void)
 {
@@ -2473,7 +2470,7 @@ cairo_quartz_surface_get_cg_context (cairo_surface_t *surface)
  *
  * Return value: True if the surface is an quartz surface
  **/
-static cairo_bool_t
+cairo_bool_t
 _cairo_surface_is_quartz (const cairo_surface_t *surface)
 {
     return surface->backend == &cairo_quartz_surface_backend;
commit 531da6fb915a6e9ea33216a90196ae962876acf4
Author: Andrea Canciani <ranma42 at gmail.com>
Date:   Thu Oct 2 18:10:00 2014 +0200

    quartz: Fix build
    
    Cairo cannot build with Quartz enabled since
    573ddfc3d5c08c37b95a21e0a1b34acecc646053, because of a double
    definition of _cairo_surface_is_quartz().
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=84569
    Signed-off-by: Andrea Canciani <ranma42 at gmail.com>

diff --git a/src/cairo-quartz-surface.c b/src/cairo-quartz-surface.c
index 2aa83be..667828b 100644
--- a/src/cairo-quartz-surface.c
+++ b/src/cairo-quartz-surface.c
@@ -2195,20 +2195,6 @@ _cairo_quartz_surface_clipper_intersect_clip_path (cairo_surface_clipper_t *clip
     return CAIRO_STATUS_SUCCESS;
 }
 
-/**
- * _cairo_surface_is_quartz:
- * @surface: a #cairo_surface_t
- *
- * Checks if a surface is a #cairo_quartz_surface_t
- *
- * Return value: True if the surface is an quartz surface
- **/
-inline cairo_bool_t
-_cairo_surface_is_quartz (cairo_surface_t *surface)
-{
-    return surface->backend == &cairo_quartz_surface_backend;
-}
-
 // XXXtodo implement show_page; need to figure out how to handle begin/end
 
 static const struct _cairo_surface_backend cairo_quartz_surface_backend = {
@@ -2479,6 +2465,14 @@ cairo_quartz_surface_get_cg_context (cairo_surface_t *surface)
 	return NULL;
 }
 
+/**
+ * _cairo_surface_is_quartz:
+ * @surface: a #cairo_surface_t
+ *
+ * Checks if a surface is a #cairo_quartz_surface_t
+ *
+ * Return value: True if the surface is an quartz surface
+ **/
 static cairo_bool_t
 _cairo_surface_is_quartz (const cairo_surface_t *surface)
 {


More information about the cairo-commit mailing list