X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fopenbox_wrap.cc;h=39ff63bd57c6ef9191cf22e585314773e3a920f1;hb=8f8acc24933830d4f5784616b9b0c5896bde0b93;hp=b5e66bb62fe46ce22f0c794496075e5705d73f84;hpb=88b7de4aaa417512552003ccf20344766234e0e3;p=chaz%2Fopenbox diff --git a/src/openbox_wrap.cc b/src/openbox_wrap.cc index b5e66bb6..39ff63bd 100644 --- a/src/openbox_wrap.cc +++ b/src/openbox_wrap.cc @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.17u-20021226-0459 + * Version 1.3.17u-20021128-1508 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -791,19 +791,19 @@ static void _SWIG_exception(int code, const char *msg) { #include -static PyObject* SwigInt_FromBool(bool b) { +PyObject* SwigInt_FromBool(bool b) { return PyInt_FromLong(b ? 1L : 0L); } -static double SwigNumber_Check(PyObject* o) { +double SwigNumber_Check(PyObject* o) { return PyFloat_Check(o) || PyInt_Check(o); } -static double SwigNumber_AsDouble(PyObject* o) { +double SwigNumber_AsDouble(PyObject* o) { return (PyFloat_Check(o) ? PyFloat_AsDouble(o) : double(PyInt_AsLong(o))); } -static PyObject* SwigString_FromString(const std::string& s) { +PyObject* SwigString_FromString(const std::string& s) { return PyString_FromString(s.c_str()); } -static std::string SwigString_AsString(PyObject* o) { +std::string SwigString_AsString(PyObject* o) { return std::string(PyString_AsString(o)); } @@ -882,6 +882,9 @@ void python_callback(PyObject *func, KeyData *data) #include + + Display *OBDisplay_display() { return otk::OBDisplay::display; } + ob::OBClient *ob_OBScreen_client(ob::OBScreen *self,int i){ if (i >= (int)self->clients.size()) return NULL; @@ -909,24 +912,17 @@ static PyObject *_wrap_Openbox_instance(PyObject *self, PyObject *args) { } -static int _wrap_OBDisplay_display_set(PyObject *_val) { - { - void *temp; - if ((SWIG_ConvertPtr(_val,(void **) &temp, SWIGTYPE_p_Display, SWIG_POINTER_EXCEPTION | SWIG_POINTER_DISOWN)) == -1) { - PyErr_SetString(PyExc_TypeError, "C variable 'otk::OBDisplay::display (Display *)'"); - return 1; - } - otk::OBDisplay::display = (Display *) temp; - } - return 0; -} - - -static PyObject *_wrap_OBDisplay_display_get() { - PyObject *pyobj; +static PyObject *_wrap_OBDisplay_display(PyObject *self, PyObject *args) { + PyObject *resultobj; + Display *result; - pyobj = SWIG_NewPointerObj((void *) otk::OBDisplay::display, SWIGTYPE_p_Display, 0); - return pyobj; + if(!PyArg_ParseTuple(args,(char *)":OBDisplay_display")) goto fail; + result = (Display *)OBDisplay_display(); + + resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_Display, 0); + return resultobj; + fail: + return NULL; } @@ -3964,6 +3960,30 @@ static PyObject *_wrap_itostring(PyObject *self, PyObject *args) { } +static PyObject *_wrap_putenv(PyObject *self, PyObject *args) { + PyObject *resultobj; + std::string *arg1 = 0 ; + std::string temp1 ; + PyObject * obj0 = 0 ; + + if(!PyArg_ParseTuple(args,(char *)"O:putenv",&obj0)) goto fail; + { + if (PyString_Check(obj0)) { + temp1 = std::string(PyString_AsString(obj0)); + arg1 = &temp1; + }else { + SWIG_exception(SWIG_TypeError, "string expected"); + } + } + otk::putenv((std::string const &)*arg1); + + Py_INCREF(Py_None); resultobj = Py_None; + return resultobj; + fail: + return NULL; +} + + static PyObject *_wrap_basename(PyObject *self, PyObject *args) { PyObject *resultobj; std::string *arg1 = 0 ; @@ -8105,6 +8125,7 @@ static PyObject *_wrap_send_client_msg(PyObject *self, PyObject *args) { static PyMethodDef SwigMethods[] = { { (char *)"Openbox_instance", _wrap_Openbox_instance, METH_VARARGS }, + { (char *)"OBDisplay_display", _wrap_OBDisplay_display, METH_VARARGS }, { (char *)"OBDisplay_initialize", _wrap_OBDisplay_initialize, METH_VARARGS }, { (char *)"OBDisplay_destroy", _wrap_OBDisplay_destroy, METH_VARARGS }, { (char *)"OBDisplay_gcCache", _wrap_OBDisplay_gcCache, METH_VARARGS }, @@ -8195,6 +8216,7 @@ static PyMethodDef SwigMethods[] = { { (char *)"itostring_long", _wrap_itostring_long, METH_VARARGS }, { (char *)"itostring_unsigned", _wrap_itostring_unsigned, METH_VARARGS }, { (char *)"itostring", _wrap_itostring, METH_VARARGS }, + { (char *)"putenv", _wrap_putenv, METH_VARARGS }, { (char *)"basename", _wrap_basename, METH_VARARGS }, { (char *)"OtkEventHandler_handle", _wrap_OtkEventHandler_handle, METH_VARARGS }, { (char *)"OtkEventHandler_keyPressHandler", _wrap_OtkEventHandler_keyPressHandler, METH_VARARGS }, @@ -9117,7 +9139,6 @@ SWIGEXPORT(void) SWIG_init(void) { SWIG_InstallConstants(d,swig_const_table); PyDict_SetItemString(d,(char*)"cvar", SWIG_globals); - SWIG_addvarlink(SWIG_globals,(char*)"OBDisplay_display",_wrap_OBDisplay_display_get, _wrap_OBDisplay_display_set); SWIG_addvarlink(SWIG_globals,(char*)"BSENTINEL",_wrap_BSENTINEL_get, _wrap_BSENTINEL_set); }