(wxObjectEventFunction) &wxPyCallback::EventThunker,
new wxPyCallback(func));
}
+ else if (func == Py_None) {
+ self->Disconnect(id, lastId, eventType,
+ (wxObjectEventFunction)
+ &wxPyCallback::EventThunker);
+ }
+ else {
+ PyErr_SetString(PyExc_TypeError, "Expected callable object or None.");
+ }
}
static PyObject *_wrap_wxEvtHandler_Connect(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxFont & _result_ref = wxWindow_GetFont(_arg0);
- _result = (wxFont *) &_result_ref;
+ _result = new wxFont (wxWindow_GetFont(_arg0));
wxPy_END_ALLOW_THREADS;
if (PyErr_Occurred()) return NULL;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxFont_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
+} SWIG_MakePtr(_ptemp, (void *) _result,"_wxFont_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
return _resultobj;
}
PyObject * _resultobj;
bool _result;
wxWindow * _arg0;
- bool _arg1;
+ bool _arg1 = (bool ) TRUE;
PyObject * _argo0 = 0;
- int tempbool1;
+ int tempbool1 = (int) TRUE;
char *_kwnames[] = { "self","show", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxWindow_Show",_kwnames,&_argo0,&tempbool1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxWindow_Show",_kwnames,&_argo0,&tempbool1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
wxPy_END_ALLOW_THREADS;
if (PyErr_Occurred()) return NULL;
-}{ _resultobj = wxPyMake_wxObject(_result); }
+}{ _resultobj = wxPyMake_wxSizer(_result); }
return _resultobj;
}