X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c8bc7bb84dcca816055d5876e4772551c48acda5..a4353f07c6b37712634d4b2d86527b647a08044f:/wxPython/src/msw/sizers.cpp?ds=sidebyside diff --git a/wxPython/src/msw/sizers.cpp b/wxPython/src/msw/sizers.cpp index 5bddf40caf..79841577fe 100644 --- a/wxPython/src/msw/sizers.cpp +++ b/wxPython/src/msw/sizers.cpp @@ -860,7 +860,7 @@ static void *SwigwxSizerTowxObject(void *ptr) { } static void wxSizer__setOORInfo(wxSizer *self,PyObject * _self) { - self->SetClientObject(new wxPyClientData(_self)); + self->SetClientObject(new wxPyOORClientData(_self)); } static PyObject *_wrap_wxSizer__setOORInfo(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -1755,11 +1755,13 @@ static PyObject *_wrap_wxSizer_Layout(PyObject *self, PyObject *args, PyObject * #define wxSizer_Fit(_swigobj,_swigarg0) (_swigobj->Fit(_swigarg0)) static PyObject *_wrap_wxSizer_Fit(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; + wxSize * _result; wxSizer * _arg0; wxWindow * _arg1; PyObject * _argo0 = 0; PyObject * _argo1 = 0; char *_kwnames[] = { "self","window", NULL }; + char _ptemp[128]; self = self; if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxSizer_Fit",_kwnames,&_argo0,&_argo1)) @@ -1780,7 +1782,44 @@ static PyObject *_wrap_wxSizer_Fit(PyObject *self, PyObject *args, PyObject *kwa } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - wxSizer_Fit(_arg0,_arg1); + _result = new wxSize (wxSizer_Fit(_arg0,_arg1)); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} SWIG_MakePtr(_ptemp, (void *) _result,"_wxSize_p"); + _resultobj = Py_BuildValue("s",_ptemp); + return _resultobj; +} + +#define wxSizer_FitInside(_swigobj,_swigarg0) (_swigobj->FitInside(_swigarg0)) +static PyObject *_wrap_wxSizer_FitInside(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxSizer * _arg0; + wxWindow * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","window", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxSizer_FitInside",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxSizer_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxSizer_FitInside. Expected _wxSizer_p."); + return NULL; + } + } + if (_argo1) { + if (_argo1 == Py_None) { _arg1 = NULL; } + else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxSizer_FitInside. Expected _wxWindow_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxSizer_FitInside(_arg0,_arg1); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) return NULL; @@ -1826,6 +1865,43 @@ static PyObject *_wrap_wxSizer_SetSizeHints(PyObject *self, PyObject *args, PyOb return _resultobj; } +#define wxSizer_SetVirtualSizeHints(_swigobj,_swigarg0) (_swigobj->SetVirtualSizeHints(_swigarg0)) +static PyObject *_wrap_wxSizer_SetVirtualSizeHints(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxSizer * _arg0; + wxWindow * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","window", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxSizer_SetVirtualSizeHints",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxSizer_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxSizer_SetVirtualSizeHints. Expected _wxSizer_p."); + return NULL; + } + } + if (_argo1) { + if (_argo1 == Py_None) { _arg1 = NULL; } + else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxSizer_SetVirtualSizeHints. Expected _wxWindow_p."); + return NULL; + } + } +{ + PyThreadState* __tstate = wxPyBeginAllowThreads(); + wxSizer_SetVirtualSizeHints(_arg0,_arg1); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxSizer_Clear(_swigobj,_swigarg0) (_swigobj->Clear(_swigarg0)) static PyObject *_wrap_wxSizer_Clear(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -3006,7 +3082,9 @@ static PyMethodDef sizerscMethods[] = { { "wxSizer_GetChildren", (PyCFunction) _wrap_wxSizer_GetChildren, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_DeleteWindows", (PyCFunction) _wrap_wxSizer_DeleteWindows, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_Clear", (PyCFunction) _wrap_wxSizer_Clear, METH_VARARGS | METH_KEYWORDS }, + { "wxSizer_SetVirtualSizeHints", (PyCFunction) _wrap_wxSizer_SetVirtualSizeHints, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_SetSizeHints", (PyCFunction) _wrap_wxSizer_SetSizeHints, METH_VARARGS | METH_KEYWORDS }, + { "wxSizer_FitInside", (PyCFunction) _wrap_wxSizer_FitInside, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_Fit", (PyCFunction) _wrap_wxSizer_Fit, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_Layout", (PyCFunction) _wrap_wxSizer_Layout, METH_VARARGS | METH_KEYWORDS }, { "wxSizer_GetMinSize", (PyCFunction) _wrap_wxSizer_GetMinSize, METH_VARARGS | METH_KEYWORDS },