2 # Copyright (c) 2008 INdT - Instituto Nokia de Tecnologia
4 # This file is part of python-purple.
6 # python-purple is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
11 # python-purple is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program. If not, see <http://www.gnu.org/licenses/>.
21 ctypedef int volatile_gint "volatile int"
23 cdef extern from "glib.h":
24 ctypedef void *gpointer
25 ctypedef void *gconstpointer
27 ctypedef unsigned int guint
28 ctypedef unsigned long gulong
29 ctypedef signed long long gint64
30 ctypedef unsigned long long guint64
31 ctypedef gint gboolean
32 ctypedef gboolean (*GSourceFunc) (gpointer data)
33 ctypedef unsigned int gsize
35 ctypedef unsigned char guchar
37 ctypedef void (*GCallback) ()
38 ctypedef void (*GDestroyNotify) (gpointer)
40 ctypedef guint GHashFunc (gconstpointer)
41 ctypedef gboolean GEqualFunc (gconstpointer, gconstpointer)
43 ctypedef struct GObject:
46 ctypedef struct GHashNode:
52 ctypedef struct GHashTable:
57 GEqualFunc key_equal_func
58 volatile_gint ref_count
60 GDestroyNotify key_destroy_func
61 GDestroyNotify value_destroy_func
63 ctypedef struct GMainContext:
66 ctypedef struct GSList:
70 ctypedef struct GList:
75 void g_list_free (GList*)
77 gboolean g_str_equal (gconstpointer, gconstpointer)
78 guint g_str_hash (gconstpointer)
80 GHashTable *g_hash_table_new (GHashFunc, GEqualFunc)
81 void g_hash_table_destroy (GHashTable*)
82 GList *g_hash_table_get_keys (GHashTable*)
83 GList *g_hash_table_get_values (GHashTable*)
84 void g_hash_table_insert (GHashTable*, gpointer, gpointer)
85 gpointer g_hash_table_lookup (GHashTable*, gconstpointer)
87 guint g_timeout_add(guint interval, GSourceFunc function, gpointer data)
88 guint g_timeout_add_seconds(guint interval, GSourceFunc function, gpointer data)
90 gboolean g_main_context_iteration (GMainContext *context, gboolean may_block)
92 gboolean g_source_remove(guint tag)