[cairo-commit] goocanvas/src goocanvasgroup.c, 1.9, 1.10 goocanvasitem.c, 1.7, 1.8 goocanvasitemsimple.c, 1.12, 1.13 goocanvasprivate.h, 1.1, 1.2 goocanvasutils.c, 1.4, 1.5 goocanvasutils.h, 1.4, 1.5

Damon Chaplin commit at pdx.freedesktop.org
Wed Jul 19 06:38:15 PDT 2006


Committed by: damon

Update of /cvs/cairo/goocanvas/src
In directory kemper:/tmp/cvs-serv16845/src

Modified Files:
	goocanvasgroup.c goocanvasitem.c goocanvasitemsimple.c 
	goocanvasprivate.h goocanvasutils.c goocanvasutils.h 
Log Message:
2006-07-19  Damon Chaplin  <damon at gnome.org>

	* configure.in: depend on glib 2.10.0 (from Gian Mario Tagliaretti).

	* src/goocanvasutils.c (goo_canvas_pointer_events_get_type): use a
	flags type rather than an enum type (from Gustavo J. A. M. Carneiro).

	* src/goocanvasitem.c (goo_canvas_item_base_init): 
	* src/goocanvasitemsimple.c: 
	* src/goocanvasgroup.c: updated to use the flags type for
	"pointer-events" instead of enum.

 	* src/goocanvasprivate.h:
 	* src/goocanvasutils.h: The type GOO_TYPE_CAIRO_MATRIX is used in
 	a public interface (a property in the GooCanvasItem interface),
 	therefore it has to be public (from Gustavo J. A. M. Carneiro).



Index: goocanvasgroup.c
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasgroup.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- goocanvasgroup.c	27 May 2006 19:31:44 -0000	1.9
+++ goocanvasgroup.c	19 Jul 2006 13:38:13 -0000	1.10
@@ -329,7 +329,7 @@
       g_value_set_double (value, group->visibility_threshold);
       break;
     case PROP_POINTER_EVENTS:
-      g_value_set_enum (value, group->pointer_events);
+      g_value_set_flags (value, group->pointer_events);
       break;
     case PROP_TITLE:
       g_value_set_string (value, group->title);
@@ -367,7 +367,7 @@
       group->visibility_threshold = g_value_get_double (value);
       break;
     case PROP_POINTER_EVENTS:
-      group->pointer_events = g_value_get_enum (value);
+      group->pointer_events = g_value_get_flags (value);
       break;
     case PROP_TITLE:
       g_free (group->title);

