]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/msw/wizard_wrap.cpp
trying to make GetData() return data format more clear
[wxWidgets.git] / wxPython / src / msw / wizard_wrap.cpp
index bc0c86b74505ef384bcae75eb7f7dff37910d667..43a58b397aa4529a6db075c2fbc49cb3ea87d359 100644 (file)
@@ -553,11 +553,12 @@ bool wxPyWizardPage_Create(wxPyWizardPage *self,wxWizard *parent,wxBitmap const
     } 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);      
 
@@ -567,7 +568,7 @@ bool wxPyWizardPage_Create(wxPyWizardPage *self,wxWizard *parent,wxBitmap const
         Py_DECREF(o3);
     }
     return target;
-}
+  }