#define SWIG_name "helpc"
-#include "export.h"
+#include "wxPython.h"
#include <wx/cshelp.h>
}
return target;
}
-
-#if PYTHON_API_VERSION >= 1009
- static char* wxStringErrorMsg = "String or Unicode type required";
-#else
- static char* wxStringErrorMsg = "string type is required for parameter";
-#endif
#ifdef __cplusplus
extern "C" {
#endif
return NULL;
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxHelpEvent *)new_wxHelpEvent(_arg0,_arg1,*_arg2);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxHelpEvent *)new_wxHelpEvent(_arg0,_arg1,*_arg2);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxHelpEvent_p");
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- const wxPoint & _result_ref = wxHelpEvent_GetPosition(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ const wxPoint & _result_ref = wxHelpEvent_GetPosition(_arg0);
_result = (wxPoint *) &_result_ref;
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPoint_p");
return NULL;
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpEvent_SetPosition(_arg0,*_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpEvent_SetPosition(_arg0,*_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- const wxString & _result_ref = wxHelpEvent_GetLink(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ const wxString & _result_ref = wxHelpEvent_GetLink(_arg0);
_result = (wxString *) &_result_ref;
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{
+#if wxUSE_UNICODE
+ _resultobj = PyUnicode_FromUnicode(_result->c_str(), _result->Len());
+#else
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
+#endif
}
return _resultobj;
}
}
}
{
-#if PYTHON_API_VERSION >= 1009
- char* tmpPtr; int tmpSize;
- if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
- return NULL;
- _arg1 = new wxString(tmpPtr, tmpSize);
-#else
- if (!PyString_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ _arg1 = wxString_in_helper(_obj1);
+ if (_arg1 == NULL)
return NULL;
- }
- _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
-#endif
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpEvent_SetLink(_arg0,*_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpEvent_SetLink(_arg0,*_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- const wxString & _result_ref = wxHelpEvent_GetTarget(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ const wxString & _result_ref = wxHelpEvent_GetTarget(_arg0);
_result = (wxString *) &_result_ref;
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{
+#if wxUSE_UNICODE
+ _resultobj = PyUnicode_FromUnicode(_result->c_str(), _result->Len());
+#else
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
+#endif
}
return _resultobj;
}
}
}
{
-#if PYTHON_API_VERSION >= 1009
- char* tmpPtr; int tmpSize;
- if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
- return NULL;
- _arg1 = new wxString(tmpPtr, tmpSize);
-#else
- if (!PyString_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ _arg1 = wxString_in_helper(_obj1);
+ if (_arg1 == NULL)
return NULL;
- }
- _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
-#endif
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpEvent_SetTarget(_arg0,*_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpEvent_SetTarget(_arg0,*_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
return NULL;
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxContextMenuEvent *)new_wxContextMenuEvent(_arg0,_arg1,*_arg2);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxContextMenuEvent *)new_wxContextMenuEvent(_arg0,_arg1,*_arg2);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxContextMenuEvent_p");
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- const wxPoint & _result_ref = wxContextMenuEvent_GetPosition(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ const wxPoint & _result_ref = wxContextMenuEvent_GetPosition(_arg0);
_result = (wxPoint *) &_result_ref;
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPoint_p");
return NULL;
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxContextMenuEvent_SetPosition(_arg0,*_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxContextMenuEvent_SetPosition(_arg0,*_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
_arg1 = (bool ) tempbool1;
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxContextHelp *)new_wxContextHelp(_arg0,_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxContextHelp *)new_wxContextHelp(_arg0,_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxContextHelp_p");
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- delete_wxContextHelp(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ delete_wxContextHelp(_arg0);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxContextHelp_BeginContextHelp(_arg0,_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (bool )wxContextHelp_BeginContextHelp(_arg0,_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxContextHelp_EndContextHelp(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (bool )wxContextHelp_EndContextHelp(_arg0);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
return NULL;
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxContextHelpButton *)new_wxContextHelpButton(_arg0,_arg1,*_arg2,*_arg3,_arg4);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxContextHelpButton *)new_wxContextHelpButton(_arg0,_arg1,*_arg2,*_arg3,_arg4);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxContextHelpButton_p");
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxHelpProvider *)wxHelpProvider::Set(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxHelpProvider *)wxHelpProvider::Set(_arg0);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxHelpProvider_p");
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxHelpProvider_Get",_kwnames))
return NULL;
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxHelpProvider *)wxHelpProvider::Get();
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxHelpProvider *)wxHelpProvider::Get();
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxHelpProvider_p");
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = new wxString (wxHelpProvider_GetHelp(_arg0,_arg1));
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = new wxString (wxHelpProvider_GetHelp(_arg0,_arg1));
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{
+#if wxUSE_UNICODE
+ _resultobj = PyUnicode_FromUnicode(_result->c_str(), _result->Len());
+#else
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
+#endif
}
{
delete _result;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxHelpProvider_ShowHelp(_arg0,_arg1);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (bool )wxHelpProvider_ShowHelp(_arg0,_arg1);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
}
{
-#if PYTHON_API_VERSION >= 1009
- char* tmpPtr; int tmpSize;
- if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
- return NULL;
- _arg2 = new wxString(tmpPtr, tmpSize);
-#else
- if (!PyString_Check(_obj2)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ _arg2 = wxString_in_helper(_obj2);
+ if (_arg2 == NULL)
return NULL;
- }
- _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
-#endif
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpProvider_AddHelp(_arg0,_arg1,*_arg2);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpProvider_AddHelp(_arg0,_arg1,*_arg2);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
}
{
-#if PYTHON_API_VERSION >= 1009
- char* tmpPtr; int tmpSize;
- if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
+ _arg2 = wxString_in_helper(_obj2);
+ if (_arg2 == NULL)
return NULL;
- _arg2 = new wxString(tmpPtr, tmpSize);
-#else
- if (!PyString_Check(_obj2)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- _arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
-#endif
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpProvider_AddHelpById(_arg0,_arg1,*_arg2);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpProvider_AddHelpById(_arg0,_arg1,*_arg2);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- wxHelpProvider_Destroy(_arg0);
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ wxHelpProvider_Destroy(_arg0);
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxSimpleHelpProvider",_kwnames))
return NULL;
{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxSimpleHelpProvider *)new_wxSimpleHelpProvider();
+ PyThreadState* __tstate = wxPyBeginAllowThreads();
+ _result = (wxSimpleHelpProvider *)new_wxSimpleHelpProvider();
- wxPy_END_ALLOW_THREADS;
+ wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxSimpleHelpProvider_p");
PyDict_SetItemString(d,"wxID_CONTEXT_HELP", PyInt_FromLong((long) wxID_CONTEXT_HELP));
PyDict_SetItemString(d,"wxEVT_HELP", PyInt_FromLong((long) wxEVT_HELP));
PyDict_SetItemString(d,"wxEVT_DETAILED_HELP", PyInt_FromLong((long) wxEVT_DETAILED_HELP));
- PyDict_SetItemString(d,"wxEVT_CONTEXT_MENU", PyInt_FromLong((long) wxEVT_CONTEXT_MENU));
{
int i;
for (i = 0; _swig_mapping[i].n1; i++)