X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0122b7e3fcfd78f879470053c91a60e3c66537a3..f9ee64b1356530b7f5c957d250d2a1dcbef60f60:/wxPython/src/sizers.i diff --git a/wxPython/src/sizers.i b/wxPython/src/sizers.i index c1a6c05373..a43993df98 100644 --- a/wxPython/src/sizers.i +++ b/wxPython/src/sizers.i @@ -43,6 +43,8 @@ public: //wxSizerItem( wxWindow *window, int option, int flag, int border, wxObject* userData ); //wxSizerItem( wxSizer *sizer, int option, int flag, int border, wxObject* userData ); + void DeleteWindows(); + wxPoint GetPosition(); wxSize GetSize(); wxSize CalcMin(); @@ -93,6 +95,12 @@ public: // wxSizer(); **** abstract, can't instantiate // ~wxSizer(); + %addmethods { + void _setOORInfo(PyObject* _self) { + self->SetClientObject(new wxPyClientData(_self)); + } + } + %addmethods { void Destroy() { delete self; } @@ -231,6 +239,10 @@ public: void Fit( wxWindow *window ); void SetSizeHints( wxWindow *window ); + void Clear( bool delete_windows=FALSE ); + void DeleteWindows(); + + // wxList& GetChildren(); %addmethods { PyObject* GetChildren() { @@ -268,6 +280,7 @@ public: wxPySizer(); void _setCallbackInfo(PyObject* self, PyObject* _class); %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPySizer)" + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" }; @@ -276,6 +289,7 @@ public: class wxBoxSizer : public wxSizer { public: wxBoxSizer(int orient = wxHORIZONTAL); + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" int GetOrientation(); void RecalcSizes(); wxSize CalcMin(); @@ -286,6 +300,7 @@ public: class wxStaticBoxSizer : public wxBoxSizer { public: wxStaticBoxSizer(wxStaticBox *box, int orient = wxHORIZONTAL); + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" wxStaticBox *GetStaticBox(); void RecalcSizes(); wxSize CalcMin(); @@ -296,10 +311,9 @@ public: class wxNotebookSizer: public wxSizer { public: wxNotebookSizer( wxNotebook *nb ); - + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void RecalcSizes(); wxSize CalcMin(); - wxNotebook *GetNotebook(); }; @@ -309,6 +323,7 @@ class wxGridSizer: public wxSizer { public: wxGridSizer( int rows=1, int cols=0, int vgap=0, int hgap=0 ); + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void RecalcSizes(); wxSize CalcMin(); @@ -329,6 +344,7 @@ class wxFlexGridSizer: public wxGridSizer { public: wxFlexGridSizer( int rows=1, int cols=0, int vgap=0, int hgap=0 ); + %pragma(python) addtomethod = "__init__:self._setOORInfo(self)" void RecalcSizes(); wxSize CalcMin();