2 * Copyright (C) 2006-2007, Red Hat, Inc.
3 * Copyright (C) 2009 Jan Michael Alonzo <jmalonzo@gmail.com>
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the
17 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 * Boston, MA 02111-1307, USA.
26 /* include this first, before NO_IMPORT_PYGOBJECT is defined */
27 #include <pygobject.h>
28 #include <pygtk/pygtk.h>
30 extern PyMethodDef pywebkit_functions
[];
32 void pywebkit_register_classes (PyObject
*d
);
39 if (!pygobject_init(-1, -1, -1)) {
41 Py_FatalError ("can't initialise module gobject");
46 if (!g_thread_supported())
50 m
= Py_InitModule ("webkit", pywebkit_functions
);
51 d
= PyModule_GetDict (m
);
52 pywebkit_register_classes (d
);
54 if (PyErr_Occurred ()) {
56 Py_FatalError ("can't initialise module webkit.gjs");