Index: goocanvasitem.c
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasitem.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- goocanvasitem.c	18 Apr 2006 23:40:44 -0000	1.7
+++ goocanvasitem.c	19 Jul 2006 13:38:13 -0000	1.8
@@ -169,12 +169,12 @@
 							       G_PARAM_READWRITE));
 
       g_object_interface_install_property (g_iface,
-					   g_param_spec_enum ("pointer-events",
-							      _("Pointer Events"),
-							      _("Specifies when the item receives pointer events"),
-							      GOO_TYPE_CANVAS_POINTER_EVENTS,
-							      GOO_CANVAS_EVENTS_VISIBLE_PAINTED,
-							      G_PARAM_READWRITE));
+					   g_param_spec_flags ("pointer-events",
+							       _("Pointer Events"),
+							       _("Specifies when the item receives pointer events"),
+							       GOO_TYPE_CANVAS_POINTER_EVENTS,
+							       GOO_CANVAS_EVENTS_VISIBLE_PAINTED,
+							       G_PARAM_READWRITE));
 
       g_object_interface_install_property (g_iface,
 					   g_param_spec_string ("title",

Index: goocanvasitemsimple.c
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasitemsimple.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- goocanvasitemsimple.c	8 Jun 2006 08:45:27 -0000	1.12
+++ goocanvasitemsimple.c	19 Jul 2006 13:38:13 -0000	1.13
@@ -437,7 +437,7 @@
       g_value_set_double (value, item->visibility_threshold);
       break;
     case PROP_POINTER_EVENTS:
-      g_value_set_enum (value, item->pointer_events);
+      g_value_set_flags (value, item->pointer_events);
       break;
     case PROP_TITLE:
       g_value_set_string (value, item->title);
@@ -614,7 +614,7 @@
       item->visibility_threshold = g_value_get_double (value);
       break;
     case PROP_POINTER_EVENTS:
-      item->pointer_events = g_value_get_enum (value);
+      item->pointer_events = g_value_get_flags (value);
       break;
     case PROP_TITLE:
       g_free (item->title);

Index: goocanvasprivate.h
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasprivate.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- goocanvasprivate.h	14 Apr 2006 12:49:11 -0000	1.1
+++ goocanvasprivate.h	19 Jul 2006 13:38:13 -0000	1.2
@@ -34,7 +34,6 @@
 #define GOO_TYPE_CAIRO_LINE_CAP    (goo_cairo_line_cap_get_type ())
 #define GOO_TYPE_CAIRO_LINE_JOIN   (goo_cairo_line_join_get_type ())
 #define GOO_TYPE_CAIRO_LINE_DASH   (goo_cairo_line_dash_get_type ())
-#define GOO_TYPE_CAIRO_MATRIX	   (goo_cairo_matrix_get_type())
 
 GType goo_cairo_pattern_get_type   (void) G_GNUC_CONST;
 GType goo_cairo_fill_rule_get_type (void) G_GNUC_CONST;
@@ -43,9 +42,6 @@
 GType goo_cairo_line_cap_get_type  (void) G_GNUC_CONST;
 GType goo_cairo_line_join_get_type (void) G_GNUC_CONST;
 GType goo_cairo_line_dash_get_type (void) G_GNUC_CONST;
-GType goo_cairo_matrix_get_type    (void) G_GNUC_CONST;
-
-cairo_matrix_t*  goo_cairo_matrix_copy         (cairo_matrix_t   *matrix);
 
 cairo_pattern_t* goo_canvas_cairo_pattern_from_pixbuf (GdkPixbuf *pixbuf);
 cairo_surface_t* goo_canvas_cairo_surface_from_pixbuf (GdkPixbuf *pixbuf);

Index: goocanvasutils.c
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasutils.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- goocanvasutils.c	14 Apr 2006 12:49:11 -0000	1.4
+++ goocanvasutils.c	19 Jul 2006 13:38:13 -0000	1.5
@@ -93,7 +93,7 @@
 {
   static GType etype = 0;
   if (etype == 0) {
-    static const GEnumValue values[] = {
+    static const GFlagsValue values[] = {
       { GOO_CANVAS_EVENTS_VISIBLE_MASK, "GOO_CANVAS_EVENTS_VISIBLE_MASK", "visible-mask" },
       { GOO_CANVAS_EVENTS_PAINTED_MASK, "GOO_CANVAS_EVENTS_PAINTED_MASK", "painted-mask" },
       { GOO_CANVAS_EVENTS_FILL_MASK, "GOO_CANVAS_EVENTS_FILL_MASK", "fill-mask" },
@@ -109,7 +109,7 @@
       { GOO_CANVAS_EVENTS_ALL, "GOO_CANVAS_EVENTS_ALL", "all" },
       { 0, NULL, NULL }
     };
-    etype = g_enum_register_static ("GooCanvasPointerEvents", values);
+    etype = g_flags_register_static ("GooCanvasPointerEvents", values);
   }
   return etype;
 }

Index: goocanvasutils.h
===================================================================
RCS file: /cvs/cairo/goocanvas/src/goocanvasutils.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- goocanvasutils.h	14 Apr 2006 12:49:11 -0000	1.4
+++ goocanvasutils.h	19 Jul 2006 13:38:13 -0000	1.5
@@ -137,6 +137,12 @@
 void               goo_canvas_line_dash_unref (GooCanvasLineDash *dash);
 
 
+#define GOO_TYPE_CAIRO_MATRIX	   (goo_cairo_matrix_get_type())
+
+GType              goo_cairo_matrix_get_type  (void) G_GNUC_CONST;
+cairo_matrix_t*    goo_cairo_matrix_copy      (cairo_matrix_t   *matrix);
+
+
 G_END_DECLS
 
 #endif /* __GOO_CANVAS_UTILS_H__ */



More information about the cairo-commit mailing list