]> git.saurik.com Git - wxWidgets.git/commitdiff
Some typemap updates
authorRobin Dunn <robin@alldunn.com>
Mon, 24 Jun 2002 23:55:30 +0000 (23:55 +0000)
committerRobin Dunn <robin@alldunn.com>
Mon, 24 Jun 2002 23:55:30 +0000 (23:55 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15952 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/contrib/gizmos/gizmos.cpp
wxPython/contrib/gizmos/gizmos.i
wxPython/contrib/gizmos/gizmos.py
wxPython/src/my_typemaps.i

index 7e948992682b9c93b9927d8f0755bc5b46af3049..f92d609908eefedde0251d794b880326e9eb8df4 100644 (file)
@@ -60,6 +60,7 @@ extern PyObject *SWIG_newvarlink(void);
 #include <wx/gizmos/editlbox.h>
 #include <wx/gizmos/splittree.h>
 #include <wx/gizmos/ledctrl.h>
+#include <wx/listctrl.h>
 
 
 static PyObject* t_output_helper(PyObject* target, PyObject* o) {
@@ -723,7 +724,6 @@ static PyObject *_wrap_wxEditableListBox_GetListCtrl(PyObject *self, PyObject *a
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetListCtrl",_kwnames,&_argo0)) 
@@ -741,13 +741,7 @@ static PyObject *_wrap_wxEditableListBox_GetListCtrl(PyObject *self, PyObject *a
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
@@ -758,7 +752,6 @@ static PyObject *_wrap_wxEditableListBox_GetDelButton(PyObject *self, PyObject *
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetDelButton",_kwnames,&_argo0)) 
@@ -776,13 +769,7 @@ static PyObject *_wrap_wxEditableListBox_GetDelButton(PyObject *self, PyObject *
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
@@ -793,7 +780,6 @@ static PyObject *_wrap_wxEditableListBox_GetNewButton(PyObject *self, PyObject *
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetNewButton",_kwnames,&_argo0)) 
@@ -811,13 +797,7 @@ static PyObject *_wrap_wxEditableListBox_GetNewButton(PyObject *self, PyObject *
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
@@ -828,7 +808,6 @@ static PyObject *_wrap_wxEditableListBox_GetUpButton(PyObject *self, PyObject *a
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetUpButton",_kwnames,&_argo0)) 
@@ -846,13 +825,7 @@ static PyObject *_wrap_wxEditableListBox_GetUpButton(PyObject *self, PyObject *a
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
@@ -863,7 +836,6 @@ static PyObject *_wrap_wxEditableListBox_GetDownButton(PyObject *self, PyObject
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetDownButton",_kwnames,&_argo0)) 
@@ -881,13 +853,7 @@ static PyObject *_wrap_wxEditableListBox_GetDownButton(PyObject *self, PyObject
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
@@ -898,7 +864,6 @@ static PyObject *_wrap_wxEditableListBox_GetEditButton(PyObject *self, PyObject
     wxEditableListBox * _arg0;
     PyObject * _argo0 = 0;
     char *_kwnames[] = { "self", NULL };
-    char _ptemp[128];
 
     self = self;
     if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxEditableListBox_GetEditButton",_kwnames,&_argo0)) 
@@ -916,13 +881,7 @@ static PyObject *_wrap_wxEditableListBox_GetEditButton(PyObject *self, PyObject
 
     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;
-    }
+}{ _resultobj = wxPyMake_wxObject(_result); }
     return _resultobj;
 }
 
index 466d181c478acd7ee1438a9415760c44968cff1d..48b33f4e7c588f80092fb2258b30ba713f26ca7d 100644 (file)
@@ -19,6 +19,7 @@
 #include <wx/gizmos/editlbox.h>
 #include <wx/gizmos/splittree.h>
 #include <wx/gizmos/ledctrl.h>
+#include <wx/listctrl.h>
 %}
 
 //---------------------------------------------------------------------------
index c96190872e561bc9553e50be03ecb8585eed1ed1..dfb3f66d85825f2b09be7ce8b9c99ad695e403b4 100644 (file)
@@ -121,27 +121,21 @@ class wxEditableListBoxPtr(wxPanelPtr):
         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,)
index d32602247b1747aef39bc6485a286880cd848817..91fb0ada9600bb03569f0012d065e3b5cdc63fbe 100644 (file)
@@ -383,10 +383,12 @@ $function
 %typemap(python, out) wxToolTip*                { $target = wxPyMake_wxObject($source); }
 
 
+%typemap(python, out) wxBitmapButton*           { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxButton*                 { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxControl*                { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxFrame*                  { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxGrid*                   { $target = wxPyMake_wxObject($source); }
+%typemap(python, out) wxListCtrl*               { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxMDIChildFrame*          { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxMDIClientWindow*        { $target = wxPyMake_wxObject($source); }
 %typemap(python, out) wxMenuBar*                { $target = wxPyMake_wxObject($source); }