summaryrefslogtreecommitdiffstats
path: root/gio/gio.override
diff options
context:
space:
mode:
authorJohan Dahlin <johan@gnome.org>2008-07-24 21:38:50 +0000
committerJohan Dahlin <johan@src.gnome.org>2008-07-24 21:38:50 +0000
commit4777faab0d31bd883bf2eee600bf8bd32f119600 (patch)
tree7b56d4ac2aaa902bc0924f25bb5dfe790230e140 /gio/gio.override
parentc5639326d2f2f09175e495d4e24193e22df8f7be (diff)
downloadpygobject-4777faab0d31bd883bf2eee600bf8bd32f119600.tar.gz
pygobject-4777faab0d31bd883bf2eee600bf8bd32f119600.tar.xz
pygobject-4777faab0d31bd883bf2eee600bf8bd32f119600.zip
Wrap gio.File.copy, add tests and documentation. Rename
2008-07-24 Johan Dahlin <johan@gnome.org> * gio/gfile.override: * gio/gfileenumerator.override: * gio/ginputstream.override: * gio/gio.defs: * gio/gio.override: * gio/goutputstream.override: * tests/test_gio.py: Wrap gio.File.copy, add tests and documentation. Rename PyGAsyncRequestNotify to PyGIONotify and reuse it. svn path=/trunk/; revision=850
Diffstat (limited to 'gio/gio.override')
-rw-r--r--gio/gio.override14
1 files changed, 7 insertions, 7 deletions
diff --git a/gio/gio.override b/gio/gio.override
index 3d26b7d..ffd2d4e 100644
--- a/gio/gio.override
+++ b/gio/gio.override
@@ -35,7 +35,7 @@ headers
typedef struct {
PyObject *callback;
PyObject *data;
-} PyGAsyncRequestNotify;
+} PyGIONotify;
static void
py_decref_callback (gpointer data)
@@ -46,7 +46,7 @@ py_decref_callback (gpointer data)
static void
async_result_callback_marshal(GObject *source_object,
GAsyncResult *result,
- PyGAsyncRequestNotify *notify)
+ PyGIONotify *notify)
{
PyObject *ret;
PyGILState_STATE state;
@@ -73,7 +73,7 @@ async_result_callback_marshal(GObject *source_object,
Py_DECREF(notify->callback);
Py_XDECREF(notify->data);
- g_slice_free(PyGAsyncRequestNotify, notify);
+ g_slice_free(PyGIONotify, notify);
pyg_gil_state_release(state);
}
@@ -234,13 +234,13 @@ _wrap_g_mount_unmount(PyGObject *self,
{
static char *kwlist[] = { "callback", "flags",
"cancellable", "user_data", NULL };
- PyGAsyncRequestNotify *notify;
+ PyGIONotify *notify;
PyObject *py_flags = NULL;
PyGObject *py_cancellable = NULL;
GMountUnmountFlags flags = G_MOUNT_UNMOUNT_NONE;
GCancellable *cancellable;
- notify = g_slice_new0(PyGAsyncRequestNotify);
+ notify = g_slice_new0(PyGIONotify);
if (!PyArg_ParseTupleAndKeywords(args, kwargs,
"O|OOO:GMount.unmount",
@@ -251,14 +251,14 @@ _wrap_g_mount_unmount(PyGObject *self,
&notify->data))
{
- g_slice_free(PyGAsyncRequestNotify, notify);
+ g_slice_free(PyGIONotify, notify);
return NULL;
}
if (!PyCallable_Check(notify->callback))
{
PyErr_SetString(PyExc_TypeError, "callback argument not callable");
- g_slice_free(PyGAsyncRequestNotify, notify);
+ g_slice_free(PyGIONotify, notify);
return NULL;
}
Py_INCREF(notify->callback);