]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/contrib/gizmos/gtk/gizmos_wrap.cpp
reSWIGged
[wxWidgets.git] / wxPython / contrib / gizmos / gtk / gizmos_wrap.cpp
index 1ef7ca74634a3da4fedafef0bf459ff7a1b60ab2..bb74927d3c4e1dbee4f5e978b5cb3cbf150a7e66 100644 (file)
@@ -790,11 +790,12 @@ PyObject *wxPyTreeListCtrl_GetNextChild(wxPyTreeListCtrl *self,wxTreeItemId cons
     } else if (target == Py_None) {  
         Py_DECREF(Py_None);
         target = o;
-    } else {                         
-        o2 = target;
-        target = PyTuple_New(1);
-        PyTuple_SetItem(target, 0, o2);
-
+    } else {
+        if (!PyTuple_Check(target)) {
+            o2 = target;
+            target = PyTuple_New(1);
+            PyTuple_SetItem(target, 0, o2);
+        }            
         o3 = PyTuple_New(1);            
         PyTuple_SetItem(o3, 0, o);      
 
@@ -804,7 +805,7 @@ PyObject *wxPyTreeListCtrl_GetNextChild(wxPyTreeListCtrl *self,wxTreeItemId cons
         Py_DECREF(o3);
     }
     return target;
-}
+  }
 
 
 PyObject *wxPyTreeListCtrl_GetBoundingRect(wxPyTreeListCtrl *self,wxTreeItemId const &item,bool textOnly){