Added component control accessors to wxEditableListBox

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15946 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn 2002-06-24 21:51:06 +00:00
parent 009f8ef4a3
commit 366d7bd615
4 changed files with 254 additions and 0 deletions

View File

@ -50,6 +50,13 @@ public:
void SetStrings(const wxArrayString& strings);
void GetStrings(wxArrayString& strings);
wxListCtrl* GetListCtrl() { return m_listCtrl; }
wxBitmapButton* GetDelButton() { return m_bDel; }
wxBitmapButton* GetNewButton() { return m_bNew; }
wxBitmapButton* GetUpButton() { return m_bUp; }
wxBitmapButton* GetDownButton() { return m_bDown; }
wxBitmapButton* GetEditButton() { return m_bEdit; }
protected:
wxBitmapButton *m_bDel, *m_bNew, *m_bUp, *m_bDown, *m_bEdit;
wxListCtrl *m_listCtrl;

View File

@ -716,6 +716,216 @@ static PyObject *_wrap_wxEditableListBox_GetStrings(PyObject *self, PyObject *ar
return _resultobj;
}
#define wxEditableListBox_GetListCtrl(_swigobj) (_swigobj->GetListCtrl())
static PyObject *_wrap_wxEditableListBox_GetListCtrl(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxListCtrl * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetListCtrl",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetListCtrl. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxListCtrl *)wxEditableListBox_GetListCtrl(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxListCtrl_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define wxEditableListBox_GetDelButton(_swigobj) (_swigobj->GetDelButton())
static PyObject *_wrap_wxEditableListBox_GetDelButton(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmapButton * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetDelButton",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetDelButton. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxBitmapButton *)wxEditableListBox_GetDelButton(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmapButton_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define wxEditableListBox_GetNewButton(_swigobj) (_swigobj->GetNewButton())
static PyObject *_wrap_wxEditableListBox_GetNewButton(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmapButton * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetNewButton",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetNewButton. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxBitmapButton *)wxEditableListBox_GetNewButton(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmapButton_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define wxEditableListBox_GetUpButton(_swigobj) (_swigobj->GetUpButton())
static PyObject *_wrap_wxEditableListBox_GetUpButton(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmapButton * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetUpButton",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetUpButton. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxBitmapButton *)wxEditableListBox_GetUpButton(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmapButton_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define wxEditableListBox_GetDownButton(_swigobj) (_swigobj->GetDownButton())
static PyObject *_wrap_wxEditableListBox_GetDownButton(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmapButton * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetDownButton",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetDownButton. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxBitmapButton *)wxEditableListBox_GetDownButton(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmapButton_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define wxEditableListBox_GetEditButton(_swigobj) (_swigobj->GetEditButton())
static PyObject *_wrap_wxEditableListBox_GetEditButton(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmapButton * _result;
wxEditableListBox * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetEditButton",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEditableListBox_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEditableListBox_GetEditButton. Expected _wxEditableListBox_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxBitmapButton *)wxEditableListBox_GetEditButton(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmapButton_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
static void *SwigwxRemotelyScrolledTreeCtrlTowxPyTreeCtrl(void *ptr) {
wxRemotelyScrolledTreeCtrl *src;
wxPyTreeCtrl *dest;
@ -1760,6 +1970,12 @@ static PyMethodDef gizmoscMethods[] = {
{ "wxRemotelyScrolledTreeCtrl_AdjustRemoteScrollbars", (PyCFunction) _wrap_wxRemotelyScrolledTreeCtrl_AdjustRemoteScrollbars, METH_VARARGS | METH_KEYWORDS },
{ "wxRemotelyScrolledTreeCtrl_HideVScrollbar", (PyCFunction) _wrap_wxRemotelyScrolledTreeCtrl_HideVScrollbar, METH_VARARGS | METH_KEYWORDS },
{ "new_wxRemotelyScrolledTreeCtrl", (PyCFunction) _wrap_new_wxRemotelyScrolledTreeCtrl, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetEditButton", (PyCFunction) _wrap_wxEditableListBox_GetEditButton, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetDownButton", (PyCFunction) _wrap_wxEditableListBox_GetDownButton, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetUpButton", (PyCFunction) _wrap_wxEditableListBox_GetUpButton, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetNewButton", (PyCFunction) _wrap_wxEditableListBox_GetNewButton, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetDelButton", (PyCFunction) _wrap_wxEditableListBox_GetDelButton, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetListCtrl", (PyCFunction) _wrap_wxEditableListBox_GetListCtrl, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_GetStrings", (PyCFunction) _wrap_wxEditableListBox_GetStrings, METH_VARARGS | METH_KEYWORDS },
{ "wxEditableListBox_SetStrings", (PyCFunction) _wrap_wxEditableListBox_SetStrings, METH_VARARGS | METH_KEYWORDS },
{ "new_wxEditableListBox", (PyCFunction) _wrap_new_wxEditableListBox, METH_VARARGS | METH_KEYWORDS },

View File

@ -193,6 +193,13 @@ public:
return wxArrayString2PyList_helper(strings);
}
}
wxListCtrl* GetListCtrl() { return m_listCtrl; }
wxBitmapButton* GetDelButton() { return m_bDel; }
wxBitmapButton* GetNewButton() { return m_bNew; }
wxBitmapButton* GetUpButton() { return m_bUp; }
wxBitmapButton* GetDownButton() { return m_bDown; }
wxBitmapButton* GetEditButton() { return m_bEdit; }
};

View File

@ -119,6 +119,30 @@ class wxEditableListBoxPtr(wxPanelPtr):
def GetStrings(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetStrings,(self,) + _args, _kwargs)
return val
def GetListCtrl(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetListCtrl,(self,) + _args, _kwargs)
if val: val = wxListCtrlPtr(val)
return val
def GetDelButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetDelButton,(self,) + _args, _kwargs)
if val: val = wxBitmapButtonPtr(val)
return val
def GetNewButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetNewButton,(self,) + _args, _kwargs)
if val: val = wxBitmapButtonPtr(val)
return val
def GetUpButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetUpButton,(self,) + _args, _kwargs)
if val: val = wxBitmapButtonPtr(val)
return val
def GetDownButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetDownButton,(self,) + _args, _kwargs)
if val: val = wxBitmapButtonPtr(val)
return val
def GetEditButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetEditButton,(self,) + _args, _kwargs)
if val: val = wxBitmapButtonPtr(val)
return val
def __repr__(self):
return "<C wxEditableListBox instance at %s>" % (self.this,)
class wxEditableListBox(wxEditableListBoxPtr):