From 12d1116bee8820bb1850f6f3ec63aa8a81b8e53f Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Sun, 12 May 2002 04:16:47 +0000 Subject: [PATCH] swigged updates for wxGTK git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15521 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/src/gtk/controls2.cpp | 202 --------------------------------- wxPython/src/gtk/misc.cpp | 22 ++++ wxPython/src/gtk/misc.py | 4 + wxPython/src/gtk/misc2.cpp | 80 +++++++++++++ wxPython/src/gtk/misc2.py | 6 + wxPython/src/gtk/printfw.cpp | 87 ++++++++++++++ wxPython/src/gtk/printfw.py | 9 ++ wxPython/src/gtk/utils.cpp | 5 +- wxPython/src/gtk/windows.cpp | 38 +++++++ wxPython/src/gtk/windows.py | 3 + wxPython/src/gtk/windows2.cpp | 1 + 11 files changed, 253 insertions(+), 204 deletions(-) diff --git a/wxPython/src/gtk/controls2.cpp b/wxPython/src/gtk/controls2.cpp index 330f426071..a3299838d8 100644 --- a/wxPython/src/gtk/controls2.cpp +++ b/wxPython/src/gtk/controls2.cpp @@ -2156,35 +2156,6 @@ static PyObject *_wrap_new_wxListEvent(PyObject *self, PyObject *args, PyObject return _resultobj; } -#define wxListEvent_m_code_set(_swigobj,_swigval) (_swigobj->m_code = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_code_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - int _result; - wxListEvent * _arg0; - int _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_code", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxListEvent_m_code_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_code_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_code_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("i",_result); - return _resultobj; -} - #define wxListEvent_m_code_get(_swigobj) ((int ) _swigobj->m_code) static PyObject *_wrap_wxListEvent_m_code_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2213,35 +2184,6 @@ static PyObject *_wrap_wxListEvent_m_code_get(PyObject *self, PyObject *args, Py return _resultobj; } -#define wxListEvent_m_oldItemIndex_set(_swigobj,_swigval) (_swigobj->m_oldItemIndex = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_oldItemIndex_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - long _result; - wxListEvent * _arg0; - long _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_oldItemIndex", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListEvent_m_oldItemIndex_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_oldItemIndex_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_oldItemIndex_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("l",_result); - return _resultobj; -} - #define wxListEvent_m_oldItemIndex_get(_swigobj) ((long ) _swigobj->m_oldItemIndex) static PyObject *_wrap_wxListEvent_m_oldItemIndex_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2270,35 +2212,6 @@ static PyObject *_wrap_wxListEvent_m_oldItemIndex_get(PyObject *self, PyObject * return _resultobj; } -#define wxListEvent_m_itemIndex_set(_swigobj,_swigval) (_swigobj->m_itemIndex = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_itemIndex_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - long _result; - wxListEvent * _arg0; - long _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_itemIndex", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxListEvent_m_itemIndex_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_itemIndex_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (long )wxListEvent_m_itemIndex_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("l",_result); - return _resultobj; -} - #define wxListEvent_m_itemIndex_get(_swigobj) ((long ) _swigobj->m_itemIndex) static PyObject *_wrap_wxListEvent_m_itemIndex_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2327,35 +2240,6 @@ static PyObject *_wrap_wxListEvent_m_itemIndex_get(PyObject *self, PyObject *arg return _resultobj; } -#define wxListEvent_m_col_set(_swigobj,_swigval) (_swigobj->m_col = _swigval,_swigval) -static PyObject *_wrap_wxListEvent_m_col_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - int _result; - wxListEvent * _arg0; - int _arg1; - PyObject * _argo0 = 0; - char *_kwnames[] = { "self","m_col", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxListEvent_m_col_set",_kwnames,&_argo0,&_arg1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_col_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (int )wxListEvent_m_col_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} _resultobj = Py_BuildValue("i",_result); - return _resultobj; -} - #define wxListEvent_m_col_get(_swigobj) ((int ) _swigobj->m_col) static PyObject *_wrap_wxListEvent_m_col_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2384,49 +2268,6 @@ static PyObject *_wrap_wxListEvent_m_col_get(PyObject *self, PyObject *args, PyO return _resultobj; } -#define wxListEvent_m_pointDrag_set(_swigobj,_swigval) (_swigobj->m_pointDrag = *(_swigval),_swigval) -static PyObject *_wrap_wxListEvent_m_pointDrag_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - wxPoint * _result; - wxListEvent * _arg0; - wxPoint * _arg1; - PyObject * _argo0 = 0; - wxPoint temp; - PyObject * _obj1 = 0; - char *_kwnames[] = { "self","m_pointDrag", NULL }; - char _ptemp[128]; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxListEvent_m_pointDrag_set",_kwnames,&_argo0,&_obj1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_pointDrag_set. Expected _wxListEvent_p."); - return NULL; - } - } -{ - _arg1 = &temp; - if (! wxPoint_helper(_obj1, &_arg1)) - return NULL; -} -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxPoint *)wxListEvent_m_pointDrag_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -} if (_result) { - SWIG_MakePtr(_ptemp, (char *) _result,"_wxPoint_p"); - _resultobj = Py_BuildValue("s",_ptemp); - } else { - Py_INCREF(Py_None); - _resultobj = Py_None; - } - return _resultobj; -} - #define wxListEvent_m_pointDrag_get(_swigobj) (&_swigobj->m_pointDrag) static PyObject *_wrap_wxListEvent_m_pointDrag_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2462,43 +2303,6 @@ static PyObject *_wrap_wxListEvent_m_pointDrag_get(PyObject *self, PyObject *arg return _resultobj; } -#define wxListEvent_m_item_set(_swigobj,_swigval) (_swigobj->m_item = *(_swigval),_swigval) -static PyObject *_wrap_wxListEvent_m_item_set(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject * _resultobj; - wxListItem * _result; - wxListEvent * _arg0; - wxListItem * _arg1; - PyObject * _argo0 = 0; - PyObject * _argo1 = 0; - char *_kwnames[] = { "self","m_item", NULL }; - - self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxListEvent_m_item_set",_kwnames,&_argo0,&_argo1)) - return NULL; - if (_argo0) { - if (_argo0 == Py_None) { _arg0 = NULL; } - else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListEvent_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListEvent_m_item_set. Expected _wxListEvent_p."); - return NULL; - } - } - if (_argo1) { - if (_argo1 == Py_None) { _arg1 = NULL; } - else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxListItem_p")) { - PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListEvent_m_item_set. Expected _wxListItem_p."); - return NULL; - } - } -{ - PyThreadState* __tstate = wxPyBeginAllowThreads(); - _result = (wxListItem *)wxListEvent_m_item_set(_arg0,_arg1); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) return NULL; -}{ _resultobj = wxPyMake_wxObject(_result); } - return _resultobj; -} - #define wxListEvent_m_item_get(_swigobj) (&_swigobj->m_item) static PyObject *_wrap_wxListEvent_m_item_get(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -10952,17 +10756,11 @@ static PyMethodDef controls2cMethods[] = { { "wxListEvent_GetIndex", (PyCFunction) _wrap_wxListEvent_GetIndex, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_GetCode", (PyCFunction) _wrap_wxListEvent_GetCode, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_item_get", (PyCFunction) _wrap_wxListEvent_m_item_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_item_set", (PyCFunction) _wrap_wxListEvent_m_item_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_pointDrag_get", (PyCFunction) _wrap_wxListEvent_m_pointDrag_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_pointDrag_set", (PyCFunction) _wrap_wxListEvent_m_pointDrag_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_col_get", (PyCFunction) _wrap_wxListEvent_m_col_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_col_set", (PyCFunction) _wrap_wxListEvent_m_col_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_itemIndex_get", (PyCFunction) _wrap_wxListEvent_m_itemIndex_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_itemIndex_set", (PyCFunction) _wrap_wxListEvent_m_itemIndex_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_oldItemIndex_get", (PyCFunction) _wrap_wxListEvent_m_oldItemIndex_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_oldItemIndex_set", (PyCFunction) _wrap_wxListEvent_m_oldItemIndex_set, METH_VARARGS | METH_KEYWORDS }, { "wxListEvent_m_code_get", (PyCFunction) _wrap_wxListEvent_m_code_get, METH_VARARGS | METH_KEYWORDS }, - { "wxListEvent_m_code_set", (PyCFunction) _wrap_wxListEvent_m_code_set, METH_VARARGS | METH_KEYWORDS }, { "new_wxListEvent", (PyCFunction) _wrap_new_wxListEvent, METH_VARARGS | METH_KEYWORDS }, { "wxListItem_m_width_get", (PyCFunction) _wrap_wxListItem_m_width_get, METH_VARARGS | METH_KEYWORDS }, { "wxListItem_m_width_set", (PyCFunction) _wrap_wxListItem_m_width_set, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/misc.cpp b/wxPython/src/gtk/misc.cpp index abe4cf77a9..9b55b43aee 100644 --- a/wxPython/src/gtk/misc.cpp +++ b/wxPython/src/gtk/misc.cpp @@ -509,6 +509,25 @@ static PyObject *_wrap_wxGetOsDescription(PyObject *self, PyObject *args, PyObje return _resultobj; } +static PyObject *_wrap_wxShutdown(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxShutdownFlags _arg0; + char *_kwnames[] = { "wFlags", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:wxShutdown",_kwnames,&_arg0)) + return NULL; +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (bool )wxShutdown(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + static PyObject *_wrap_wxSleep(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; int _arg0; @@ -4238,6 +4257,7 @@ static PyMethodDef misccMethods[] = { { "wxYield", (PyCFunction) _wrap_wxYield, METH_VARARGS | METH_KEYWORDS }, { "wxUsleep", (PyCFunction) _wrap_wxUsleep, METH_VARARGS | METH_KEYWORDS }, { "wxSleep", (PyCFunction) _wrap_wxSleep, METH_VARARGS | METH_KEYWORDS }, + { "wxShutdown", (PyCFunction) _wrap_wxShutdown, METH_VARARGS | METH_KEYWORDS }, { "wxGetOsDescription", (PyCFunction) _wrap_wxGetOsDescription, METH_VARARGS | METH_KEYWORDS }, { "wxGetOsVersion", (PyCFunction) _wrap_wxGetOsVersion, METH_VARARGS | METH_KEYWORDS }, { "wxStartTimer", (PyCFunction) _wrap_wxStartTimer, METH_VARARGS | METH_KEYWORDS }, @@ -4370,6 +4390,8 @@ SWIGEXPORT(void) initmiscc() { SWIG_globals = SWIG_newvarlink(); m = Py_InitModule("miscc", misccMethods); d = PyModule_GetDict(m); + PyDict_SetItemString(d,"wxSHUTDOWN_POWEROFF", PyInt_FromLong((long) wxSHUTDOWN_POWEROFF)); + PyDict_SetItemString(d,"wxSHUTDOWN_REBOOT", PyInt_FromLong((long) wxSHUTDOWN_REBOOT)); PyDict_SetItemString(d,"wxLeft", PyInt_FromLong((long) wxLeft)); PyDict_SetItemString(d,"wxTop", PyInt_FromLong((long) wxTop)); PyDict_SetItemString(d,"wxRight", PyInt_FromLong((long) wxRight)); diff --git a/wxPython/src/gtk/misc.py b/wxPython/src/gtk/misc.py index d8acff0fb4..b6abd3bc34 100644 --- a/wxPython/src/gtk/misc.py +++ b/wxPython/src/gtk/misc.py @@ -575,6 +575,8 @@ wxGetOsVersion = miscc.wxGetOsVersion wxGetOsDescription = miscc.wxGetOsDescription +wxShutdown = miscc.wxShutdown + wxSleep = miscc.wxSleep wxUsleep = miscc.wxUsleep @@ -612,6 +614,8 @@ def wxGetAccelFromString(*_args, **_kwargs): #-------------- VARIABLE WRAPPERS ------------------ +wxSHUTDOWN_POWEROFF = miscc.wxSHUTDOWN_POWEROFF +wxSHUTDOWN_REBOOT = miscc.wxSHUTDOWN_REBOOT wxLeft = miscc.wxLeft wxTop = miscc.wxTop wxRight = miscc.wxRight diff --git a/wxPython/src/gtk/misc2.cpp b/wxPython/src/gtk/misc2.cpp index e6919f4c6f..46ac78960d 100644 --- a/wxPython/src/gtk/misc2.cpp +++ b/wxPython/src/gtk/misc2.cpp @@ -2261,6 +2261,46 @@ static PyObject *_wrap_wxLogSysError(PyObject *self, PyObject *args, PyObject *k return _resultobj; } +static PyObject *_wrap_wxSafeShowMessage(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxString * _arg0; + wxString * _arg1; + PyObject * _obj0 = 0; + PyObject * _obj1 = 0; + char *_kwnames[] = { "title","text", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxSafeShowMessage",_kwnames,&_obj0,&_obj1)) + return NULL; +{ + _arg0 = wxString_in_helper(_obj0); + if (_arg0 == NULL) + return NULL; +} +{ + _arg1 = wxString_in_helper(_obj1); + if (_arg1 == NULL) + return NULL; +} +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxSafeShowMessage(*_arg0,*_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; +{ + if (_obj0) + delete _arg0; +} +{ + if (_obj1) + delete _arg1; +} + return _resultobj; +} + static PyObject *_wrap_wxExecute(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; long _result; @@ -2431,6 +2471,43 @@ static PyObject *_wrap_wxSystemSettings_HasFeature(PyObject *self, PyObject *arg return _resultobj; } +static PyObject *_wrap_wxSystemSettings_GetScreen(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxSystemScreen _result; + char *_kwnames[] = { NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxSystemSettings_GetScreen",_kwnames)) + return NULL; +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (wxSystemScreen )wxSystemSettings::GetScreen(); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + +static PyObject *_wrap_wxSystemSettings_SetScreen(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxSystemScreen _arg0; + char *_kwnames[] = { "screen", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:wxSystemSettings_SetScreen",_kwnames,&_arg0)) + return NULL; +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxSystemSettings::SetScreen(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + static void *SwigwxToolTipTowxObject(void *ptr) { wxToolTip *src; wxObject *dest; @@ -10029,12 +10106,15 @@ static PyMethodDef misc2cMethods[] = { { "wxToolTip_GetTip", (PyCFunction) _wrap_wxToolTip_GetTip, METH_VARARGS | METH_KEYWORDS }, { "wxToolTip_SetTip", (PyCFunction) _wrap_wxToolTip_SetTip, METH_VARARGS | METH_KEYWORDS }, { "new_wxToolTip", (PyCFunction) _wrap_new_wxToolTip, METH_VARARGS | METH_KEYWORDS }, + { "wxSystemSettings_SetScreen", (PyCFunction) _wrap_wxSystemSettings_SetScreen, METH_VARARGS | METH_KEYWORDS }, + { "wxSystemSettings_GetScreen", (PyCFunction) _wrap_wxSystemSettings_GetScreen, METH_VARARGS | METH_KEYWORDS }, { "wxSystemSettings_HasFeature", (PyCFunction) _wrap_wxSystemSettings_HasFeature, METH_VARARGS | METH_KEYWORDS }, { "wxSystemSettings_GetMetric", (PyCFunction) _wrap_wxSystemSettings_GetMetric, METH_VARARGS | METH_KEYWORDS }, { "wxSystemSettings_GetFont", (PyCFunction) _wrap_wxSystemSettings_GetFont, METH_VARARGS | METH_KEYWORDS }, { "wxSystemSettings_GetColour", (PyCFunction) _wrap_wxSystemSettings_GetColour, METH_VARARGS | METH_KEYWORDS }, { "wxWaveData", (PyCFunction) _wrap_wxWaveData, METH_VARARGS | METH_KEYWORDS }, { "wxExecute", (PyCFunction) _wrap_wxExecute, METH_VARARGS | METH_KEYWORDS }, + { "wxSafeShowMessage", (PyCFunction) _wrap_wxSafeShowMessage, METH_VARARGS | METH_KEYWORDS }, { "wxLogSysError", (PyCFunction) _wrap_wxLogSysError, METH_VARARGS | METH_KEYWORDS }, { "wxLogStatusFrame", (PyCFunction) _wrap_wxLogStatusFrame, METH_VARARGS | METH_KEYWORDS }, { "wxLogStatus", (PyCFunction) _wrap_wxLogStatus, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/misc2.py b/wxPython/src/gtk/misc2.py index aad17d6eac..6f063d12c8 100644 --- a/wxPython/src/gtk/misc2.py +++ b/wxPython/src/gtk/misc2.py @@ -1103,6 +1103,8 @@ wxLogStatusFrame = misc2c.wxLogStatusFrame wxLogSysError = misc2c.wxLogSysError +wxSafeShowMessage = misc2c.wxSafeShowMessage + wxExecute = misc2c.wxExecute def wxWaveData(*_args, **_kwargs): @@ -1124,6 +1126,10 @@ wxSystemSettings_GetMetric = misc2c.wxSystemSettings_GetMetric wxSystemSettings_HasFeature = misc2c.wxSystemSettings_HasFeature +wxSystemSettings_GetScreen = misc2c.wxSystemSettings_GetScreen + +wxSystemSettings_SetScreen = misc2c.wxSystemSettings_SetScreen + wxToolTip_Enable = misc2c.wxToolTip_Enable wxToolTip_SetDelay = misc2c.wxToolTip_SetDelay diff --git a/wxPython/src/gtk/printfw.cpp b/wxPython/src/gtk/printfw.cpp index d0dbdeecc3..44a493747e 100644 --- a/wxPython/src/gtk/printfw.cpp +++ b/wxPython/src/gtk/printfw.cpp @@ -301,6 +301,34 @@ static PyObject *_wrap_wxPrintData_GetOrientation(PyObject *self, PyObject *args return _resultobj; } +#define wxPrintData_Ok(_swigobj) (_swigobj->Ok()) +static PyObject *_wrap_wxPrintData_Ok(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxPrintData * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPrintData_Ok",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPrintData_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPrintData_Ok. Expected _wxPrintData_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (bool )wxPrintData_Ok(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + #define wxPrintData_GetPrinterName(_swigobj) (_swigobj->GetPrinterName()) static PyObject *_wrap_wxPrintData_GetPrinterName(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2329,6 +2357,34 @@ static PyObject *_wrap_wxPageSetupDialogData_GetPrintData(PyObject *self, PyObje return _resultobj; } +#define wxPageSetupDialogData_Ok(_swigobj) (_swigobj->Ok()) +static PyObject *_wrap_wxPageSetupDialogData_Ok(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxPageSetupDialogData * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPageSetupDialogData_Ok",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPageSetupDialogData_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPageSetupDialogData_Ok. Expected _wxPageSetupDialogData_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (bool )wxPageSetupDialogData_Ok(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + #define wxPageSetupDialogData_SetDefaultInfo(_swigobj,_swigarg0) (_swigobj->SetDefaultInfo(_swigarg0)) static PyObject *_wrap_wxPageSetupDialogData_SetDefaultInfo(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -3232,6 +3288,34 @@ static PyObject *_wrap_wxPrintDialogData_GetToPage(PyObject *self, PyObject *arg return _resultobj; } +#define wxPrintDialogData_Ok(_swigobj) (_swigobj->Ok()) +static PyObject *_wrap_wxPrintDialogData_Ok(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxPrintDialogData * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPrintDialogData_Ok",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPrintDialogData_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPrintDialogData_Ok. Expected _wxPrintDialogData_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + _result = (bool )wxPrintDialogData_Ok(_arg0); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + #define wxPrintDialogData_SetCollate(_swigobj,_swigarg0) (_swigobj->SetCollate(_swigarg0)) static PyObject *_wrap_wxPrintDialogData_SetCollate(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -5373,6 +5457,7 @@ static PyMethodDef printfwcMethods[] = { { "wxPrintDialogData_SetMaxPage", (PyCFunction) _wrap_wxPrintDialogData_SetMaxPage, METH_VARARGS | METH_KEYWORDS }, { "wxPrintDialogData_SetFromPage", (PyCFunction) _wrap_wxPrintDialogData_SetFromPage, METH_VARARGS | METH_KEYWORDS }, { "wxPrintDialogData_SetCollate", (PyCFunction) _wrap_wxPrintDialogData_SetCollate, METH_VARARGS | METH_KEYWORDS }, + { "wxPrintDialogData_Ok", (PyCFunction) _wrap_wxPrintDialogData_Ok, METH_VARARGS | METH_KEYWORDS }, { "wxPrintDialogData_GetToPage", (PyCFunction) _wrap_wxPrintDialogData_GetToPage, METH_VARARGS | METH_KEYWORDS }, { "wxPrintDialogData_GetPrintToFile", (PyCFunction) _wrap_wxPrintDialogData_GetPrintToFile, METH_VARARGS | METH_KEYWORDS }, { "wxPrintDialogData_GetPrintData", (PyCFunction) _wrap_wxPrintDialogData_GetPrintData, METH_VARARGS | METH_KEYWORDS }, @@ -5400,6 +5485,7 @@ static PyMethodDef printfwcMethods[] = { { "wxPageSetupDialogData_SetMarginTopLeft", (PyCFunction) _wrap_wxPageSetupDialogData_SetMarginTopLeft, METH_VARARGS | METH_KEYWORDS }, { "wxPageSetupDialogData_SetDefaultMinMargins", (PyCFunction) _wrap_wxPageSetupDialogData_SetDefaultMinMargins, METH_VARARGS | METH_KEYWORDS }, { "wxPageSetupDialogData_SetDefaultInfo", (PyCFunction) _wrap_wxPageSetupDialogData_SetDefaultInfo, METH_VARARGS | METH_KEYWORDS }, + { "wxPageSetupDialogData_Ok", (PyCFunction) _wrap_wxPageSetupDialogData_Ok, METH_VARARGS | METH_KEYWORDS }, { "wxPageSetupDialogData_GetPrintData", (PyCFunction) _wrap_wxPageSetupDialogData_GetPrintData, METH_VARARGS | METH_KEYWORDS }, { "wxPageSetupDialogData_GetPaperSize", (PyCFunction) _wrap_wxPageSetupDialogData_GetPaperSize, METH_VARARGS | METH_KEYWORDS }, { "wxPageSetupDialogData_GetPaperId", (PyCFunction) _wrap_wxPageSetupDialogData_GetPaperId, METH_VARARGS | METH_KEYWORDS }, @@ -5464,6 +5550,7 @@ static PyMethodDef printfwcMethods[] = { { "wxPrintData_GetDuplex", (PyCFunction) _wrap_wxPrintData_GetDuplex, METH_VARARGS | METH_KEYWORDS }, { "wxPrintData_GetColour", (PyCFunction) _wrap_wxPrintData_GetColour, METH_VARARGS | METH_KEYWORDS }, { "wxPrintData_GetPrinterName", (PyCFunction) _wrap_wxPrintData_GetPrinterName, METH_VARARGS | METH_KEYWORDS }, + { "wxPrintData_Ok", (PyCFunction) _wrap_wxPrintData_Ok, METH_VARARGS | METH_KEYWORDS }, { "wxPrintData_GetOrientation", (PyCFunction) _wrap_wxPrintData_GetOrientation, METH_VARARGS | METH_KEYWORDS }, { "wxPrintData_GetCollate", (PyCFunction) _wrap_wxPrintData_GetCollate, METH_VARARGS | METH_KEYWORDS }, { "wxPrintData_GetNoCopies", (PyCFunction) _wrap_wxPrintData_GetNoCopies, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/printfw.py b/wxPython/src/gtk/printfw.py index 70fb3b1887..6265abcddf 100644 --- a/wxPython/src/gtk/printfw.py +++ b/wxPython/src/gtk/printfw.py @@ -37,6 +37,9 @@ class wxPrintDataPtr(wxObjectPtr): def GetOrientation(self, *_args, **_kwargs): val = apply(printfwc.wxPrintData_GetOrientation,(self,) + _args, _kwargs) return val + def Ok(self, *_args, **_kwargs): + val = apply(printfwc.wxPrintData_Ok,(self,) + _args, _kwargs) + return val def GetPrinterName(self, *_args, **_kwargs): val = apply(printfwc.wxPrintData_GetPrinterName,(self,) + _args, _kwargs) return val @@ -255,6 +258,9 @@ class wxPageSetupDialogDataPtr(wxObjectPtr): val = apply(printfwc.wxPageSetupDialogData_GetPrintData,(self,) + _args, _kwargs) if val: val = wxPrintDataPtr(val) ; val.thisown = 1 return val + def Ok(self, *_args, **_kwargs): + val = apply(printfwc.wxPageSetupDialogData_Ok,(self,) + _args, _kwargs) + return val def SetDefaultInfo(self, *_args, **_kwargs): val = apply(printfwc.wxPageSetupDialogData_SetDefaultInfo,(self,) + _args, _kwargs) return val @@ -361,6 +367,9 @@ class wxPrintDialogDataPtr(wxObjectPtr): def GetToPage(self, *_args, **_kwargs): val = apply(printfwc.wxPrintDialogData_GetToPage,(self,) + _args, _kwargs) return val + def Ok(self, *_args, **_kwargs): + val = apply(printfwc.wxPrintDialogData_Ok,(self,) + _args, _kwargs) + return val def SetCollate(self, *_args, **_kwargs): val = apply(printfwc.wxPrintDialogData_SetCollate,(self,) + _args, _kwargs) return val diff --git a/wxPython/src/gtk/utils.cpp b/wxPython/src/gtk/utils.cpp index b4920a86fe..3b5bee1283 100644 --- a/wxPython/src/gtk/utils.cpp +++ b/wxPython/src/gtk/utils.cpp @@ -7883,8 +7883,9 @@ SWIGEXPORT(void) initutilsc() { PyDict_SetItemString(d,"wxCONFIG_USE_GLOBAL_FILE", PyInt_FromLong((long) wxCONFIG_USE_GLOBAL_FILE)); PyDict_SetItemString(d,"wxCONFIG_USE_RELATIVE_PATH", PyInt_FromLong((long) wxCONFIG_USE_RELATIVE_PATH)); - wxClassInfo::CleanUpClasses(); - wxClassInfo::InitializeClasses(); + // These are no longer needed since utils is back in the core +// wxClassInfo::CleanUpClasses(); +// wxClassInfo::InitializeClasses(); PyDict_SetItemString(d,"wxConfigBase_Type_Unknown", PyInt_FromLong((long) wxConfigBase::Type_Unknown)); PyDict_SetItemString(d,"wxConfigBase_Type_String", PyInt_FromLong((long) wxConfigBase::Type_String)); PyDict_SetItemString(d,"wxConfigBase_Type_Boolean", PyInt_FromLong((long) wxConfigBase::Type_Boolean)); diff --git a/wxPython/src/gtk/windows.cpp b/wxPython/src/gtk/windows.cpp index 0888f82b7b..816b9f667b 100644 --- a/wxPython/src/gtk/windows.cpp +++ b/wxPython/src/gtk/windows.cpp @@ -6228,6 +6228,43 @@ static PyObject *_wrap_wxWindow_SetDefaultItem(PyObject *self, PyObject *args, P return _resultobj; } +#define wxWindow_SetTmpDefaultItem(_swigobj,_swigarg0) (_swigobj->SetTmpDefaultItem(_swigarg0)) +static PyObject *_wrap_wxWindow_SetTmpDefaultItem(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxWindow * _arg0; + wxWindow * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","win", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxWindow_SetTmpDefaultItem",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxWindow_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxWindow_SetTmpDefaultItem. Expected _wxWindow_p."); + return NULL; + } + } + if (_argo1) { + if (_argo1 == Py_None) { _arg1 = NULL; } + else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxWindow_SetTmpDefaultItem. Expected _wxWindow_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxWindow_SetTmpDefaultItem(_arg0,_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxWindow_WarpPointer(_swigobj,_swigarg0,_swigarg1) (_swigobj->WarpPointer(_swigarg0,_swigarg1)) static PyObject *_wrap_wxWindow_WarpPointer(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -11165,6 +11202,7 @@ static PyMethodDef windowscMethods[] = { { "wxWindow_ReleaseMouse", (PyCFunction) _wrap_wxWindow_ReleaseMouse, METH_VARARGS | METH_KEYWORDS }, { "wxWindow_CaptureMouse", (PyCFunction) _wrap_wxWindow_CaptureMouse, METH_VARARGS | METH_KEYWORDS }, { "wxWindow_WarpPointer", (PyCFunction) _wrap_wxWindow_WarpPointer, METH_VARARGS | METH_KEYWORDS }, + { "wxWindow_SetTmpDefaultItem", (PyCFunction) _wrap_wxWindow_SetTmpDefaultItem, METH_VARARGS | METH_KEYWORDS }, { "wxWindow_SetDefaultItem", (PyCFunction) _wrap_wxWindow_SetDefaultItem, METH_VARARGS | METH_KEYWORDS }, { "wxWindow_GetDefaultItem", (PyCFunction) _wrap_wxWindow_GetDefaultItem, METH_VARARGS | METH_KEYWORDS }, { "wxWindow_GetAcceleratorTable", (PyCFunction) _wrap_wxWindow_GetAcceleratorTable, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/windows.py b/wxPython/src/gtk/windows.py index 085d8947bf..1803ef9da0 100644 --- a/wxPython/src/gtk/windows.py +++ b/wxPython/src/gtk/windows.py @@ -610,6 +610,9 @@ class wxWindowPtr(wxEvtHandlerPtr): def SetDefaultItem(self, *_args, **_kwargs): val = apply(windowsc.wxWindow_SetDefaultItem,(self,) + _args, _kwargs) return val + def SetTmpDefaultItem(self, *_args, **_kwargs): + val = apply(windowsc.wxWindow_SetTmpDefaultItem,(self,) + _args, _kwargs) + return val def WarpPointer(self, *_args, **_kwargs): val = apply(windowsc.wxWindow_WarpPointer,(self,) + _args, _kwargs) return val diff --git a/wxPython/src/gtk/windows2.cpp b/wxPython/src/gtk/windows2.cpp index 2e6c97a6ff..b72c9cdacf 100644 --- a/wxPython/src/gtk/windows2.cpp +++ b/wxPython/src/gtk/windows2.cpp @@ -68,6 +68,7 @@ extern PyObject *SWIG_newvarlink(void); // Put some wx default wxChar* values into wxStrings. DECLARE_DEF_STRING(NOTEBOOK_NAME); + DECLARE_DEF_STRING(PanelNameStr); static const wxChar* wxSplitterNameStr = wxT("splitter"); DECLARE_DEF_STRING(SplitterNameStr); -- 2.45.2