summaryrefslogtreecommitdiffstats
path: root/gio
diff options
context:
space:
mode:
authorGian Mario Tagliaretti <gianmt@gnome.org>2009-03-30 22:56:59 +0000
committerGian Mario Tagliaretti <gianmt@src.gnome.org>2009-03-30 22:56:59 +0000
commit9202a2ae922608d5c970818036446d59273e63c5 (patch)
tree8ac83a58eed15839d5a525fe12870507e28034f1 /gio
parent43f80a09363d72d92b015a8d19e7b00d7529fe18 (diff)
downloadpygobject-9202a2ae922608d5c970818036446d59273e63c5.tar.gz
pygobject-9202a2ae922608d5c970818036446d59273e63c5.tar.xz
pygobject-9202a2ae922608d5c970818036446d59273e63c5.zip
Wrap new GFile method.
2009-03-31 Gian Mario Tagliaretti <gianmt@gnome.org> * gio/gfile.override: (_wrap_g_file_query_filesystem_info_async) Wrap new GFile method. svn path=/trunk/; revision=1051
Diffstat (limited to 'gio')
-rw-r--r--gio/gfile.override48
1 files changed, 48 insertions, 0 deletions
diff --git a/gio/gfile.override b/gio/gfile.override
index 3d9cbb0..6d63533 100644
--- a/gio/gfile.override
+++ b/gio/gfile.override
@@ -1374,6 +1374,54 @@ _wrap_g_file_find_enclosing_mount_async(PyGObject *self,
pygio_notify_free(notify);
return NULL;
}
+%%
+override g_file_query_filesystem_info_async kwargs
+static PyObject *
+_wrap_g_file_query_filesystem_info_async(PyGObject *self, PyObject *args, PyObject *kwargs)
+{
+ static char *kwlist[] = { "attributes", "callback",
+ "io_priority", "cancellable", "user_data", NULL };
+ PyGIONotify *notify;
+ char *attributes;
+ int io_priority = G_PRIORITY_DEFAULT;
+ GCancellable *cancellable = NULL;
+ PyGObject *py_cancellable = NULL;
+
+ notify = pygio_notify_new();
+
+ if (!PyArg_ParseTupleAndKeywords(args, kwargs,
+ "sO|iOO:GFile.enumerate_children_async",
+ kwlist,
+ &attributes,
+ &notify->callback,
+ &io_priority,
+ &py_cancellable,
+ &notify->data))
+ goto error;
+
+ if (!pygio_notify_callback_is_valid(notify))
+ goto error;
+
+
+ if (!pygio_check_cancellable(py_cancellable, &cancellable))
+ goto error;
+
+ pygio_notify_reference_callback(notify);
+
+ g_file_query_filesystem_info_async(G_FILE(self->obj),
+ attributes,
+ io_priority,
+ (GCancellable *) cancellable,
+ (GAsyncReadyCallback)async_result_callback_marshal,
+ notify);
+
+ Py_INCREF(Py_None);
+ return Py_None;
+
+ error:
+ pygio_notify_free(notify);
+ return NULL;
+}
/* GFile.set_attributes_async */
/* GFile.set_display_name_async */