+#define DEC_PYCALLBACK_BOOL_STRING_pure(CBNAME) \
+ bool CBNAME(const wxString& a);
+ \
+#define IMP_PYCALLBACK_BOOL_STRING_pure(CLASS, PCLASS, CBNAME) \
+ bool CLASS::CBNAME(const wxString& a) { \
+ bool rval; \
+ bool doSave = wxPyRestoreThread(); \
+ if (m_myInst.findCallback(#CBNAME)) \
+ rval = m_myInst.callCallback(Py_BuildValue("(s)", a.c_str())); \
+ wxPySaveThread(doSave); \
+ return rval; \
+ } \
+
+//---------------------------------------------------------------------------
+
+#define DEC_PYCALLBACK_STRING_STRING_pure(CBNAME) \
+ wxString CBNAME(const wxString& a); \
+
+#define IMP_PYCALLBACK_STRING_STRING_pure(CLASS, PCLASS, CBNAME) \
+ wxString CLASS::CBNAME(const wxString& a) { \
+ wxString rval; \
+ bool doSave = wxPyRestoreThread(); \
+ if (m_myInst.findCallback(#CBNAME)) { \
+ PyObject* ro; \
+ ro = m_myInst.callCallbackObj(Py_BuildValue("(s)", a.c_str())); \
+ if (ro) { \
+ rval = PyString_AsString(PyObject_Str(ro)); \
+ Py_DECREF(ro); \
+ } \
+ } \
+ wxPySaveThread(doSave); \
+ return rval; \
+ } \
+
+//---------------------------------------------------------------------------
+
+#define DEC_PYCALLBACK_STRING_STRINGINT_pure(CBNAME) \
+ wxString CBNAME(const wxString& a,int b); \
+
+#define IMP_PYCALLBACK_STRING_STRINGINT_pure(CLASS, PCLASS, CBNAME) \
+ wxString CLASS::CBNAME(const wxString& a,int b) { \
+ wxString rval; \
+ bool doSave = wxPyRestoreThread(); \
+ if (m_myInst.findCallback(#CBNAME)) { \
+ PyObject* ro; \
+ ro = m_myInst.callCallbackObj(Py_BuildValue("(si)", a.c_str(),b)); \
+ if (ro) { \
+ rval = PyString_AsString(PyObject_Str(ro)); \
+ Py_DECREF(ro); \
+ } \
+ } \
+ wxPySaveThread(doSave); \
+ return rval; \
+ } \
+
+//---------------------------------------------------------------------------
+