X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/211a46cf8271a93ad670effd0d2b742c6050f50f..c74d8df09d0c0e182cb2063cc4cc546de3a00fae:/wxPython/contrib/ogl/oglshapes2.i diff --git a/wxPython/contrib/ogl/oglshapes2.i b/wxPython/contrib/ogl/oglshapes2.i index a79ebca598..89d4ee8f06 100644 --- a/wxPython/contrib/ogl/oglshapes2.i +++ b/wxPython/contrib/ogl/oglshapes2.i @@ -47,8 +47,9 @@ class wxPyEllipseShape : public wxPyShape { public: wxPyEllipseShape(double width = 0.0, double height = 0.0); - void _setSelf(PyObject* self, PyObject* _class); - %pragma(python) addtomethod = "__init__:self._setSelf(self, wxPyEllipseShape)" + void _setCallbackInfo(PyObject* self, PyObject* _class); + %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyEllipseShape)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void base_OnDraw(wxDC& dc); void base_OnDrawContents(wxDC& dc); @@ -90,8 +91,9 @@ class wxPyCircleShape : public wxPyEllipseShape { public: wxPyCircleShape(double width = 0.0); - void _setSelf(PyObject* self, PyObject* _class); - %pragma(python) addtomethod = "__init__:self._setSelf(self, wxPyCircleShape)" + void _setCallbackInfo(PyObject* self, PyObject* _class); + %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyCircleShape)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void base_OnDraw(wxDC& dc); void base_OnDrawContents(wxDC& dc); @@ -125,7 +127,7 @@ public: }; //--------------------------------------------------------------------------- //--------------------------------------------------------------------------- -class wxArrowHead { +class wxArrowHead : public wxObject { public: wxArrowHead(int type = 0, int end = 0, @@ -162,8 +164,9 @@ class wxPyLineShape : public wxPyShape { public: wxPyLineShape(); - void _setSelf(PyObject* self, PyObject* _class); - %pragma(python) addtomethod = "__init__:self._setSelf(self, wxPyLineShape)" + void _setCallbackInfo(PyObject* self, PyObject* _class); + %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyLineShape)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void AddArrow(int type, int end = ARROW_POSITION_END, double arrowSize = 10.0, double xOffset = 0.0, @@ -207,8 +210,13 @@ public: bool IsSpline(); void MakeLineControlPoints(int n); - // TODO: // inline wxList *GetLineControlPoints() { return m_lineControlPoints; } + %addmethods { + PyObject* GetLineControlPoints() { + wxList* list = self->GetLineControlPoints(); + return wxPy_ConvertList(list, "wxPyControlPoint"); + } + } void SetAttachmentFrom(int fromAttach); void SetAttachments(int fromAttach, int toAttach); @@ -262,8 +270,9 @@ class wxPyPolygonShape : public wxPyShape { public: wxPyPolygonShape(); - void _setSelf(PyObject* self, PyObject* _class); - %pragma(python) addtomethod = "__init__:self._setSelf(self, wxPyPolygonShape)" + void _setCallbackInfo(PyObject* self, PyObject* _class); + %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyPolygonShape)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" // void Create(wxList* points); @@ -333,8 +342,9 @@ class wxPyTextShape : public wxPyRectangleShape { public: wxPyTextShape(double width = 0.0, double height = 0.0); - void _setSelf(PyObject* self, PyObject* _class); - %pragma(python) addtomethod = "__init__:self._setSelf(self, wxPyTextShape)" + void _setCallbackInfo(PyObject* self, PyObject* _class); + %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyTextShape)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void base_OnDelete();