[gegl] gegl: make gegl-op.h C++-friendly
- From: Ell <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] gegl: make gegl-op.h C++-friendly
- Date: Mon, 12 Nov 2018 07:36:31 +0000 (UTC)
commit b9e36cc9498e0d7c3721f49175c8e6f19d148118
Author: Ell <ell_se yahoo com>
Date: Sun Nov 11 12:45:41 2018 -0500
gegl: make gegl-op.h C++-friendly
... by adding some explicit casts.
gegl/gegl-op.h | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/gegl/gegl-op.h b/gegl/gegl-op.h
index fdfac9795..0a52011e4 100644
--- a/gegl/gegl-op.h
+++ b/gegl/gegl-op.h
@@ -515,22 +515,23 @@ set_property (GObject *gobject,
#define property_object(name, label, def_val) \
case PROP_##name: \
g_clear_object (&properties->name); \
- properties->name = g_value_dup_object (value); \
+ properties->name = G_OBJECT (g_value_dup_object (value)); \
break;
#define property_curve(name, label, def_val) \
case PROP_##name: \
g_clear_object (&properties->name); \
- properties->name = g_value_dup_object (value); \
+ properties->name = GEGL_CURVE (g_value_dup_object (value)); \
break;
#define property_color(name, label, def_val) \
case PROP_##name: \
g_clear_object (&properties->name); \
- properties->name = g_value_dup_object (value); \
+ properties->name = GEGL_COLOR (g_value_dup_object (value)); \
break;
#define property_audio_fragment(name, label, def_val) \
case PROP_##name: \
g_clear_object (&properties->name); \
- properties->name = g_value_dup_object (value); \
+ properties->name = \
+ GEGL_AUDIO_FRAGMENT (g_value_dup_object (value); \
break;
#define property_path(name, label, def_val) \
case PROP_##name: \
@@ -542,7 +543,7 @@ set_property (GObject *gobject,
properties->path_changed_handler = 0; \
g_object_unref (properties->name); \
} \
- properties->name = g_value_dup_object (value); \
+ properties->name = GEGL_PATH (g_value_dup_object (value)); \
if (properties->name != NULL) \
{ \
properties->path_changed_handler = \
@@ -560,7 +561,7 @@ set_property (GObject *gobject,
break;
#define property_enum(name, label, enum, enum_name, def_val) \
case PROP_##name: \
- properties->name = g_value_get_enum (value); \
+ properties->name = (enum) g_value_get_enum (value); \
break;
#define property_seed(name, label, rand_name) \
case PROP_##name: \
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]