X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/98624b49d3abd7ebc1d5f8df4209f563b3e3323f..742fc581e46beca2328551cdaec38c3dfca50cb1:/wxPython/src/msw/controls.cpp diff --git a/wxPython/src/msw/controls.cpp b/wxPython/src/msw/controls.cpp index f5c909de0e..7a1cb4bc7a 100644 --- a/wxPython/src/msw/controls.cpp +++ b/wxPython/src/msw/controls.cpp @@ -6463,6 +6463,39 @@ static PyObject *_wrap_wxTextCtrl_GetSelection(PyObject *self, PyObject *args, P return _resultobj; } +#define wxTextCtrl_GetStringSelection(_swigobj) (_swigobj->GetStringSelection()) +static PyObject *_wrap_wxTextCtrl_GetStringSelection(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxString * _result; + wxTextCtrl * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextCtrl_GetStringSelection",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTextCtrl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTextCtrl_GetStringSelection. Expected _wxTextCtrl_p."); + return NULL; + } + } +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = new wxString (wxTextCtrl_GetStringSelection(_arg0)); + + wxPy_END_ALLOW_THREADS; + if (PyErr_Occurred()) return NULL; +}{ + _resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len()); +} +{ + delete _result; +} + return _resultobj; +} + #define wxTextCtrl_Clear(_swigobj) (_swigobj->Clear()) static PyObject *_wrap_wxTextCtrl_Clear(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -11183,6 +11216,7 @@ static PyMethodDef controlscMethods[] = { { "wxTextCtrl_Remove", (PyCFunction) _wrap_wxTextCtrl_Remove, METH_VARARGS | METH_KEYWORDS }, { "wxTextCtrl_Replace", (PyCFunction) _wrap_wxTextCtrl_Replace, METH_VARARGS | METH_KEYWORDS }, { "wxTextCtrl_Clear", (PyCFunction) _wrap_wxTextCtrl_Clear, METH_VARARGS | METH_KEYWORDS }, + { "wxTextCtrl_GetStringSelection", (PyCFunction) _wrap_wxTextCtrl_GetStringSelection, METH_VARARGS | METH_KEYWORDS }, { "wxTextCtrl_GetSelection", (PyCFunction) _wrap_wxTextCtrl_GetSelection, METH_VARARGS | METH_KEYWORDS }, { "wxTextCtrl_IsEditable", (PyCFunction) _wrap_wxTextCtrl_IsEditable, METH_VARARGS | METH_KEYWORDS }, { "wxTextCtrl_IsModified", (PyCFunction) _wrap_wxTextCtrl_IsModified, METH_VARARGS | METH_KEYWORDS },