Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2008-11-11 21:20:42 (GMT)
committer Jonas Smedegaard <dr@jones.dk>2008-11-11 21:20:42 (GMT)
commit69c890e6731e3ef7ecb3dc2bf96711ff402403aa (patch)
tree951111d409c36f905e973743753c07987c8cccc2
parent1fef73f90a320955b604ba038e03713626d5be60 (diff)
Imported Upstream version 0.4.7~dfsgupstream/0.4.7.dfsg
-rw-r--r--python/config.py1
-rw-r--r--python/hulahop.c358
2 files changed, 0 insertions, 359 deletions
diff --git a/python/config.py b/python/config.py
deleted file mode 100644
index 52b362e..0000000
--- a/python/config.py
+++ /dev/null
@@ -1 +0,0 @@
-libxul_dir = '/home/erikos/sugar-jhbuild/install/lib64/xulrunner-1.9.0.2'
diff --git a/python/hulahop.c b/python/hulahop.c
deleted file mode 100644
index 9a31345..0000000
--- a/python/hulahop.c
+++ /dev/null
@@ -1,358 +0,0 @@
-/* -- THIS FILE IS GENERATED - DO NOT EDIT *//* -*- Mode: C; c-basic-offset: 4 -*- */
-
-#include <Python.h>
-
-
-
-#line 4 "hulahop.override"
-#include <Python.h>
-#include <pygtk/pygtk.h>
-
-#include "hulahop-web-view.h"
-
-#line 14 "hulahop.c"
-
-
-/* ---------- types from other modules ---------- */
-static PyTypeObject *_PyGtkBin_Type;
-#define PyGtkBin_Type (*_PyGtkBin_Type)
-
-
-/* ---------- forward type declarations ---------- */
-PyTypeObject G_GNUC_INTERNAL PyHulahopWebView_Type;
-
-#line 25 "hulahop.c"
-
-
-
-/* ----------- HulahopWebView ----------- */
-
-static PyObject *
-_wrap_hulahop_web_view_grab_focus(PyGObject *self)
-{
-
- hulahop_web_view_grab_focus(HULAHOP_WEB_VIEW(self->obj));
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-#line 19 "hulahop.override"
-static PyObject *
-_wrap_hulahop_web_view_get_browser(PyGObject *self)
-{
- return hulahop_web_view_get_browser(HULAHOP_WEB_VIEW(self->obj));
-}
-#line 47 "hulahop.c"
-
-
-#line 26 "hulahop.override"
-static PyObject *
-_wrap_hulahop_web_view_get_window_root(PyGObject *self)
-{
- return hulahop_web_view_get_window_root(HULAHOP_WEB_VIEW(self->obj));
-}
-#line 56 "hulahop.c"
-
-
-static PyObject *
-_wrap_hulahop_web_view_push_js_context(PyGObject *self)
-{
-
- hulahop_web_view_push_js_context(HULAHOP_WEB_VIEW(self->obj));
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_hulahop_web_view_pop_js_context(PyGObject *self)
-{
-
- hulahop_web_view_pop_js_context(HULAHOP_WEB_VIEW(self->obj));
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_hulahop_web_view_evaluate_script(PyGObject *self, PyObject *args, PyObject *kwargs)
-{
- static char *kwlist[] = { "script", NULL };
- char *script;
-
- if (!PyArg_ParseTupleAndKeywords(args, kwargs,"s:HulahopWebView.evaluate_script", kwlist, &script))
- return NULL;
-
- hulahop_web_view_evaluate_script(HULAHOP_WEB_VIEW(self->obj), script);
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_HulahopWebView__do_setup(PyObject *cls, PyObject *args, PyObject *kwargs)
-{
- gpointer klass;
- static char *kwlist[] = { "self", NULL };
- PyGObject *self;
-
- if (!PyArg_ParseTupleAndKeywords(args, kwargs,"O!:HulahopWebView.setup", kwlist, &PyHulahopWebView_Type, &self))
- return NULL;
- klass = g_type_class_ref(pyg_type_from_object(cls));
- if (HULAHOP_WEB_VIEW_CLASS(klass)->setup)
- HULAHOP_WEB_VIEW_CLASS(klass)->setup(HULAHOP_WEB_VIEW(self->obj));
- else {
- PyErr_SetString(PyExc_NotImplementedError, "virtual method HulahopWebView.setup not implemented");
- g_type_class_unref(klass);
- return NULL;
- }
- g_type_class_unref(klass);
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static const PyMethodDef _PyHulahopWebView_methods[] = {
- { "grab_focus", (PyCFunction)_wrap_hulahop_web_view_grab_focus, METH_NOARGS,
- NULL },
- { "get_browser", (PyCFunction)_wrap_hulahop_web_view_get_browser, METH_NOARGS,
- NULL },
- { "get_window_root", (PyCFunction)_wrap_hulahop_web_view_get_window_root, METH_NOARGS,
- NULL },
- { "push_js_context", (PyCFunction)_wrap_hulahop_web_view_push_js_context, METH_NOARGS,
- NULL },
- { "pop_js_context", (PyCFunction)_wrap_hulahop_web_view_pop_js_context, METH_NOARGS,
- NULL },
- { "evaluate_script", (PyCFunction)_wrap_hulahop_web_view_evaluate_script, METH_VARARGS|METH_KEYWORDS,
- NULL },
- { "do_setup", (PyCFunction)_wrap_HulahopWebView__do_setup, METH_VARARGS|METH_KEYWORDS|METH_CLASS,
- NULL },
- { NULL, NULL, 0, NULL }
-};
-
-PyTypeObject G_GNUC_INTERNAL PyHulahopWebView_Type = {
- PyObject_HEAD_INIT(NULL)
- 0, /* ob_size */
- "_hulahop.WebView", /* tp_name */
- sizeof(PyGObject), /* tp_basicsize */
- 0, /* tp_itemsize */
- /* methods */
- (destructor)0, /* tp_dealloc */
- (printfunc)0, /* tp_print */
- (getattrfunc)0, /* tp_getattr */
- (setattrfunc)0, /* tp_setattr */
- (cmpfunc)0, /* tp_compare */
- (reprfunc)0, /* tp_repr */
- (PyNumberMethods*)0, /* tp_as_number */
- (PySequenceMethods*)0, /* tp_as_sequence */
- (PyMappingMethods*)0, /* tp_as_mapping */
- (hashfunc)0, /* tp_hash */
- (ternaryfunc)0, /* tp_call */
- (reprfunc)0, /* tp_str */
- (getattrofunc)0, /* tp_getattro */
- (setattrofunc)0, /* tp_setattro */
- (PyBufferProcs*)0, /* tp_as_buffer */
- Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /* tp_flags */
- NULL, /* Documentation string */
- (traverseproc)0, /* tp_traverse */
- (inquiry)0, /* tp_clear */
- (richcmpfunc)0, /* tp_richcompare */
- offsetof(PyGObject, weakreflist), /* tp_weaklistoffset */
- (getiterfunc)0, /* tp_iter */
- (iternextfunc)0, /* tp_iternext */
- (struct PyMethodDef*)_PyHulahopWebView_methods, /* tp_methods */
- (struct PyMemberDef*)0, /* tp_members */
- (struct PyGetSetDef*)0, /* tp_getset */
- NULL, /* tp_base */
- NULL, /* tp_dict */
- (descrgetfunc)0, /* tp_descr_get */
- (descrsetfunc)0, /* tp_descr_set */
- offsetof(PyGObject, inst_dict), /* tp_dictoffset */
- (initproc)0, /* tp_init */
- (allocfunc)0, /* tp_alloc */
- (newfunc)0, /* tp_new */
- (freefunc)0, /* tp_free */
- (inquiry)0 /* tp_is_gc */
-};
-
-static void
-_wrap_HulahopWebView__proxy_do_setup(HulahopWebView *self)
-{
- PyGILState_STATE __py_state;
- PyObject *py_self;
- PyObject *py_retval;
- PyObject *py_method;
-
- __py_state = pyg_gil_state_ensure();
- py_self = pygobject_new((GObject *) self);
- if (!py_self) {
- if (PyErr_Occurred())
- PyErr_Print();
- pyg_gil_state_release(__py_state);
- return;
- }
-
-
- py_method = PyObject_GetAttrString(py_self, "do_setup");
- if (!py_method) {
- if (PyErr_Occurred())
- PyErr_Print();
- Py_DECREF(py_self);
- pyg_gil_state_release(__py_state);
- return;
- }
- py_retval = PyObject_CallObject(py_method, NULL);
- if (!py_retval) {
- if (PyErr_Occurred())
- PyErr_Print();
- Py_XDECREF(py_retval);
- Py_DECREF(py_method);
- Py_DECREF(py_self);
- pyg_gil_state_release(__py_state);
- return;
- }
- if (py_retval != Py_None) {
- PyErr_SetString(PyExc_TypeError, "virtual method should return None");
- PyErr_Print();
- Py_XDECREF(py_retval);
- Py_DECREF(py_method);
- Py_DECREF(py_self);
- pyg_gil_state_release(__py_state);
- return;
- }
-
-
- Py_XDECREF(py_retval);
- Py_DECREF(py_method);
- Py_DECREF(py_self);
- pyg_gil_state_release(__py_state);
-}
-
-static int
-__HulahopWebView_class_init(gpointer gclass, PyTypeObject *pyclass)
-{
- PyObject *o;
- HulahopWebViewClass *klass = HULAHOP_WEB_VIEW_CLASS(gclass);
- PyObject *gsignals = PyDict_GetItemString(pyclass->tp_dict, "__gsignals__");
-
- o = PyObject_GetAttrString((PyObject *) pyclass, "do_setup");
- if (o == NULL)
- PyErr_Clear();
- else {
- if (!PyObject_TypeCheck(o, &PyCFunction_Type)
- && !(gsignals && PyDict_GetItemString(gsignals, "setup")))
- klass->setup = _wrap_HulahopWebView__proxy_do_setup;
- Py_DECREF(o);
- }
- return 0;
-}
-
-
-/* ----------- functions ----------- */
-
-static PyObject *
-_wrap_hulahop_startup(PyObject *self)
-{
- int ret;
-
-
- ret = hulahop_startup();
-
- return PyBool_FromLong(ret);
-
-}
-
-static PyObject *
-_wrap_hulahop_shutdown(PyObject *self)
-{
-
- hulahop_shutdown();
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_hulahop_set_profile_path(PyObject *self, PyObject *args, PyObject *kwargs)
-{
- static char *kwlist[] = { "path", NULL };
- char *path;
-
- if (!PyArg_ParseTupleAndKeywords(args, kwargs,"s:set_profile_path", kwlist, &path))
- return NULL;
-
- hulahop_set_profile_path(path);
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_hulahop_add_components_path(PyObject *self, PyObject *args, PyObject *kwargs)
-{
- static char *kwlist[] = { "path", NULL };
- char *path;
-
- if (!PyArg_ParseTupleAndKeywords(args, kwargs,"s:add_components_path", kwlist, &path))
- return NULL;
-
- hulahop_add_components_path(path);
-
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-static PyObject *
-_wrap_hulahop_get_view_for_window(PyObject *self, PyObject *args, PyObject *kwargs)
-{
- static char *kwlist[] = { "dom_window", NULL };
- PyObject *dom_window;
- HulahopWebView *ret;
-
- if (!PyArg_ParseTupleAndKeywords(args, kwargs,"O:get_view_for_window", kwlist, &dom_window))
- return NULL;
-
- ret = hulahop_get_view_for_window(dom_window);
-
- /* pygobject_new handles NULL checking */
- return pygobject_new((GObject *)ret);
-}
-
-const PyMethodDef pyhulahop_functions[] = {
- { "startup", (PyCFunction)_wrap_hulahop_startup, METH_NOARGS,
- NULL },
- { "shutdown", (PyCFunction)_wrap_hulahop_shutdown, METH_NOARGS,
- NULL },
- { "set_profile_path", (PyCFunction)_wrap_hulahop_set_profile_path, METH_VARARGS|METH_KEYWORDS,
- NULL },
- { "add_components_path", (PyCFunction)_wrap_hulahop_add_components_path, METH_VARARGS|METH_KEYWORDS,
- NULL },
- { "get_view_for_window", (PyCFunction)_wrap_hulahop_get_view_for_window, METH_VARARGS|METH_KEYWORDS,
- NULL },
- { NULL, NULL, 0, NULL }
-};
-
-/* initialise stuff extension classes */
-void
-pyhulahop_register_classes(PyObject *d)
-{
- PyObject *module;
-
- if ((module = PyImport_ImportModule("gtk")) != NULL) {
- _PyGtkBin_Type = (PyTypeObject *)PyObject_GetAttrString(module, "Bin");
- if (_PyGtkBin_Type == NULL) {
- PyErr_SetString(PyExc_ImportError,
- "cannot import name Bin from gtk");
- return ;
- }
- } else {
- PyErr_SetString(PyExc_ImportError,
- "could not import gtk");
- return ;
- }
-
-
-#line 356 "hulahop.c"
- pygobject_register_class(d, "HulahopWebView", HULAHOP_TYPE_WEB_VIEW, &PyHulahopWebView_Type, Py_BuildValue("(O)", &PyGtkBin_Type));
- pyg_register_class_init(HULAHOP_TYPE_WEB_VIEW, __HulahopWebView_class_init);
-}