X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4dfaa61e60c3f7bf781d22687fffe2453d97d008..08a092f9f4de6c80a2d43d4072c379ac84e6cc2f:/wxPython/src/gtk/cmndlgs.cpp diff --git a/wxPython/src/gtk/cmndlgs.cpp b/wxPython/src/gtk/cmndlgs.cpp index 1bb34a9cd0..5aacee4060 100644 --- a/wxPython/src/gtk/cmndlgs.cpp +++ b/wxPython/src/gtk/cmndlgs.cpp @@ -207,18 +207,12 @@ static PyObject *_wrap_wxColourData_GetColour(PyObject *self, PyObject *args, Py } { wxPy_BEGIN_ALLOW_THREADS; - wxColour & _result_ref = wxColourData_GetColour(_arg0); - _result = (wxColour *) &_result_ref; + _result = new wxColour (wxColourData_GetColour(_arg0)); wxPy_END_ALLOW_THREADS; if (PyErr_Occurred()) return NULL; -} if (_result) { - SWIG_MakePtr(_ptemp, (char *) _result,"_wxColour_p"); - _resultobj = Py_BuildValue("s",_ptemp); - } else { - Py_INCREF(Py_None); - _resultobj = Py_None; - } +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); return _resultobj; } @@ -2171,18 +2165,12 @@ static PyObject *_wrap_wxFontData_GetColour(PyObject *self, PyObject *args, PyOb } { wxPy_BEGIN_ALLOW_THREADS; - wxColour & _result_ref = wxFontData_GetColour(_arg0); - _result = (wxColour *) &_result_ref; + _result = new wxColour (wxFontData_GetColour(_arg0)); wxPy_END_ALLOW_THREADS; if (PyErr_Occurred()) return NULL; -} if (_result) { - SWIG_MakePtr(_ptemp, (char *) _result,"_wxColour_p"); - _resultobj = Py_BuildValue("s",_ptemp); - } else { - Py_INCREF(Py_None); - _resultobj = Py_None; - } +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxColour_p"); + _resultobj = Py_BuildValue("s",_ptemp); return _resultobj; }