summaryrefslogtreecommitdiff
path: root/tests/testhelpermodule.c
diff options
context:
space:
mode:
authorMartin Pitt <martinpitt@gnome.org>2013-01-14 12:15:27 +0100
committerMartin Pitt <martinpitt@gnome.org>2013-01-14 12:22:19 +0100
commitf9429192cb1002725a11a75a7b8f9300375b9caf (patch)
tree18183acd970f3cea9e1702078bb26b5a75ec25a6 /tests/testhelpermodule.c
parent99f72925c7de76611f7592bce9d8217a9ff46809 (diff)
downloadpygobject-f9429192cb1002725a11a75a7b8f9300375b9caf.tar.gz
Support GParamSpec signal arguments from Python
In pyg_value_from_pyobject(), recognize both the real GI GObject.ParamSpec type as well as the statically wrapped _gobject.GParamSpec type. This fixes marshalling GObject.ParamSpec signal/vfunc arguments. https://bugzilla.gnome.org/show_bug.cgi?id=683099
Diffstat (limited to 'tests/testhelpermodule.c')
-rw-r--r--tests/testhelpermodule.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/testhelpermodule.c b/tests/testhelpermodule.c
index d82a3c22..9ca82bca 100644
--- a/tests/testhelpermodule.c
+++ b/tests/testhelpermodule.c
@@ -402,6 +402,15 @@ test_gvalue_ret_callback (GObject *object, GType type)
return ret;
}
+static GParamSpec *
+test_paramspec_in_callback (GObject *object, GParamSpec *p)
+{
+ g_return_val_if_fail (G_IS_OBJECT (object), NULL);
+ g_return_val_if_fail (G_IS_PARAM_SPEC (p), NULL);
+
+ return p;
+}
+
static void
connectcallbacks (GObject *object)
{
@@ -460,6 +469,10 @@ connectcallbacks (GObject *object)
"test_gvalue_ret",
G_CALLBACK (test_gvalue_ret_callback),
NULL);
+ g_signal_connect (G_OBJECT (object),
+ "test_paramspec_in",
+ G_CALLBACK (test_paramspec_in_callback),
+ NULL);
}
static PyObject *