PyObject* ro;
ro = wxPyCBH_callCallbackObj(m_myInst, Py_BuildValue("(ii)",row,col));
if (ro) {
+ if (!PyString_Check(ro) && !PyUnicode_Check(ro)) {
+ PyObject* old = ro;
+ ro = PyObject_Str(ro);
+ Py_DECREF(old);
+ }
rval = Py2wxString(ro);
Py_DECREF(ro);
}
bool wxGridCellCoords_typecheck(PyObject* source) {
void* ptr;
-
+
if (wxPySwigInstance_Check(source) &&
wxPyConvertSwigPtr(source, (void **)&ptr, wxT("wxGridCellCoords")))
return True;
PyErr_Clear();
if (PySequence_Check(source) && PySequence_Length(source) == 2)
return True;
-
+
return False;
}