From 3bcd5e1c64a85bee7005dcb65bee98784dad1f0f Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Thu, 18 Oct 2001 19:26:06 +0000 Subject: [PATCH] An incorrect patch to SWIG caused incorrect generated code. Fixed and regenerated. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12063 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/contrib/glcanvas/gtk/glcanvas.cpp | 61 +-- wxPython/contrib/xrc/xrc.cpp | 5 +- wxPython/src/gtk/calendar.cpp | 64 +-- wxPython/src/gtk/clip_dnd.cpp | 115 +----- wxPython/src/gtk/cmndlgs.cpp | 196 +-------- wxPython/src/gtk/controls.cpp | 328 +-------------- wxPython/src/gtk/controls2.cpp | 112 +---- wxPython/src/gtk/events.cpp | 268 +----------- wxPython/src/gtk/filesys.cpp | 76 +--- wxPython/src/gtk/frames.cpp | 106 +---- wxPython/src/gtk/gdi.cpp | 459 ++++++++++++++------- wxPython/src/gtk/gdi.py | 28 ++ wxPython/src/gtk/grid.cpp | 196 +-------- wxPython/src/gtk/help.cpp | 85 +--- wxPython/src/gtk/html.cpp | 179 +++----- wxPython/src/gtk/html.py | 3 + wxPython/src/gtk/htmlhelp.cpp | 64 +-- wxPython/src/gtk/image.cpp | 91 +--- wxPython/src/gtk/mdi.cpp | 82 +--- wxPython/src/gtk/misc.cpp | 55 +-- wxPython/src/gtk/misc2.cpp | 91 +--- wxPython/src/gtk/printfw.cpp | 106 +---- wxPython/src/gtk/sizers.cpp | 91 +--- wxPython/src/gtk/stattool.cpp | 129 +----- wxPython/src/gtk/streams.cpp | 43 +- wxPython/src/gtk/utils.cpp | 49 +-- wxPython/src/gtk/windows.cpp | 106 +---- wxPython/src/gtk/windows2.cpp | 85 +--- wxPython/src/gtk/windows3.cpp | 109 +---- wxPython/src/gtk/wx.cpp | 49 +-- 30 files changed, 735 insertions(+), 2696 deletions(-) diff --git a/wxPython/contrib/glcanvas/gtk/glcanvas.cpp b/wxPython/contrib/glcanvas/gtk/glcanvas.cpp index a03a8a72b7..e25b0d7089 100644 --- a/wxPython/contrib/glcanvas/gtk/glcanvas.cpp +++ b/wxPython/contrib/glcanvas/gtk/glcanvas.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -61,47 +63,28 @@ extern PyObject *SWIG_newvarlink(void); #endif -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -798,15 +781,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxGLCanvas",SwigwxGLCanvasTowxEvtHandler}, - { "_class_wxEvtHandler","_wxGLCanvas",SwigwxGLCanvasTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxGLCanvas",SwigwxGLCanvasTowxObject}, - { "_class_wxObject","_wxGLCanvas",SwigwxGLCanvasTowxObject}, - { "_class_wxObject","_class_wxGLContext",SwigwxGLContextTowxObject}, - { "_class_wxObject","_wxGLContext",SwigwxGLContextTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -814,7 +791,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxPanel","_class_wxGLCanvas",SwigwxGLCanvasTowxPanel}, { "_wxPanel","_wxGLCanvas",SwigwxGLCanvasTowxPanel}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, @@ -833,8 +809,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxPanel","_class_wxGLCanvas",SwigwxGLCanvasTowxPanel}, - { "_class_wxPanel","_wxGLCanvas",SwigwxGLCanvasTowxPanel}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, @@ -847,15 +821,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxGLCanvas",SwigwxGLCanvasTowxWindow}, - { "_class_wxWindow","_wxGLCanvas",SwigwxGLCanvasTowxWindow}, - { "_wxObject","_class_wxGLCanvas",SwigwxGLCanvasTowxObject}, { "_wxObject","_wxGLCanvas",SwigwxGLCanvasTowxObject}, - { "_wxObject","_class_wxGLContext",SwigwxGLContextTowxObject}, { "_wxObject","_wxGLContext",SwigwxGLContextTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, - { "_wxScrolledWindow","_class_wxGLCanvas",SwigwxGLCanvasTowxScrolledWindow}, { "_wxScrolledWindow","_wxGLCanvas",SwigwxGLCanvasTowxScrolledWindow}, { "_unsigned_char","_byte",0}, { "_unsigned_int","_wxCoord",0}, @@ -906,11 +875,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxGLCanvas",SwigwxGLCanvasTowxEvtHandler}, { "_wxEvtHandler","_wxGLCanvas",SwigwxGLCanvasTowxEvtHandler}, - { "_class_wxScrolledWindow","_class_wxGLCanvas",SwigwxGLCanvasTowxScrolledWindow}, - { "_class_wxScrolledWindow","_wxGLCanvas",SwigwxGLCanvasTowxScrolledWindow}, - { "_wxWindow","_class_wxGLCanvas",SwigwxGLCanvasTowxWindow}, { "_wxWindow","_wxGLCanvas",SwigwxGLCanvasTowxWindow}, {0,0,0}}; diff --git a/wxPython/contrib/xrc/xrc.cpp b/wxPython/contrib/xrc/xrc.cpp index fe59e6ea96..53fa3da578 100644 --- a/wxPython/contrib/xrc/xrc.cpp +++ b/wxPython/contrib/xrc/xrc.cpp @@ -88,7 +88,7 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) { #if PYTHON_API_VERSION >= 1009 static char* wxStringErrorMsg = "String or Unicode type required"; #else - static char* wxStringErrorMsg = "string type is required for parameter"; + static char* wxStringErrorMsg = "String type required"; #endif #ifdef __cplusplus extern "C" { @@ -1167,8 +1167,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxXmlResource",SwigwxXmlResourceTowxObject}, - { "_class_wxObject","_wxXmlResource",SwigwxXmlResourceTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -1205,7 +1203,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxXmlResource",SwigwxXmlResourceTowxObject}, { "_wxObject","_wxXmlResource",SwigwxXmlResourceTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, diff --git a/wxPython/src/gtk/calendar.cpp b/wxPython/src/gtk/calendar.cpp index b7d9abc37b..eb0f903cf0 100644 --- a/wxPython/src/gtk/calendar.cpp +++ b/wxPython/src/gtk/calendar.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -56,47 +58,28 @@ extern PyObject *SWIG_newvarlink(void); #include "export.h" #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -1821,7 +1804,6 @@ static PyMethodDef calendarcMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxCalendarEvent",SwigwxCalendarEventTowxEvent}, { "_wxEvent","_wxCalendarEvent",SwigwxCalendarEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -1833,15 +1815,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxCalendarCtrl",SwigwxCalendarCtrlTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxObject}, - { "_class_wxObject","_wxCalendarCtrl",SwigwxCalendarCtrlTowxObject}, - { "_class_wxObject","_class_wxCalendarEvent",SwigwxCalendarEventTowxObject}, - { "_class_wxObject","_wxCalendarEvent",SwigwxCalendarEventTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -1857,9 +1833,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxCalendarEvent",SwigwxCalendarEventTowxEvent}, - { "_class_wxEvent","_wxCalendarEvent",SwigwxCalendarEventTowxEvent}, - { "_wxCommandEvent","_class_wxCalendarEvent",SwigwxCalendarEventTowxCommandEvent}, { "_wxCommandEvent","_wxCalendarEvent",SwigwxCalendarEventTowxCommandEvent}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, @@ -1882,16 +1855,11 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxWindow}, - { "_class_wxWindow","_wxCalendarCtrl",SwigwxCalendarCtrlTowxWindow}, - { "_wxObject","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxObject}, { "_wxObject","_wxCalendarCtrl",SwigwxCalendarCtrlTowxObject}, - { "_wxObject","_class_wxCalendarEvent",SwigwxCalendarEventTowxObject}, { "_wxObject","_wxCalendarEvent",SwigwxCalendarEventTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxControl}, { "_wxControl","_wxCalendarCtrl",SwigwxCalendarCtrlTowxControl}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -1932,8 +1900,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_class_wxControl","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxControl}, - { "_class_wxControl","_wxCalendarCtrl",SwigwxCalendarCtrlTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -1943,11 +1909,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxCalendarEvent",SwigwxCalendarEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxCalendarEvent",SwigwxCalendarEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxEvtHandler}, { "_wxEvtHandler","_wxCalendarCtrl",SwigwxCalendarCtrlTowxEvtHandler}, - { "_wxWindow","_class_wxCalendarCtrl",SwigwxCalendarCtrlTowxWindow}, { "_wxWindow","_wxCalendarCtrl",SwigwxCalendarCtrlTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/clip_dnd.cpp b/wxPython/src/gtk/clip_dnd.cpp index efb14aaad4..0ca77005a4 100644 --- a/wxPython/src/gtk/clip_dnd.cpp +++ b/wxPython/src/gtk/clip_dnd.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -58,47 +60,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -3464,7 +3447,6 @@ static PyMethodDef clip_dndcMethods[] = { */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_long","_long",0}, - { "_wxBitmapDataObject","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxBitmapDataObject}, { "_wxBitmapDataObject","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxBitmapDataObject}, { "_wxPrintQuality","_wxCoord",0}, { "_wxPrintQuality","_int",0}, @@ -3476,44 +3458,24 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, { "_byte","_unsigned_char",0}, - { "_wxDataObject","_class_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObject}, { "_wxDataObject","_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxFileDataObject",SwigwxFileDataObjectTowxDataObject}, { "_wxDataObject","_wxFileDataObject",SwigwxFileDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObject}, { "_wxDataObject","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObject}, { "_wxDataObject","_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObject}, { "_wxDataObject","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxTextDataObject",SwigwxTextDataObjectTowxDataObject}, { "_wxDataObject","_wxTextDataObject",SwigwxTextDataObjectTowxDataObject}, - { "_wxDataObject","_class_wxDataObjectComposite",SwigwxDataObjectCompositeTowxDataObject}, { "_wxDataObject","_wxDataObjectComposite",SwigwxDataObjectCompositeTowxDataObject}, - { "_wxDataObject","_class_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObject}, { "_wxDataObject","_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObject}, - { "_wxDataObject","_class_wxDataObjectSimple",SwigwxDataObjectSimpleTowxDataObject}, { "_wxDataObject","_wxDataObjectSimple",SwigwxDataObjectSimpleTowxDataObject}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_wxDataObjectSimple","_class_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxFileDataObject",SwigwxFileDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxFileDataObject",SwigwxFileDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxTextDataObject",SwigwxTextDataObjectTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxTextDataObject",SwigwxTextDataObjectTowxDataObjectSimple}, - { "_wxDataObjectSimple","_class_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObjectSimple}, { "_wxDataObjectSimple","_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObjectSimple}, - { "_class_wxBitmapDataObject","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxBitmapDataObject}, - { "_class_wxBitmapDataObject","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxBitmapDataObject}, - { "_class_wxObject","_class_wxClipboard",SwigwxClipboardTowxObject}, - { "_class_wxObject","_wxClipboard",SwigwxClipboardTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -3521,40 +3483,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTextDataObject","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject}, { "_wxTextDataObject","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject}, - { "_class_wxDataObject","_class_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxFileDataObject",SwigwxFileDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxFileDataObject",SwigwxFileDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxTextDataObject",SwigwxTextDataObjectTowxDataObject}, - { "_class_wxDataObject","_wxTextDataObject",SwigwxTextDataObjectTowxDataObject}, - { "_class_wxDataObject","_class_wxDataObjectComposite",SwigwxDataObjectCompositeTowxDataObject}, - { "_class_wxDataObject","_wxDataObjectComposite",SwigwxDataObjectCompositeTowxDataObject}, - { "_class_wxDataObject","_class_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObject}, - { "_class_wxDataObject","_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObject}, - { "_class_wxDataObject","_class_wxDataObjectSimple",SwigwxDataObjectSimpleTowxDataObject}, - { "_class_wxDataObject","_wxDataObjectSimple",SwigwxDataObjectSimpleTowxDataObject}, - { "_class_wxDataObjectSimple","_class_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxCustomDataObject",SwigwxCustomDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxFileDataObject",SwigwxFileDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxFileDataObject",SwigwxFileDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxPyBitmapDataObject",SwigwxPyBitmapDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxBitmapDataObject",SwigwxBitmapDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxTextDataObject",SwigwxTextDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxTextDataObject",SwigwxTextDataObjectTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_class_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObjectSimple}, - { "_class_wxDataObjectSimple","_wxPyDataObjectSimple",SwigwxPyDataObjectSimpleTowxDataObjectSimple}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, { "_uint","_time_t",0}, @@ -3565,21 +3494,14 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxChar","_char",0}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, - { "_wxDropTarget","_class_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxDropTarget}, { "_wxDropTarget","_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxDropTarget}, - { "_wxDropTarget","_class_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxDropTarget}, { "_wxDropTarget","_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxDropTarget}, - { "_wxDropTarget","_class_wxPyDropTarget",SwigwxPyDropTargetTowxDropTarget}, { "_wxDropTarget","_wxPyDropTarget",SwigwxPyDropTargetTowxDropTarget}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, { "_EBool","_signed_int",0}, { "_EBool","_int",0}, { "_EBool","_wxWindowID",0}, - { "_class_wxPyDropTarget","_class_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget}, - { "_class_wxPyDropTarget","_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget}, - { "_class_wxPyDropTarget","_class_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxPyDropTarget}, - { "_class_wxPyDropTarget","_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxPyDropTarget}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, { "_signed_int","_wxCoord",0}, @@ -3587,20 +3509,11 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTextDataObject","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject}, - { "_class_wxTextDataObject","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, - { "_class_wxDropTarget","_class_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxDropTarget}, - { "_class_wxDropTarget","_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxDropTarget}, - { "_class_wxDropTarget","_class_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxDropTarget}, - { "_class_wxDropTarget","_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxDropTarget}, - { "_class_wxDropTarget","_class_wxPyDropTarget",SwigwxPyDropTargetTowxDropTarget}, - { "_class_wxDropTarget","_wxPyDropTarget",SwigwxPyDropTargetTowxDropTarget}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxClipboard",SwigwxClipboardTowxObject}, { "_wxObject","_wxClipboard",SwigwxClipboardTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -3649,9 +3562,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxPyDropTarget","_class_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget}, { "_wxPyDropTarget","_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget}, - { "_wxPyDropTarget","_class_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxPyDropTarget}, { "_wxPyDropTarget","_wxPyTextDropTarget",SwigwxPyTextDropTargetTowxPyDropTarget}, {0,0,0}}; diff --git a/wxPython/src/gtk/cmndlgs.cpp b/wxPython/src/gtk/cmndlgs.cpp index cc148c941d..65a415adf6 100644 --- a/wxPython/src/gtk/cmndlgs.cpp +++ b/wxPython/src/gtk/cmndlgs.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -60,47 +62,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -3931,7 +3914,6 @@ static PyMethodDef cmndlgscMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxEvent}, { "_wxEvent","_wxFindDialogEvent",SwigwxFindDialogEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -3943,53 +3925,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxProgressDialog",SwigwxProgressDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxProgressDialog",SwigwxProgressDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxMessageDialog",SwigwxMessageDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMessageDialog",SwigwxMessageDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxFontDialog",SwigwxFontDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxFontDialog",SwigwxFontDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxTextEntryDialog",SwigwxTextEntryDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxFileDialog",SwigwxFileDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxFileDialog",SwigwxFileDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxDirDialog",SwigwxDirDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxDirDialog",SwigwxDirDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxColourDialog",SwigwxColourDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxColourDialog",SwigwxColourDialogTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxObject}, - { "_class_wxObject","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxObject}, - { "_class_wxObject","_class_wxFindReplaceData",SwigwxFindReplaceDataTowxObject}, - { "_class_wxObject","_wxFindReplaceData",SwigwxFindReplaceDataTowxObject}, - { "_class_wxObject","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxObject}, - { "_class_wxObject","_wxFindDialogEvent",SwigwxFindDialogEventTowxObject}, - { "_class_wxObject","_class_wxProgressDialog",SwigwxProgressDialogTowxObject}, - { "_class_wxObject","_wxProgressDialog",SwigwxProgressDialogTowxObject}, - { "_class_wxObject","_class_wxMessageDialog",SwigwxMessageDialogTowxObject}, - { "_class_wxObject","_wxMessageDialog",SwigwxMessageDialogTowxObject}, - { "_class_wxObject","_class_wxFontDialog",SwigwxFontDialogTowxObject}, - { "_class_wxObject","_wxFontDialog",SwigwxFontDialogTowxObject}, - { "_class_wxObject","_class_wxFontData",SwigwxFontDataTowxObject}, - { "_class_wxObject","_wxFontData",SwigwxFontDataTowxObject}, - { "_class_wxObject","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxObject}, - { "_class_wxObject","_wxTextEntryDialog",SwigwxTextEntryDialogTowxObject}, - { "_class_wxObject","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxObject}, - { "_class_wxObject","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxObject}, - { "_class_wxObject","_class_wxFileDialog",SwigwxFileDialogTowxObject}, - { "_class_wxObject","_wxFileDialog",SwigwxFileDialogTowxObject}, - { "_class_wxObject","_class_wxDirDialog",SwigwxDirDialogTowxObject}, - { "_class_wxObject","_wxDirDialog",SwigwxDirDialogTowxObject}, - { "_class_wxObject","_class_wxColourDialog",SwigwxColourDialogTowxObject}, - { "_class_wxObject","_wxColourDialog",SwigwxColourDialogTowxObject}, - { "_class_wxObject","_class_wxColourData",SwigwxColourDataTowxObject}, - { "_class_wxObject","_wxColourData",SwigwxColourDataTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -3997,40 +3935,15 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTopLevelWindow","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxProgressDialog",SwigwxProgressDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxProgressDialog",SwigwxProgressDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxMessageDialog",SwigwxMessageDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxMessageDialog",SwigwxMessageDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxFontDialog",SwigwxFontDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxFontDialog",SwigwxFontDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxTextEntryDialog",SwigwxTextEntryDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxFileDialog",SwigwxFileDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxFileDialog",SwigwxFileDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxDirDialog",SwigwxDirDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxDirDialog",SwigwxDirDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxColourDialog",SwigwxColourDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxColourDialog",SwigwxColourDialogTowxTopLevelWindow}, - { "_class_wxDialog","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxDialog}, - { "_class_wxDialog","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxDialog}, - { "_class_wxDialog","_class_wxMessageDialog",SwigwxMessageDialogTowxDialog}, - { "_class_wxDialog","_wxMessageDialog",SwigwxMessageDialogTowxDialog}, - { "_class_wxDialog","_class_wxFontDialog",SwigwxFontDialogTowxDialog}, - { "_class_wxDialog","_wxFontDialog",SwigwxFontDialogTowxDialog}, - { "_class_wxDialog","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxDialog}, - { "_class_wxDialog","_wxTextEntryDialog",SwigwxTextEntryDialogTowxDialog}, - { "_class_wxDialog","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxDialog}, - { "_class_wxDialog","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxDialog}, - { "_class_wxDialog","_class_wxFileDialog",SwigwxFileDialogTowxDialog}, - { "_class_wxDialog","_wxFileDialog",SwigwxFileDialogTowxDialog}, - { "_class_wxDialog","_class_wxDirDialog",SwigwxDirDialogTowxDialog}, - { "_class_wxDialog","_wxDirDialog",SwigwxDirDialogTowxDialog}, - { "_class_wxDialog","_class_wxColourDialog",SwigwxColourDialogTowxDialog}, - { "_class_wxDialog","_wxColourDialog",SwigwxColourDialogTowxDialog}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, { "_uint","_time_t",0}, @@ -4039,9 +3952,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxEvent}, - { "_class_wxEvent","_wxFindDialogEvent",SwigwxFindDialogEventTowxEvent}, - { "_wxCommandEvent","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxCommandEvent}, { "_wxCommandEvent","_wxFindDialogEvent",SwigwxFindDialogEventTowxCommandEvent}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, @@ -4057,72 +3967,23 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTopLevelWindow","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxProgressDialog",SwigwxProgressDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxProgressDialog",SwigwxProgressDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxMessageDialog",SwigwxMessageDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxMessageDialog",SwigwxMessageDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxFontDialog",SwigwxFontDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxFontDialog",SwigwxFontDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxTextEntryDialog",SwigwxTextEntryDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxFileDialog",SwigwxFileDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxFileDialog",SwigwxFileDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxDirDialog",SwigwxDirDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxDirDialog",SwigwxDirDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxColourDialog",SwigwxColourDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxColourDialog",SwigwxColourDialogTowxTopLevelWindow}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxWindow}, - { "_class_wxWindow","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxWindow}, - { "_class_wxWindow","_class_wxProgressDialog",SwigwxProgressDialogTowxWindow}, - { "_class_wxWindow","_wxProgressDialog",SwigwxProgressDialogTowxWindow}, - { "_class_wxWindow","_class_wxMessageDialog",SwigwxMessageDialogTowxWindow}, - { "_class_wxWindow","_wxMessageDialog",SwigwxMessageDialogTowxWindow}, - { "_class_wxWindow","_class_wxFontDialog",SwigwxFontDialogTowxWindow}, - { "_class_wxWindow","_wxFontDialog",SwigwxFontDialogTowxWindow}, - { "_class_wxWindow","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxWindow}, - { "_class_wxWindow","_wxTextEntryDialog",SwigwxTextEntryDialogTowxWindow}, - { "_class_wxWindow","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxWindow}, - { "_class_wxWindow","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxWindow}, - { "_class_wxWindow","_class_wxFileDialog",SwigwxFileDialogTowxWindow}, - { "_class_wxWindow","_wxFileDialog",SwigwxFileDialogTowxWindow}, - { "_class_wxWindow","_class_wxDirDialog",SwigwxDirDialogTowxWindow}, - { "_class_wxWindow","_wxDirDialog",SwigwxDirDialogTowxWindow}, - { "_class_wxWindow","_class_wxColourDialog",SwigwxColourDialogTowxWindow}, - { "_class_wxWindow","_wxColourDialog",SwigwxColourDialogTowxWindow}, - { "_wxObject","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxObject}, { "_wxObject","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxObject}, - { "_wxObject","_class_wxFindReplaceData",SwigwxFindReplaceDataTowxObject}, { "_wxObject","_wxFindReplaceData",SwigwxFindReplaceDataTowxObject}, - { "_wxObject","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxObject}, { "_wxObject","_wxFindDialogEvent",SwigwxFindDialogEventTowxObject}, - { "_wxObject","_class_wxProgressDialog",SwigwxProgressDialogTowxObject}, { "_wxObject","_wxProgressDialog",SwigwxProgressDialogTowxObject}, - { "_wxObject","_class_wxMessageDialog",SwigwxMessageDialogTowxObject}, { "_wxObject","_wxMessageDialog",SwigwxMessageDialogTowxObject}, - { "_wxObject","_class_wxFontDialog",SwigwxFontDialogTowxObject}, { "_wxObject","_wxFontDialog",SwigwxFontDialogTowxObject}, - { "_wxObject","_class_wxFontData",SwigwxFontDataTowxObject}, { "_wxObject","_wxFontData",SwigwxFontDataTowxObject}, - { "_wxObject","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxObject}, { "_wxObject","_wxTextEntryDialog",SwigwxTextEntryDialogTowxObject}, - { "_wxObject","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxObject}, { "_wxObject","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxObject}, - { "_wxObject","_class_wxFileDialog",SwigwxFileDialogTowxObject}, { "_wxObject","_wxFileDialog",SwigwxFileDialogTowxObject}, - { "_wxObject","_class_wxDirDialog",SwigwxDirDialogTowxObject}, { "_wxObject","_wxDirDialog",SwigwxDirDialogTowxObject}, - { "_wxObject","_class_wxColourDialog",SwigwxColourDialogTowxObject}, { "_wxObject","_wxColourDialog",SwigwxColourDialogTowxObject}, - { "_wxObject","_class_wxColourData",SwigwxColourDataTowxObject}, { "_wxObject","_wxColourData",SwigwxColourDataTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -4134,26 +3995,17 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_int","_uint",0}, { "_unsigned_int","_wxWindowID",0}, { "_unsigned_int","_int",0}, - { "_wxDialog","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxDialog}, { "_wxDialog","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxDialog}, - { "_wxDialog","_class_wxMessageDialog",SwigwxMessageDialogTowxDialog}, { "_wxDialog","_wxMessageDialog",SwigwxMessageDialogTowxDialog}, - { "_wxDialog","_class_wxFontDialog",SwigwxFontDialogTowxDialog}, { "_wxDialog","_wxFontDialog",SwigwxFontDialogTowxDialog}, - { "_wxDialog","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxDialog}, { "_wxDialog","_wxTextEntryDialog",SwigwxTextEntryDialogTowxDialog}, - { "_wxDialog","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxDialog}, { "_wxDialog","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxDialog}, - { "_wxDialog","_class_wxFileDialog",SwigwxFileDialogTowxDialog}, { "_wxDialog","_wxFileDialog",SwigwxFileDialogTowxDialog}, - { "_wxDialog","_class_wxDirDialog",SwigwxDirDialogTowxDialog}, { "_wxDialog","_wxDirDialog",SwigwxDirDialogTowxDialog}, - { "_wxDialog","_class_wxColourDialog",SwigwxColourDialogTowxDialog}, { "_wxDialog","_wxColourDialog",SwigwxColourDialogTowxDialog}, { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFrame","_class_wxProgressDialog",SwigwxProgressDialogTowxFrame}, { "_wxFrame","_wxProgressDialog",SwigwxProgressDialogTowxFrame}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -4189,46 +4041,24 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxFindDialogEvent",SwigwxFindDialogEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxFindDialogEvent",SwigwxFindDialogEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxEvtHandler}, { "_wxEvtHandler","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxProgressDialog",SwigwxProgressDialogTowxEvtHandler}, { "_wxEvtHandler","_wxProgressDialog",SwigwxProgressDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxMessageDialog",SwigwxMessageDialogTowxEvtHandler}, { "_wxEvtHandler","_wxMessageDialog",SwigwxMessageDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxFontDialog",SwigwxFontDialogTowxEvtHandler}, { "_wxEvtHandler","_wxFontDialog",SwigwxFontDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxEvtHandler}, { "_wxEvtHandler","_wxTextEntryDialog",SwigwxTextEntryDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxEvtHandler}, { "_wxEvtHandler","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxFileDialog",SwigwxFileDialogTowxEvtHandler}, { "_wxEvtHandler","_wxFileDialog",SwigwxFileDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxDirDialog",SwigwxDirDialogTowxEvtHandler}, { "_wxEvtHandler","_wxDirDialog",SwigwxDirDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxColourDialog",SwigwxColourDialogTowxEvtHandler}, { "_wxEvtHandler","_wxColourDialog",SwigwxColourDialogTowxEvtHandler}, - { "_wxWindow","_class_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxWindow}, { "_wxWindow","_wxFindReplaceDialog",SwigwxFindReplaceDialogTowxWindow}, - { "_wxWindow","_class_wxProgressDialog",SwigwxProgressDialogTowxWindow}, { "_wxWindow","_wxProgressDialog",SwigwxProgressDialogTowxWindow}, - { "_wxWindow","_class_wxMessageDialog",SwigwxMessageDialogTowxWindow}, { "_wxWindow","_wxMessageDialog",SwigwxMessageDialogTowxWindow}, - { "_wxWindow","_class_wxFontDialog",SwigwxFontDialogTowxWindow}, { "_wxWindow","_wxFontDialog",SwigwxFontDialogTowxWindow}, - { "_wxWindow","_class_wxTextEntryDialog",SwigwxTextEntryDialogTowxWindow}, { "_wxWindow","_wxTextEntryDialog",SwigwxTextEntryDialogTowxWindow}, - { "_wxWindow","_class_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxWindow}, { "_wxWindow","_wxSingleChoiceDialog",SwigwxSingleChoiceDialogTowxWindow}, - { "_wxWindow","_class_wxFileDialog",SwigwxFileDialogTowxWindow}, { "_wxWindow","_wxFileDialog",SwigwxFileDialogTowxWindow}, - { "_wxWindow","_class_wxDirDialog",SwigwxDirDialogTowxWindow}, { "_wxWindow","_wxDirDialog",SwigwxDirDialogTowxWindow}, - { "_wxWindow","_class_wxColourDialog",SwigwxColourDialogTowxWindow}, { "_wxWindow","_wxColourDialog",SwigwxColourDialogTowxWindow}, - { "_class_wxFrame","_class_wxProgressDialog",SwigwxProgressDialogTowxFrame}, - { "_class_wxFrame","_wxProgressDialog",SwigwxProgressDialogTowxFrame}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/controls.cpp b/wxPython/src/gtk/controls.cpp index 10550eda0b..80746b3ecb 100644 --- a/wxPython/src/gtk/controls.cpp +++ b/wxPython/src/gtk/controls.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -72,47 +74,28 @@ extern PyObject *SWIG_newvarlink(void); #endif -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -11206,99 +11189,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxToggleButton",SwigwxToggleButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxToggleButton",SwigwxToggleButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSpinCtrl",SwigwxSpinCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSpinCtrl",SwigwxSpinCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSlider",SwigwxSliderTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSlider",SwigwxSliderTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxRadioButton",SwigwxRadioButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxRadioButton",SwigwxRadioButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxRadioBox",SwigwxRadioBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxRadioBox",SwigwxRadioBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxStaticBitmap",SwigwxStaticBitmapTowxEvtHandler}, - { "_class_wxEvtHandler","_wxStaticBitmap",SwigwxStaticBitmapTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSpinButton",SwigwxSpinButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSpinButton",SwigwxSpinButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxScrollBar",SwigwxScrollBarTowxEvtHandler}, - { "_class_wxEvtHandler","_wxScrollBar",SwigwxScrollBarTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxTextCtrl",SwigwxTextCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxTextCtrl",SwigwxTextCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxCheckListBox",SwigwxCheckListBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxCheckListBox",SwigwxCheckListBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxListBox",SwigwxListBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxListBox",SwigwxListBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxStaticText",SwigwxStaticTextTowxEvtHandler}, - { "_class_wxEvtHandler","_wxStaticText",SwigwxStaticTextTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxStaticLine",SwigwxStaticLineTowxEvtHandler}, - { "_class_wxEvtHandler","_wxStaticLine",SwigwxStaticLineTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxStaticBox",SwigwxStaticBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxStaticBox",SwigwxStaticBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxGauge",SwigwxGaugeTowxEvtHandler}, - { "_class_wxEvtHandler","_wxGauge",SwigwxGaugeTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxComboBox",SwigwxComboBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxComboBox",SwigwxComboBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxChoice",SwigwxChoiceTowxEvtHandler}, - { "_class_wxEvtHandler","_wxChoice",SwigwxChoiceTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxCheckBox",SwigwxCheckBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_wxCheckBox",SwigwxCheckBoxTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxBitmapButton",SwigwxBitmapButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxBitmapButton",SwigwxBitmapButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxButton",SwigwxButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxButton",SwigwxButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxControlWithItems",SwigwxControlWithItemsTowxEvtHandler}, - { "_class_wxEvtHandler","_wxControlWithItems",SwigwxControlWithItemsTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxControl",SwigwxControlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxControl",SwigwxControlTowxEvtHandler}, { "_byte","_unsigned_char",0}, - { "_wxChoice","_class_wxComboBox",SwigwxComboBoxTowxChoice}, { "_wxChoice","_wxComboBox",SwigwxComboBoxTowxChoice}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxToggleButton",SwigwxToggleButtonTowxObject}, - { "_class_wxObject","_wxToggleButton",SwigwxToggleButtonTowxObject}, - { "_class_wxObject","_class_wxSpinCtrl",SwigwxSpinCtrlTowxObject}, - { "_class_wxObject","_wxSpinCtrl",SwigwxSpinCtrlTowxObject}, - { "_class_wxObject","_class_wxSlider",SwigwxSliderTowxObject}, - { "_class_wxObject","_wxSlider",SwigwxSliderTowxObject}, - { "_class_wxObject","_class_wxRadioButton",SwigwxRadioButtonTowxObject}, - { "_class_wxObject","_wxRadioButton",SwigwxRadioButtonTowxObject}, - { "_class_wxObject","_class_wxRadioBox",SwigwxRadioBoxTowxObject}, - { "_class_wxObject","_wxRadioBox",SwigwxRadioBoxTowxObject}, - { "_class_wxObject","_class_wxStaticBitmap",SwigwxStaticBitmapTowxObject}, - { "_class_wxObject","_wxStaticBitmap",SwigwxStaticBitmapTowxObject}, - { "_class_wxObject","_class_wxSpinButton",SwigwxSpinButtonTowxObject}, - { "_class_wxObject","_wxSpinButton",SwigwxSpinButtonTowxObject}, - { "_class_wxObject","_class_wxScrollBar",SwigwxScrollBarTowxObject}, - { "_class_wxObject","_wxScrollBar",SwigwxScrollBarTowxObject}, - { "_class_wxObject","_class_wxTextCtrl",SwigwxTextCtrlTowxObject}, - { "_class_wxObject","_wxTextCtrl",SwigwxTextCtrlTowxObject}, - { "_class_wxObject","_class_wxCheckListBox",SwigwxCheckListBoxTowxObject}, - { "_class_wxObject","_wxCheckListBox",SwigwxCheckListBoxTowxObject}, - { "_class_wxObject","_class_wxListBox",SwigwxListBoxTowxObject}, - { "_class_wxObject","_wxListBox",SwigwxListBoxTowxObject}, - { "_class_wxObject","_class_wxStaticText",SwigwxStaticTextTowxObject}, - { "_class_wxObject","_wxStaticText",SwigwxStaticTextTowxObject}, - { "_class_wxObject","_class_wxStaticLine",SwigwxStaticLineTowxObject}, - { "_class_wxObject","_wxStaticLine",SwigwxStaticLineTowxObject}, - { "_class_wxObject","_class_wxStaticBox",SwigwxStaticBoxTowxObject}, - { "_class_wxObject","_wxStaticBox",SwigwxStaticBoxTowxObject}, - { "_class_wxObject","_class_wxGauge",SwigwxGaugeTowxObject}, - { "_class_wxObject","_wxGauge",SwigwxGaugeTowxObject}, - { "_class_wxObject","_class_wxComboBox",SwigwxComboBoxTowxObject}, - { "_class_wxObject","_wxComboBox",SwigwxComboBoxTowxObject}, - { "_class_wxObject","_class_wxChoice",SwigwxChoiceTowxObject}, - { "_class_wxObject","_wxChoice",SwigwxChoiceTowxObject}, - { "_class_wxObject","_class_wxCheckBox",SwigwxCheckBoxTowxObject}, - { "_class_wxObject","_wxCheckBox",SwigwxCheckBoxTowxObject}, - { "_class_wxObject","_class_wxBitmapButton",SwigwxBitmapButtonTowxObject}, - { "_class_wxObject","_wxBitmapButton",SwigwxBitmapButtonTowxObject}, - { "_class_wxObject","_class_wxButton",SwigwxButtonTowxObject}, - { "_class_wxObject","_wxButton",SwigwxButtonTowxObject}, - { "_class_wxObject","_class_wxControlWithItems",SwigwxControlWithItemsTowxObject}, - { "_class_wxObject","_wxControlWithItems",SwigwxControlWithItemsTowxObject}, - { "_class_wxObject","_class_wxControl",SwigwxControlTowxObject}, - { "_class_wxObject","_wxControl",SwigwxControlTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -11314,10 +11208,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxButton","_class_wxBitmapButton",SwigwxBitmapButtonTowxButton}, - { "_class_wxButton","_wxBitmapButton",SwigwxBitmapButtonTowxButton}, { "_char","_wxChar",0}, - { "_wxSpinButton","_class_wxSpinCtrl",SwigwxSpinCtrlTowxSpinButton}, { "_wxSpinButton","_wxSpinCtrl",SwigwxSpinCtrlTowxSpinButton}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, @@ -11327,155 +11218,63 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxSpinButton","_class_wxSpinCtrl",SwigwxSpinCtrlTowxSpinButton}, - { "_class_wxSpinButton","_wxSpinCtrl",SwigwxSpinCtrlTowxSpinButton}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_wxListBox","_class_wxCheckListBox",SwigwxCheckListBoxTowxListBox}, { "_wxListBox","_wxCheckListBox",SwigwxCheckListBoxTowxListBox}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxToggleButton",SwigwxToggleButtonTowxWindow}, - { "_class_wxWindow","_wxToggleButton",SwigwxToggleButtonTowxWindow}, - { "_class_wxWindow","_class_wxSpinCtrl",SwigwxSpinCtrlTowxWindow}, - { "_class_wxWindow","_wxSpinCtrl",SwigwxSpinCtrlTowxWindow}, - { "_class_wxWindow","_class_wxSlider",SwigwxSliderTowxWindow}, - { "_class_wxWindow","_wxSlider",SwigwxSliderTowxWindow}, - { "_class_wxWindow","_class_wxRadioButton",SwigwxRadioButtonTowxWindow}, - { "_class_wxWindow","_wxRadioButton",SwigwxRadioButtonTowxWindow}, - { "_class_wxWindow","_class_wxRadioBox",SwigwxRadioBoxTowxWindow}, - { "_class_wxWindow","_wxRadioBox",SwigwxRadioBoxTowxWindow}, - { "_class_wxWindow","_class_wxStaticBitmap",SwigwxStaticBitmapTowxWindow}, - { "_class_wxWindow","_wxStaticBitmap",SwigwxStaticBitmapTowxWindow}, - { "_class_wxWindow","_class_wxSpinButton",SwigwxSpinButtonTowxWindow}, - { "_class_wxWindow","_wxSpinButton",SwigwxSpinButtonTowxWindow}, - { "_class_wxWindow","_class_wxScrollBar",SwigwxScrollBarTowxWindow}, - { "_class_wxWindow","_wxScrollBar",SwigwxScrollBarTowxWindow}, - { "_class_wxWindow","_class_wxTextCtrl",SwigwxTextCtrlTowxWindow}, - { "_class_wxWindow","_wxTextCtrl",SwigwxTextCtrlTowxWindow}, - { "_class_wxWindow","_class_wxCheckListBox",SwigwxCheckListBoxTowxWindow}, - { "_class_wxWindow","_wxCheckListBox",SwigwxCheckListBoxTowxWindow}, - { "_class_wxWindow","_class_wxListBox",SwigwxListBoxTowxWindow}, - { "_class_wxWindow","_wxListBox",SwigwxListBoxTowxWindow}, - { "_class_wxWindow","_class_wxStaticText",SwigwxStaticTextTowxWindow}, - { "_class_wxWindow","_wxStaticText",SwigwxStaticTextTowxWindow}, - { "_class_wxWindow","_class_wxStaticLine",SwigwxStaticLineTowxWindow}, - { "_class_wxWindow","_wxStaticLine",SwigwxStaticLineTowxWindow}, - { "_class_wxWindow","_class_wxStaticBox",SwigwxStaticBoxTowxWindow}, - { "_class_wxWindow","_wxStaticBox",SwigwxStaticBoxTowxWindow}, - { "_class_wxWindow","_class_wxGauge",SwigwxGaugeTowxWindow}, - { "_class_wxWindow","_wxGauge",SwigwxGaugeTowxWindow}, - { "_class_wxWindow","_class_wxComboBox",SwigwxComboBoxTowxWindow}, - { "_class_wxWindow","_wxComboBox",SwigwxComboBoxTowxWindow}, - { "_class_wxWindow","_class_wxChoice",SwigwxChoiceTowxWindow}, - { "_class_wxWindow","_wxChoice",SwigwxChoiceTowxWindow}, - { "_class_wxWindow","_class_wxCheckBox",SwigwxCheckBoxTowxWindow}, - { "_class_wxWindow","_wxCheckBox",SwigwxCheckBoxTowxWindow}, - { "_class_wxWindow","_class_wxBitmapButton",SwigwxBitmapButtonTowxWindow}, - { "_class_wxWindow","_wxBitmapButton",SwigwxBitmapButtonTowxWindow}, - { "_class_wxWindow","_class_wxButton",SwigwxButtonTowxWindow}, - { "_class_wxWindow","_wxButton",SwigwxButtonTowxWindow}, - { "_class_wxWindow","_class_wxControlWithItems",SwigwxControlWithItemsTowxWindow}, - { "_class_wxWindow","_wxControlWithItems",SwigwxControlWithItemsTowxWindow}, - { "_class_wxWindow","_class_wxControl",SwigwxControlTowxWindow}, - { "_class_wxWindow","_wxControl",SwigwxControlTowxWindow}, - { "_wxObject","_class_wxToggleButton",SwigwxToggleButtonTowxObject}, { "_wxObject","_wxToggleButton",SwigwxToggleButtonTowxObject}, - { "_wxObject","_class_wxSpinCtrl",SwigwxSpinCtrlTowxObject}, { "_wxObject","_wxSpinCtrl",SwigwxSpinCtrlTowxObject}, - { "_wxObject","_class_wxSlider",SwigwxSliderTowxObject}, { "_wxObject","_wxSlider",SwigwxSliderTowxObject}, - { "_wxObject","_class_wxRadioButton",SwigwxRadioButtonTowxObject}, { "_wxObject","_wxRadioButton",SwigwxRadioButtonTowxObject}, - { "_wxObject","_class_wxRadioBox",SwigwxRadioBoxTowxObject}, { "_wxObject","_wxRadioBox",SwigwxRadioBoxTowxObject}, - { "_wxObject","_class_wxStaticBitmap",SwigwxStaticBitmapTowxObject}, { "_wxObject","_wxStaticBitmap",SwigwxStaticBitmapTowxObject}, - { "_wxObject","_class_wxSpinButton",SwigwxSpinButtonTowxObject}, { "_wxObject","_wxSpinButton",SwigwxSpinButtonTowxObject}, - { "_wxObject","_class_wxScrollBar",SwigwxScrollBarTowxObject}, { "_wxObject","_wxScrollBar",SwigwxScrollBarTowxObject}, - { "_wxObject","_class_wxTextCtrl",SwigwxTextCtrlTowxObject}, { "_wxObject","_wxTextCtrl",SwigwxTextCtrlTowxObject}, - { "_wxObject","_class_wxCheckListBox",SwigwxCheckListBoxTowxObject}, { "_wxObject","_wxCheckListBox",SwigwxCheckListBoxTowxObject}, - { "_wxObject","_class_wxListBox",SwigwxListBoxTowxObject}, { "_wxObject","_wxListBox",SwigwxListBoxTowxObject}, - { "_wxObject","_class_wxStaticText",SwigwxStaticTextTowxObject}, { "_wxObject","_wxStaticText",SwigwxStaticTextTowxObject}, - { "_wxObject","_class_wxStaticLine",SwigwxStaticLineTowxObject}, { "_wxObject","_wxStaticLine",SwigwxStaticLineTowxObject}, - { "_wxObject","_class_wxStaticBox",SwigwxStaticBoxTowxObject}, { "_wxObject","_wxStaticBox",SwigwxStaticBoxTowxObject}, - { "_wxObject","_class_wxGauge",SwigwxGaugeTowxObject}, { "_wxObject","_wxGauge",SwigwxGaugeTowxObject}, - { "_wxObject","_class_wxComboBox",SwigwxComboBoxTowxObject}, { "_wxObject","_wxComboBox",SwigwxComboBoxTowxObject}, - { "_wxObject","_class_wxChoice",SwigwxChoiceTowxObject}, { "_wxObject","_wxChoice",SwigwxChoiceTowxObject}, - { "_wxObject","_class_wxCheckBox",SwigwxCheckBoxTowxObject}, { "_wxObject","_wxCheckBox",SwigwxCheckBoxTowxObject}, - { "_wxObject","_class_wxBitmapButton",SwigwxBitmapButtonTowxObject}, { "_wxObject","_wxBitmapButton",SwigwxBitmapButtonTowxObject}, - { "_wxObject","_class_wxButton",SwigwxButtonTowxObject}, { "_wxObject","_wxButton",SwigwxButtonTowxObject}, - { "_wxObject","_class_wxControlWithItems",SwigwxControlWithItemsTowxObject}, { "_wxObject","_wxControlWithItems",SwigwxControlWithItemsTowxObject}, - { "_wxObject","_class_wxControl",SwigwxControlTowxObject}, { "_wxObject","_wxControl",SwigwxControlTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxToggleButton",SwigwxToggleButtonTowxControl}, { "_wxControl","_wxToggleButton",SwigwxToggleButtonTowxControl}, - { "_wxControl","_class_wxSpinCtrl",SwigwxSpinCtrlTowxControl}, { "_wxControl","_wxSpinCtrl",SwigwxSpinCtrlTowxControl}, - { "_wxControl","_class_wxSlider",SwigwxSliderTowxControl}, { "_wxControl","_wxSlider",SwigwxSliderTowxControl}, - { "_wxControl","_class_wxRadioButton",SwigwxRadioButtonTowxControl}, { "_wxControl","_wxRadioButton",SwigwxRadioButtonTowxControl}, - { "_wxControl","_class_wxRadioBox",SwigwxRadioBoxTowxControl}, { "_wxControl","_wxRadioBox",SwigwxRadioBoxTowxControl}, - { "_wxControl","_class_wxStaticBitmap",SwigwxStaticBitmapTowxControl}, { "_wxControl","_wxStaticBitmap",SwigwxStaticBitmapTowxControl}, - { "_wxControl","_class_wxSpinButton",SwigwxSpinButtonTowxControl}, { "_wxControl","_wxSpinButton",SwigwxSpinButtonTowxControl}, - { "_wxControl","_class_wxScrollBar",SwigwxScrollBarTowxControl}, { "_wxControl","_wxScrollBar",SwigwxScrollBarTowxControl}, - { "_wxControl","_class_wxTextCtrl",SwigwxTextCtrlTowxControl}, { "_wxControl","_wxTextCtrl",SwigwxTextCtrlTowxControl}, - { "_wxControl","_class_wxCheckListBox",SwigwxCheckListBoxTowxControl}, { "_wxControl","_wxCheckListBox",SwigwxCheckListBoxTowxControl}, - { "_wxControl","_class_wxListBox",SwigwxListBoxTowxControl}, { "_wxControl","_wxListBox",SwigwxListBoxTowxControl}, - { "_wxControl","_class_wxStaticText",SwigwxStaticTextTowxControl}, { "_wxControl","_wxStaticText",SwigwxStaticTextTowxControl}, - { "_wxControl","_class_wxStaticLine",SwigwxStaticLineTowxControl}, { "_wxControl","_wxStaticLine",SwigwxStaticLineTowxControl}, - { "_wxControl","_class_wxStaticBox",SwigwxStaticBoxTowxControl}, { "_wxControl","_wxStaticBox",SwigwxStaticBoxTowxControl}, - { "_wxControl","_class_wxGauge",SwigwxGaugeTowxControl}, { "_wxControl","_wxGauge",SwigwxGaugeTowxControl}, - { "_wxControl","_class_wxComboBox",SwigwxComboBoxTowxControl}, { "_wxControl","_wxComboBox",SwigwxComboBoxTowxControl}, - { "_wxControl","_class_wxChoice",SwigwxChoiceTowxControl}, { "_wxControl","_wxChoice",SwigwxChoiceTowxControl}, - { "_wxControl","_class_wxCheckBox",SwigwxCheckBoxTowxControl}, { "_wxControl","_wxCheckBox",SwigwxCheckBoxTowxControl}, - { "_wxControl","_class_wxBitmapButton",SwigwxBitmapButtonTowxControl}, { "_wxControl","_wxBitmapButton",SwigwxBitmapButtonTowxControl}, - { "_wxControl","_class_wxButton",SwigwxButtonTowxControl}, { "_wxControl","_wxButton",SwigwxButtonTowxControl}, - { "_wxControl","_class_wxControlWithItems",SwigwxControlWithItemsTowxControl}, { "_wxControl","_wxControlWithItems",SwigwxControlWithItemsTowxControl}, - { "_class_wxListBox","_class_wxCheckListBox",SwigwxCheckListBoxTowxListBox}, - { "_class_wxListBox","_wxCheckListBox",SwigwxCheckListBoxTowxListBox}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, { "_unsigned_int","_time_t",0}, @@ -11486,16 +11285,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxControlWithItems","_class_wxCheckListBox",SwigwxCheckListBoxTowxControlWithItems}, { "_wxControlWithItems","_wxCheckListBox",SwigwxCheckListBoxTowxControlWithItems}, - { "_wxControlWithItems","_class_wxListBox",SwigwxListBoxTowxControlWithItems}, { "_wxControlWithItems","_wxListBox",SwigwxListBoxTowxControlWithItems}, - { "_wxControlWithItems","_class_wxComboBox",SwigwxComboBoxTowxControlWithItems}, { "_wxControlWithItems","_wxComboBox",SwigwxComboBoxTowxControlWithItems}, - { "_wxControlWithItems","_class_wxChoice",SwigwxChoiceTowxControlWithItems}, { "_wxControlWithItems","_wxChoice",SwigwxChoiceTowxControlWithItems}, - { "_class_wxChoice","_class_wxComboBox",SwigwxComboBoxTowxChoice}, - { "_class_wxChoice","_wxComboBox",SwigwxComboBoxTowxChoice}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, { "_wxWindowID","_time_t",0}, @@ -11521,50 +11314,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_wxButton","_class_wxBitmapButton",SwigwxBitmapButtonTowxButton}, { "_wxButton","_wxBitmapButton",SwigwxBitmapButtonTowxButton}, - { "_class_wxControl","_class_wxToggleButton",SwigwxToggleButtonTowxControl}, - { "_class_wxControl","_wxToggleButton",SwigwxToggleButtonTowxControl}, - { "_class_wxControl","_class_wxSpinCtrl",SwigwxSpinCtrlTowxControl}, - { "_class_wxControl","_wxSpinCtrl",SwigwxSpinCtrlTowxControl}, - { "_class_wxControl","_class_wxSlider",SwigwxSliderTowxControl}, - { "_class_wxControl","_wxSlider",SwigwxSliderTowxControl}, - { "_class_wxControl","_class_wxRadioButton",SwigwxRadioButtonTowxControl}, - { "_class_wxControl","_wxRadioButton",SwigwxRadioButtonTowxControl}, - { "_class_wxControl","_class_wxRadioBox",SwigwxRadioBoxTowxControl}, - { "_class_wxControl","_wxRadioBox",SwigwxRadioBoxTowxControl}, - { "_class_wxControl","_class_wxStaticBitmap",SwigwxStaticBitmapTowxControl}, - { "_class_wxControl","_wxStaticBitmap",SwigwxStaticBitmapTowxControl}, - { "_class_wxControl","_class_wxSpinButton",SwigwxSpinButtonTowxControl}, - { "_class_wxControl","_wxSpinButton",SwigwxSpinButtonTowxControl}, - { "_class_wxControl","_class_wxScrollBar",SwigwxScrollBarTowxControl}, - { "_class_wxControl","_wxScrollBar",SwigwxScrollBarTowxControl}, - { "_class_wxControl","_class_wxTextCtrl",SwigwxTextCtrlTowxControl}, - { "_class_wxControl","_wxTextCtrl",SwigwxTextCtrlTowxControl}, - { "_class_wxControl","_class_wxCheckListBox",SwigwxCheckListBoxTowxControl}, - { "_class_wxControl","_wxCheckListBox",SwigwxCheckListBoxTowxControl}, - { "_class_wxControl","_class_wxListBox",SwigwxListBoxTowxControl}, - { "_class_wxControl","_wxListBox",SwigwxListBoxTowxControl}, - { "_class_wxControl","_class_wxStaticText",SwigwxStaticTextTowxControl}, - { "_class_wxControl","_wxStaticText",SwigwxStaticTextTowxControl}, - { "_class_wxControl","_class_wxStaticLine",SwigwxStaticLineTowxControl}, - { "_class_wxControl","_wxStaticLine",SwigwxStaticLineTowxControl}, - { "_class_wxControl","_class_wxStaticBox",SwigwxStaticBoxTowxControl}, - { "_class_wxControl","_wxStaticBox",SwigwxStaticBoxTowxControl}, - { "_class_wxControl","_class_wxGauge",SwigwxGaugeTowxControl}, - { "_class_wxControl","_wxGauge",SwigwxGaugeTowxControl}, - { "_class_wxControl","_class_wxComboBox",SwigwxComboBoxTowxControl}, - { "_class_wxControl","_wxComboBox",SwigwxComboBoxTowxControl}, - { "_class_wxControl","_class_wxChoice",SwigwxChoiceTowxControl}, - { "_class_wxControl","_wxChoice",SwigwxChoiceTowxControl}, - { "_class_wxControl","_class_wxCheckBox",SwigwxCheckBoxTowxControl}, - { "_class_wxControl","_wxCheckBox",SwigwxCheckBoxTowxControl}, - { "_class_wxControl","_class_wxBitmapButton",SwigwxBitmapButtonTowxControl}, - { "_class_wxControl","_wxBitmapButton",SwigwxBitmapButtonTowxControl}, - { "_class_wxControl","_class_wxButton",SwigwxButtonTowxControl}, - { "_class_wxControl","_wxButton",SwigwxButtonTowxControl}, - { "_class_wxControl","_class_wxControlWithItems",SwigwxControlWithItemsTowxControl}, - { "_class_wxControl","_wxControlWithItems",SwigwxControlWithItemsTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -11574,101 +11324,49 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxControlWithItems","_class_wxCheckListBox",SwigwxCheckListBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_wxCheckListBox",SwigwxCheckListBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_class_wxListBox",SwigwxListBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_wxListBox",SwigwxListBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_class_wxComboBox",SwigwxComboBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_wxComboBox",SwigwxComboBoxTowxControlWithItems}, - { "_class_wxControlWithItems","_class_wxChoice",SwigwxChoiceTowxControlWithItems}, - { "_class_wxControlWithItems","_wxChoice",SwigwxChoiceTowxControlWithItems}, - { "_wxEvtHandler","_class_wxToggleButton",SwigwxToggleButtonTowxEvtHandler}, { "_wxEvtHandler","_wxToggleButton",SwigwxToggleButtonTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSpinCtrl",SwigwxSpinCtrlTowxEvtHandler}, { "_wxEvtHandler","_wxSpinCtrl",SwigwxSpinCtrlTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSlider",SwigwxSliderTowxEvtHandler}, { "_wxEvtHandler","_wxSlider",SwigwxSliderTowxEvtHandler}, - { "_wxEvtHandler","_class_wxRadioButton",SwigwxRadioButtonTowxEvtHandler}, { "_wxEvtHandler","_wxRadioButton",SwigwxRadioButtonTowxEvtHandler}, - { "_wxEvtHandler","_class_wxRadioBox",SwigwxRadioBoxTowxEvtHandler}, { "_wxEvtHandler","_wxRadioBox",SwigwxRadioBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxStaticBitmap",SwigwxStaticBitmapTowxEvtHandler}, { "_wxEvtHandler","_wxStaticBitmap",SwigwxStaticBitmapTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSpinButton",SwigwxSpinButtonTowxEvtHandler}, { "_wxEvtHandler","_wxSpinButton",SwigwxSpinButtonTowxEvtHandler}, - { "_wxEvtHandler","_class_wxScrollBar",SwigwxScrollBarTowxEvtHandler}, { "_wxEvtHandler","_wxScrollBar",SwigwxScrollBarTowxEvtHandler}, - { "_wxEvtHandler","_class_wxTextCtrl",SwigwxTextCtrlTowxEvtHandler}, { "_wxEvtHandler","_wxTextCtrl",SwigwxTextCtrlTowxEvtHandler}, - { "_wxEvtHandler","_class_wxCheckListBox",SwigwxCheckListBoxTowxEvtHandler}, { "_wxEvtHandler","_wxCheckListBox",SwigwxCheckListBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxListBox",SwigwxListBoxTowxEvtHandler}, { "_wxEvtHandler","_wxListBox",SwigwxListBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxStaticText",SwigwxStaticTextTowxEvtHandler}, { "_wxEvtHandler","_wxStaticText",SwigwxStaticTextTowxEvtHandler}, - { "_wxEvtHandler","_class_wxStaticLine",SwigwxStaticLineTowxEvtHandler}, { "_wxEvtHandler","_wxStaticLine",SwigwxStaticLineTowxEvtHandler}, - { "_wxEvtHandler","_class_wxStaticBox",SwigwxStaticBoxTowxEvtHandler}, { "_wxEvtHandler","_wxStaticBox",SwigwxStaticBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxGauge",SwigwxGaugeTowxEvtHandler}, { "_wxEvtHandler","_wxGauge",SwigwxGaugeTowxEvtHandler}, - { "_wxEvtHandler","_class_wxComboBox",SwigwxComboBoxTowxEvtHandler}, { "_wxEvtHandler","_wxComboBox",SwigwxComboBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxChoice",SwigwxChoiceTowxEvtHandler}, { "_wxEvtHandler","_wxChoice",SwigwxChoiceTowxEvtHandler}, - { "_wxEvtHandler","_class_wxCheckBox",SwigwxCheckBoxTowxEvtHandler}, { "_wxEvtHandler","_wxCheckBox",SwigwxCheckBoxTowxEvtHandler}, - { "_wxEvtHandler","_class_wxBitmapButton",SwigwxBitmapButtonTowxEvtHandler}, { "_wxEvtHandler","_wxBitmapButton",SwigwxBitmapButtonTowxEvtHandler}, - { "_wxEvtHandler","_class_wxButton",SwigwxButtonTowxEvtHandler}, { "_wxEvtHandler","_wxButton",SwigwxButtonTowxEvtHandler}, - { "_wxEvtHandler","_class_wxControlWithItems",SwigwxControlWithItemsTowxEvtHandler}, { "_wxEvtHandler","_wxControlWithItems",SwigwxControlWithItemsTowxEvtHandler}, - { "_wxEvtHandler","_class_wxControl",SwigwxControlTowxEvtHandler}, { "_wxEvtHandler","_wxControl",SwigwxControlTowxEvtHandler}, - { "_wxWindow","_class_wxToggleButton",SwigwxToggleButtonTowxWindow}, { "_wxWindow","_wxToggleButton",SwigwxToggleButtonTowxWindow}, - { "_wxWindow","_class_wxSpinCtrl",SwigwxSpinCtrlTowxWindow}, { "_wxWindow","_wxSpinCtrl",SwigwxSpinCtrlTowxWindow}, - { "_wxWindow","_class_wxSlider",SwigwxSliderTowxWindow}, { "_wxWindow","_wxSlider",SwigwxSliderTowxWindow}, - { "_wxWindow","_class_wxRadioButton",SwigwxRadioButtonTowxWindow}, { "_wxWindow","_wxRadioButton",SwigwxRadioButtonTowxWindow}, - { "_wxWindow","_class_wxRadioBox",SwigwxRadioBoxTowxWindow}, { "_wxWindow","_wxRadioBox",SwigwxRadioBoxTowxWindow}, - { "_wxWindow","_class_wxStaticBitmap",SwigwxStaticBitmapTowxWindow}, { "_wxWindow","_wxStaticBitmap",SwigwxStaticBitmapTowxWindow}, - { "_wxWindow","_class_wxSpinButton",SwigwxSpinButtonTowxWindow}, { "_wxWindow","_wxSpinButton",SwigwxSpinButtonTowxWindow}, - { "_wxWindow","_class_wxScrollBar",SwigwxScrollBarTowxWindow}, { "_wxWindow","_wxScrollBar",SwigwxScrollBarTowxWindow}, - { "_wxWindow","_class_wxTextCtrl",SwigwxTextCtrlTowxWindow}, { "_wxWindow","_wxTextCtrl",SwigwxTextCtrlTowxWindow}, - { "_wxWindow","_class_wxCheckListBox",SwigwxCheckListBoxTowxWindow}, { "_wxWindow","_wxCheckListBox",SwigwxCheckListBoxTowxWindow}, - { "_wxWindow","_class_wxListBox",SwigwxListBoxTowxWindow}, { "_wxWindow","_wxListBox",SwigwxListBoxTowxWindow}, - { "_wxWindow","_class_wxStaticText",SwigwxStaticTextTowxWindow}, { "_wxWindow","_wxStaticText",SwigwxStaticTextTowxWindow}, - { "_wxWindow","_class_wxStaticLine",SwigwxStaticLineTowxWindow}, { "_wxWindow","_wxStaticLine",SwigwxStaticLineTowxWindow}, - { "_wxWindow","_class_wxStaticBox",SwigwxStaticBoxTowxWindow}, { "_wxWindow","_wxStaticBox",SwigwxStaticBoxTowxWindow}, - { "_wxWindow","_class_wxGauge",SwigwxGaugeTowxWindow}, { "_wxWindow","_wxGauge",SwigwxGaugeTowxWindow}, - { "_wxWindow","_class_wxComboBox",SwigwxComboBoxTowxWindow}, { "_wxWindow","_wxComboBox",SwigwxComboBoxTowxWindow}, - { "_wxWindow","_class_wxChoice",SwigwxChoiceTowxWindow}, { "_wxWindow","_wxChoice",SwigwxChoiceTowxWindow}, - { "_wxWindow","_class_wxCheckBox",SwigwxCheckBoxTowxWindow}, { "_wxWindow","_wxCheckBox",SwigwxCheckBoxTowxWindow}, - { "_wxWindow","_class_wxBitmapButton",SwigwxBitmapButtonTowxWindow}, { "_wxWindow","_wxBitmapButton",SwigwxBitmapButtonTowxWindow}, - { "_wxWindow","_class_wxButton",SwigwxButtonTowxWindow}, { "_wxWindow","_wxButton",SwigwxButtonTowxWindow}, - { "_wxWindow","_class_wxControlWithItems",SwigwxControlWithItemsTowxWindow}, { "_wxWindow","_wxControlWithItems",SwigwxControlWithItemsTowxWindow}, - { "_wxWindow","_class_wxControl",SwigwxControlTowxWindow}, { "_wxWindow","_wxControl",SwigwxControlTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/controls2.cpp b/wxPython/src/gtk/controls2.cpp index 083f0fd264..1fb9a498f0 100644 --- a/wxPython/src/gtk/controls2.cpp +++ b/wxPython/src/gtk/controls2.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -61,47 +63,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -9721,13 +9704,9 @@ static PyMethodDef controls2cMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxTreeEvent",SwigwxTreeEventTowxEvent}, { "_wxEvent","_wxTreeEvent",SwigwxTreeEventTowxEvent}, - { "_wxEvent","_class_wxListEvent",SwigwxListEventTowxEvent}, { "_wxEvent","_wxListEvent",SwigwxListEventTowxEvent}, { "_signed_long","_long",0}, - { "_class_wxPyListCtrl","_class_wxListView",SwigwxListViewTowxPyListCtrl}, - { "_class_wxPyListCtrl","_wxListView",SwigwxListViewTowxPyListCtrl}, { "_wxPrintQuality","_wxCoord",0}, { "_wxPrintQuality","_int",0}, { "_wxPrintQuality","_signed_int",0}, @@ -9737,33 +9716,11 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxListView",SwigwxListViewTowxEvtHandler}, - { "_class_wxEvtHandler","_wxListView",SwigwxListViewTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPyListCtrl",SwigwxPyListCtrlTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyListCtrl",SwigwxPyListCtrlTowxEvtHandler}, - { "_wxNotifyEvent","_class_wxTreeEvent",SwigwxTreeEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxTreeEvent",SwigwxTreeEventTowxNotifyEvent}, - { "_wxNotifyEvent","_class_wxListEvent",SwigwxListEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxListEvent",SwigwxListEventTowxNotifyEvent}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxObject}, - { "_class_wxObject","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxObject}, - { "_class_wxObject","_class_wxTreeEvent",SwigwxTreeEventTowxObject}, - { "_class_wxObject","_wxTreeEvent",SwigwxTreeEventTowxObject}, - { "_class_wxObject","_class_wxPyTreeItemData",SwigwxPyTreeItemDataTowxObject}, - { "_class_wxObject","_wxPyTreeItemData",SwigwxPyTreeItemDataTowxObject}, - { "_class_wxObject","_class_wxListView",SwigwxListViewTowxObject}, - { "_class_wxObject","_wxListView",SwigwxListViewTowxObject}, - { "_class_wxObject","_class_wxPyListCtrl",SwigwxPyListCtrlTowxObject}, - { "_class_wxObject","_wxPyListCtrl",SwigwxPyListCtrlTowxObject}, - { "_class_wxObject","_class_wxListEvent",SwigwxListEventTowxObject}, - { "_class_wxObject","_wxListEvent",SwigwxListEventTowxObject}, - { "_class_wxObject","_class_wxListItem",SwigwxListItemTowxObject}, - { "_class_wxObject","_wxListItem",SwigwxListItemTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -9779,19 +9736,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxTreeEvent",SwigwxTreeEventTowxEvent}, - { "_class_wxEvent","_wxTreeEvent",SwigwxTreeEventTowxEvent}, - { "_class_wxEvent","_class_wxListEvent",SwigwxListEventTowxEvent}, - { "_class_wxEvent","_wxListEvent",SwigwxListEventTowxEvent}, - { "_wxCommandEvent","_class_wxTreeEvent",SwigwxTreeEventTowxCommandEvent}, { "_wxCommandEvent","_wxTreeEvent",SwigwxTreeEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxListEvent",SwigwxListEventTowxCommandEvent}, { "_wxCommandEvent","_wxListEvent",SwigwxListEventTowxCommandEvent}, { "_char","_wxChar",0}, - { "_class_wxNotifyEvent","_class_wxTreeEvent",SwigwxTreeEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxTreeEvent",SwigwxTreeEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_class_wxListEvent",SwigwxListEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxListEvent",SwigwxListEventTowxNotifyEvent}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, @@ -9810,34 +9757,18 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxWindow}, - { "_class_wxWindow","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxWindow}, - { "_class_wxWindow","_class_wxListView",SwigwxListViewTowxWindow}, - { "_class_wxWindow","_wxListView",SwigwxListViewTowxWindow}, - { "_class_wxWindow","_class_wxPyListCtrl",SwigwxPyListCtrlTowxWindow}, - { "_class_wxWindow","_wxPyListCtrl",SwigwxPyListCtrlTowxWindow}, - { "_wxObject","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxObject}, { "_wxObject","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxObject}, - { "_wxObject","_class_wxTreeEvent",SwigwxTreeEventTowxObject}, { "_wxObject","_wxTreeEvent",SwigwxTreeEventTowxObject}, - { "_wxObject","_class_wxPyTreeItemData",SwigwxPyTreeItemDataTowxObject}, { "_wxObject","_wxPyTreeItemData",SwigwxPyTreeItemDataTowxObject}, - { "_wxObject","_class_wxListView",SwigwxListViewTowxObject}, { "_wxObject","_wxListView",SwigwxListViewTowxObject}, - { "_wxObject","_class_wxPyListCtrl",SwigwxPyListCtrlTowxObject}, { "_wxObject","_wxPyListCtrl",SwigwxPyListCtrlTowxObject}, - { "_wxObject","_class_wxListEvent",SwigwxListEventTowxObject}, { "_wxObject","_wxListEvent",SwigwxListEventTowxObject}, - { "_wxObject","_class_wxListItem",SwigwxListItemTowxObject}, { "_wxObject","_wxListItem",SwigwxListItemTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxControl}, { "_wxControl","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxControl}, - { "_wxControl","_class_wxListView",SwigwxListViewTowxControl}, { "_wxControl","_wxListView",SwigwxListViewTowxControl}, - { "_wxControl","_class_wxPyListCtrl",SwigwxPyListCtrlTowxControl}, { "_wxControl","_wxPyListCtrl",SwigwxPyListCtrlTowxControl}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -9874,12 +9805,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_class_wxControl","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxControl}, - { "_class_wxControl","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxControl}, - { "_class_wxControl","_class_wxListView",SwigwxListViewTowxControl}, - { "_class_wxControl","_wxListView",SwigwxListViewTowxControl}, - { "_class_wxControl","_class_wxPyListCtrl",SwigwxPyListCtrlTowxControl}, - { "_class_wxControl","_wxPyListCtrl",SwigwxPyListCtrlTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -9889,23 +9814,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxTreeEvent",SwigwxTreeEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxTreeEvent",SwigwxTreeEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxListEvent",SwigwxListEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxListEvent",SwigwxListEventTowxCommandEvent}, - { "_wxPyListCtrl","_class_wxListView",SwigwxListViewTowxPyListCtrl}, { "_wxPyListCtrl","_wxListView",SwigwxListViewTowxPyListCtrl}, - { "_wxEvtHandler","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxEvtHandler}, { "_wxEvtHandler","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxEvtHandler}, - { "_wxEvtHandler","_class_wxListView",SwigwxListViewTowxEvtHandler}, { "_wxEvtHandler","_wxListView",SwigwxListViewTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPyListCtrl",SwigwxPyListCtrlTowxEvtHandler}, { "_wxEvtHandler","_wxPyListCtrl",SwigwxPyListCtrlTowxEvtHandler}, - { "_wxWindow","_class_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxWindow}, { "_wxWindow","_wxPyTreeCtrl",SwigwxPyTreeCtrlTowxWindow}, - { "_wxWindow","_class_wxListView",SwigwxListViewTowxWindow}, { "_wxWindow","_wxListView",SwigwxListViewTowxWindow}, - { "_wxWindow","_class_wxPyListCtrl",SwigwxPyListCtrlTowxWindow}, { "_wxWindow","_wxPyListCtrl",SwigwxPyListCtrlTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/events.cpp b/wxPython/src/gtk/events.cpp index 858cb1166a..fe6aa76cab 100644 --- a/wxPython/src/gtk/events.cpp +++ b/wxPython/src/gtk/events.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -56,47 +58,28 @@ extern PyObject *SWIG_newvarlink(void); #include "helpers.h" #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -7218,71 +7201,38 @@ static PyMethodDef eventscMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxEvent}, { "_wxEvent","_wxPyCommandEvent",SwigwxPyCommandEventTowxEvent}, - { "_wxEvent","_class_wxPyEvent",SwigwxPyEventTowxEvent}, { "_wxEvent","_wxPyEvent",SwigwxPyEventTowxEvent}, - { "_wxEvent","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxEvent}, { "_wxEvent","_wxTextUrlEvent",SwigwxTextUrlEventTowxEvent}, - { "_wxEvent","_class_wxTimerEvent",SwigwxTimerEventTowxEvent}, { "_wxEvent","_wxTimerEvent",SwigwxTimerEventTowxEvent}, - { "_wxEvent","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxEvent}, { "_wxEvent","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxEvent}, - { "_wxEvent","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxEvent}, { "_wxEvent","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxEvent}, - { "_wxEvent","_class_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxEvent}, { "_wxEvent","_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxEvent}, - { "_wxEvent","_class_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxEvent}, { "_wxEvent","_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxEvent}, - { "_wxEvent","_class_wxNotifyEvent",SwigwxNotifyEventTowxEvent}, { "_wxEvent","_wxNotifyEvent",SwigwxNotifyEventTowxEvent}, - { "_wxEvent","_class_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxEvent}, { "_wxEvent","_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxEvent}, - { "_wxEvent","_class_wxUpdateUIEvent",SwigwxUpdateUIEventTowxEvent}, { "_wxEvent","_wxUpdateUIEvent",SwigwxUpdateUIEventTowxEvent}, - { "_wxEvent","_class_wxIdleEvent",SwigwxIdleEventTowxEvent}, { "_wxEvent","_wxIdleEvent",SwigwxIdleEventTowxEvent}, - { "_wxEvent","_class_wxDropFilesEvent",SwigwxDropFilesEventTowxEvent}, { "_wxEvent","_wxDropFilesEvent",SwigwxDropFilesEventTowxEvent}, - { "_wxEvent","_class_wxJoystickEvent",SwigwxJoystickEventTowxEvent}, { "_wxEvent","_wxJoystickEvent",SwigwxJoystickEventTowxEvent}, - { "_wxEvent","_class_wxMaximizeEvent",SwigwxMaximizeEventTowxEvent}, { "_wxEvent","_wxMaximizeEvent",SwigwxMaximizeEventTowxEvent}, - { "_wxEvent","_class_wxIconizeEvent",SwigwxIconizeEventTowxEvent}, { "_wxEvent","_wxIconizeEvent",SwigwxIconizeEventTowxEvent}, - { "_wxEvent","_class_wxShowEvent",SwigwxShowEventTowxEvent}, { "_wxEvent","_wxShowEvent",SwigwxShowEventTowxEvent}, - { "_wxEvent","_class_wxMenuEvent",SwigwxMenuEventTowxEvent}, { "_wxEvent","_wxMenuEvent",SwigwxMenuEventTowxEvent}, - { "_wxEvent","_class_wxInitDialogEvent",SwigwxInitDialogEventTowxEvent}, { "_wxEvent","_wxInitDialogEvent",SwigwxInitDialogEventTowxEvent}, - { "_wxEvent","_class_wxActivateEvent",SwigwxActivateEventTowxEvent}, { "_wxEvent","_wxActivateEvent",SwigwxActivateEventTowxEvent}, - { "_wxEvent","_class_wxFocusEvent",SwigwxFocusEventTowxEvent}, { "_wxEvent","_wxFocusEvent",SwigwxFocusEventTowxEvent}, - { "_wxEvent","_class_wxEraseEvent",SwigwxEraseEventTowxEvent}, { "_wxEvent","_wxEraseEvent",SwigwxEraseEventTowxEvent}, - { "_wxEvent","_class_wxPaintEvent",SwigwxPaintEventTowxEvent}, { "_wxEvent","_wxPaintEvent",SwigwxPaintEventTowxEvent}, - { "_wxEvent","_class_wxMoveEvent",SwigwxMoveEventTowxEvent}, { "_wxEvent","_wxMoveEvent",SwigwxMoveEventTowxEvent}, - { "_wxEvent","_class_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxEvent}, { "_wxEvent","_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxEvent}, - { "_wxEvent","_class_wxKeyEvent",SwigwxKeyEventTowxEvent}, { "_wxEvent","_wxKeyEvent",SwigwxKeyEventTowxEvent}, - { "_wxEvent","_class_wxMouseEvent",SwigwxMouseEventTowxEvent}, { "_wxEvent","_wxMouseEvent",SwigwxMouseEventTowxEvent}, - { "_wxEvent","_class_wxSpinEvent",SwigwxSpinEventTowxEvent}, { "_wxEvent","_wxSpinEvent",SwigwxSpinEventTowxEvent}, - { "_wxEvent","_class_wxScrollWinEvent",SwigwxScrollWinEventTowxEvent}, { "_wxEvent","_wxScrollWinEvent",SwigwxScrollWinEventTowxEvent}, - { "_wxEvent","_class_wxScrollEvent",SwigwxScrollEventTowxEvent}, { "_wxEvent","_wxScrollEvent",SwigwxScrollEventTowxEvent}, - { "_wxEvent","_class_wxCommandEvent",SwigwxCommandEventTowxEvent}, { "_wxEvent","_wxCommandEvent",SwigwxCommandEventTowxEvent}, - { "_wxEvent","_class_wxCloseEvent",SwigwxCloseEventTowxEvent}, { "_wxEvent","_wxCloseEvent",SwigwxCloseEventTowxEvent}, - { "_wxEvent","_class_wxSizeEvent",SwigwxSizeEventTowxEvent}, { "_wxEvent","_wxSizeEvent",SwigwxSizeEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -7297,74 +7247,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxObject}, - { "_class_wxObject","_wxPyCommandEvent",SwigwxPyCommandEventTowxObject}, - { "_class_wxObject","_class_wxPyEvent",SwigwxPyEventTowxObject}, - { "_class_wxObject","_wxPyEvent",SwigwxPyEventTowxObject}, - { "_class_wxObject","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxObject}, - { "_class_wxObject","_wxTextUrlEvent",SwigwxTextUrlEventTowxObject}, - { "_class_wxObject","_class_wxTimerEvent",SwigwxTimerEventTowxObject}, - { "_class_wxObject","_wxTimerEvent",SwigwxTimerEventTowxObject}, - { "_class_wxObject","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxObject}, - { "_class_wxObject","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxObject}, - { "_class_wxObject","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxObject}, - { "_class_wxObject","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxObject}, - { "_class_wxObject","_class_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxObject}, - { "_class_wxObject","_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxObject}, - { "_class_wxObject","_class_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxObject}, - { "_class_wxObject","_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxObject}, - { "_class_wxObject","_class_wxNotifyEvent",SwigwxNotifyEventTowxObject}, - { "_class_wxObject","_wxNotifyEvent",SwigwxNotifyEventTowxObject}, - { "_class_wxObject","_class_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxObject}, - { "_class_wxObject","_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxObject}, - { "_class_wxObject","_class_wxUpdateUIEvent",SwigwxUpdateUIEventTowxObject}, - { "_class_wxObject","_wxUpdateUIEvent",SwigwxUpdateUIEventTowxObject}, - { "_class_wxObject","_class_wxIdleEvent",SwigwxIdleEventTowxObject}, - { "_class_wxObject","_wxIdleEvent",SwigwxIdleEventTowxObject}, - { "_class_wxObject","_class_wxDropFilesEvent",SwigwxDropFilesEventTowxObject}, - { "_class_wxObject","_wxDropFilesEvent",SwigwxDropFilesEventTowxObject}, - { "_class_wxObject","_class_wxJoystickEvent",SwigwxJoystickEventTowxObject}, - { "_class_wxObject","_wxJoystickEvent",SwigwxJoystickEventTowxObject}, - { "_class_wxObject","_class_wxMaximizeEvent",SwigwxMaximizeEventTowxObject}, - { "_class_wxObject","_wxMaximizeEvent",SwigwxMaximizeEventTowxObject}, - { "_class_wxObject","_class_wxIconizeEvent",SwigwxIconizeEventTowxObject}, - { "_class_wxObject","_wxIconizeEvent",SwigwxIconizeEventTowxObject}, - { "_class_wxObject","_class_wxShowEvent",SwigwxShowEventTowxObject}, - { "_class_wxObject","_wxShowEvent",SwigwxShowEventTowxObject}, - { "_class_wxObject","_class_wxMenuEvent",SwigwxMenuEventTowxObject}, - { "_class_wxObject","_wxMenuEvent",SwigwxMenuEventTowxObject}, - { "_class_wxObject","_class_wxInitDialogEvent",SwigwxInitDialogEventTowxObject}, - { "_class_wxObject","_wxInitDialogEvent",SwigwxInitDialogEventTowxObject}, - { "_class_wxObject","_class_wxActivateEvent",SwigwxActivateEventTowxObject}, - { "_class_wxObject","_wxActivateEvent",SwigwxActivateEventTowxObject}, - { "_class_wxObject","_class_wxFocusEvent",SwigwxFocusEventTowxObject}, - { "_class_wxObject","_wxFocusEvent",SwigwxFocusEventTowxObject}, - { "_class_wxObject","_class_wxEraseEvent",SwigwxEraseEventTowxObject}, - { "_class_wxObject","_wxEraseEvent",SwigwxEraseEventTowxObject}, - { "_class_wxObject","_class_wxPaintEvent",SwigwxPaintEventTowxObject}, - { "_class_wxObject","_wxPaintEvent",SwigwxPaintEventTowxObject}, - { "_class_wxObject","_class_wxMoveEvent",SwigwxMoveEventTowxObject}, - { "_class_wxObject","_wxMoveEvent",SwigwxMoveEventTowxObject}, - { "_class_wxObject","_class_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxObject}, - { "_class_wxObject","_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxObject}, - { "_class_wxObject","_class_wxKeyEvent",SwigwxKeyEventTowxObject}, - { "_class_wxObject","_wxKeyEvent",SwigwxKeyEventTowxObject}, - { "_class_wxObject","_class_wxMouseEvent",SwigwxMouseEventTowxObject}, - { "_class_wxObject","_wxMouseEvent",SwigwxMouseEventTowxObject}, - { "_class_wxObject","_class_wxSpinEvent",SwigwxSpinEventTowxObject}, - { "_class_wxObject","_wxSpinEvent",SwigwxSpinEventTowxObject}, - { "_class_wxObject","_class_wxScrollWinEvent",SwigwxScrollWinEventTowxObject}, - { "_class_wxObject","_wxScrollWinEvent",SwigwxScrollWinEventTowxObject}, - { "_class_wxObject","_class_wxScrollEvent",SwigwxScrollEventTowxObject}, - { "_class_wxObject","_wxScrollEvent",SwigwxScrollEventTowxObject}, - { "_class_wxObject","_class_wxCommandEvent",SwigwxCommandEventTowxObject}, - { "_class_wxObject","_wxCommandEvent",SwigwxCommandEventTowxObject}, - { "_class_wxObject","_class_wxCloseEvent",SwigwxCloseEventTowxObject}, - { "_class_wxObject","_wxCloseEvent",SwigwxCloseEventTowxObject}, - { "_class_wxObject","_class_wxSizeEvent",SwigwxSizeEventTowxObject}, - { "_class_wxObject","_wxSizeEvent",SwigwxSizeEventTowxObject}, - { "_class_wxObject","_class_wxEvent",SwigwxEventTowxObject}, - { "_class_wxObject","_wxEvent",SwigwxEventTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -7380,89 +7262,15 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxEvent}, - { "_class_wxEvent","_wxPyCommandEvent",SwigwxPyCommandEventTowxEvent}, - { "_class_wxEvent","_class_wxPyEvent",SwigwxPyEventTowxEvent}, - { "_class_wxEvent","_wxPyEvent",SwigwxPyEventTowxEvent}, - { "_class_wxEvent","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxEvent}, - { "_class_wxEvent","_wxTextUrlEvent",SwigwxTextUrlEventTowxEvent}, - { "_class_wxEvent","_class_wxTimerEvent",SwigwxTimerEventTowxEvent}, - { "_class_wxEvent","_wxTimerEvent",SwigwxTimerEventTowxEvent}, - { "_class_wxEvent","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxEvent}, - { "_class_wxEvent","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxEvent}, - { "_class_wxEvent","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxEvent}, - { "_class_wxEvent","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxEvent}, - { "_class_wxEvent","_class_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxEvent}, - { "_class_wxEvent","_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxEvent}, - { "_class_wxEvent","_class_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxEvent}, - { "_class_wxEvent","_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxEvent}, - { "_class_wxEvent","_class_wxNotifyEvent",SwigwxNotifyEventTowxEvent}, - { "_class_wxEvent","_wxNotifyEvent",SwigwxNotifyEventTowxEvent}, - { "_class_wxEvent","_class_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxEvent}, - { "_class_wxEvent","_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxEvent}, - { "_class_wxEvent","_class_wxUpdateUIEvent",SwigwxUpdateUIEventTowxEvent}, - { "_class_wxEvent","_wxUpdateUIEvent",SwigwxUpdateUIEventTowxEvent}, - { "_class_wxEvent","_class_wxIdleEvent",SwigwxIdleEventTowxEvent}, - { "_class_wxEvent","_wxIdleEvent",SwigwxIdleEventTowxEvent}, - { "_class_wxEvent","_class_wxDropFilesEvent",SwigwxDropFilesEventTowxEvent}, - { "_class_wxEvent","_wxDropFilesEvent",SwigwxDropFilesEventTowxEvent}, - { "_class_wxEvent","_class_wxJoystickEvent",SwigwxJoystickEventTowxEvent}, - { "_class_wxEvent","_wxJoystickEvent",SwigwxJoystickEventTowxEvent}, - { "_class_wxEvent","_class_wxMaximizeEvent",SwigwxMaximizeEventTowxEvent}, - { "_class_wxEvent","_wxMaximizeEvent",SwigwxMaximizeEventTowxEvent}, - { "_class_wxEvent","_class_wxIconizeEvent",SwigwxIconizeEventTowxEvent}, - { "_class_wxEvent","_wxIconizeEvent",SwigwxIconizeEventTowxEvent}, - { "_class_wxEvent","_class_wxShowEvent",SwigwxShowEventTowxEvent}, - { "_class_wxEvent","_wxShowEvent",SwigwxShowEventTowxEvent}, - { "_class_wxEvent","_class_wxMenuEvent",SwigwxMenuEventTowxEvent}, - { "_class_wxEvent","_wxMenuEvent",SwigwxMenuEventTowxEvent}, - { "_class_wxEvent","_class_wxInitDialogEvent",SwigwxInitDialogEventTowxEvent}, - { "_class_wxEvent","_wxInitDialogEvent",SwigwxInitDialogEventTowxEvent}, - { "_class_wxEvent","_class_wxActivateEvent",SwigwxActivateEventTowxEvent}, - { "_class_wxEvent","_wxActivateEvent",SwigwxActivateEventTowxEvent}, - { "_class_wxEvent","_class_wxFocusEvent",SwigwxFocusEventTowxEvent}, - { "_class_wxEvent","_wxFocusEvent",SwigwxFocusEventTowxEvent}, - { "_class_wxEvent","_class_wxEraseEvent",SwigwxEraseEventTowxEvent}, - { "_class_wxEvent","_wxEraseEvent",SwigwxEraseEventTowxEvent}, - { "_class_wxEvent","_class_wxPaintEvent",SwigwxPaintEventTowxEvent}, - { "_class_wxEvent","_wxPaintEvent",SwigwxPaintEventTowxEvent}, - { "_class_wxEvent","_class_wxMoveEvent",SwigwxMoveEventTowxEvent}, - { "_class_wxEvent","_wxMoveEvent",SwigwxMoveEventTowxEvent}, - { "_class_wxEvent","_class_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxEvent}, - { "_class_wxEvent","_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxEvent}, - { "_class_wxEvent","_class_wxKeyEvent",SwigwxKeyEventTowxEvent}, - { "_class_wxEvent","_wxKeyEvent",SwigwxKeyEventTowxEvent}, - { "_class_wxEvent","_class_wxMouseEvent",SwigwxMouseEventTowxEvent}, - { "_class_wxEvent","_wxMouseEvent",SwigwxMouseEventTowxEvent}, - { "_class_wxEvent","_class_wxSpinEvent",SwigwxSpinEventTowxEvent}, - { "_class_wxEvent","_wxSpinEvent",SwigwxSpinEventTowxEvent}, - { "_class_wxEvent","_class_wxScrollWinEvent",SwigwxScrollWinEventTowxEvent}, - { "_class_wxEvent","_wxScrollWinEvent",SwigwxScrollWinEventTowxEvent}, - { "_class_wxEvent","_class_wxScrollEvent",SwigwxScrollEventTowxEvent}, - { "_class_wxEvent","_wxScrollEvent",SwigwxScrollEventTowxEvent}, - { "_class_wxEvent","_class_wxCommandEvent",SwigwxCommandEventTowxEvent}, - { "_class_wxEvent","_wxCommandEvent",SwigwxCommandEventTowxEvent}, - { "_class_wxEvent","_class_wxCloseEvent",SwigwxCloseEventTowxEvent}, - { "_class_wxEvent","_wxCloseEvent",SwigwxCloseEventTowxEvent}, - { "_class_wxEvent","_class_wxSizeEvent",SwigwxSizeEventTowxEvent}, - { "_class_wxEvent","_wxSizeEvent",SwigwxSizeEventTowxEvent}, - { "_wxCommandEvent","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxCommandEvent}, { "_wxCommandEvent","_wxPyCommandEvent",SwigwxPyCommandEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxCommandEvent}, { "_wxCommandEvent","_wxTextUrlEvent",SwigwxTextUrlEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxCommandEvent}, { "_wxCommandEvent","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxCommandEvent}, { "_wxCommandEvent","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxNotifyEvent",SwigwxNotifyEventTowxCommandEvent}, { "_wxCommandEvent","_wxNotifyEvent",SwigwxNotifyEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxSpinEvent",SwigwxSpinEventTowxCommandEvent}, { "_wxCommandEvent","_wxSpinEvent",SwigwxSpinEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxScrollEvent",SwigwxScrollEventTowxCommandEvent}, { "_wxCommandEvent","_wxScrollEvent",SwigwxScrollEventTowxCommandEvent}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, - { "_wxScrollEvent","_class_wxSpinEvent",SwigwxSpinEventTowxScrollEvent}, { "_wxScrollEvent","_wxSpinEvent",SwigwxSpinEventTowxScrollEvent}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, @@ -7481,73 +7289,39 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxObject}, { "_wxObject","_wxPyCommandEvent",SwigwxPyCommandEventTowxObject}, - { "_wxObject","_class_wxPyEvent",SwigwxPyEventTowxObject}, { "_wxObject","_wxPyEvent",SwigwxPyEventTowxObject}, - { "_wxObject","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxObject}, { "_wxObject","_wxTextUrlEvent",SwigwxTextUrlEventTowxObject}, - { "_wxObject","_class_wxTimerEvent",SwigwxTimerEventTowxObject}, { "_wxObject","_wxTimerEvent",SwigwxTimerEventTowxObject}, - { "_wxObject","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxObject}, { "_wxObject","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxObject}, - { "_wxObject","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxObject}, { "_wxObject","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxObject}, - { "_wxObject","_class_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxObject}, { "_wxObject","_wxQueryNewPaletteEvent",SwigwxQueryNewPaletteEventTowxObject}, - { "_wxObject","_class_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxObject}, { "_wxObject","_wxPaletteChangedEvent",SwigwxPaletteChangedEventTowxObject}, - { "_wxObject","_class_wxNotifyEvent",SwigwxNotifyEventTowxObject}, { "_wxObject","_wxNotifyEvent",SwigwxNotifyEventTowxObject}, - { "_wxObject","_class_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxObject}, { "_wxObject","_wxSysColourChangedEvent",SwigwxSysColourChangedEventTowxObject}, - { "_wxObject","_class_wxUpdateUIEvent",SwigwxUpdateUIEventTowxObject}, { "_wxObject","_wxUpdateUIEvent",SwigwxUpdateUIEventTowxObject}, - { "_wxObject","_class_wxIdleEvent",SwigwxIdleEventTowxObject}, { "_wxObject","_wxIdleEvent",SwigwxIdleEventTowxObject}, - { "_wxObject","_class_wxDropFilesEvent",SwigwxDropFilesEventTowxObject}, { "_wxObject","_wxDropFilesEvent",SwigwxDropFilesEventTowxObject}, - { "_wxObject","_class_wxJoystickEvent",SwigwxJoystickEventTowxObject}, { "_wxObject","_wxJoystickEvent",SwigwxJoystickEventTowxObject}, - { "_wxObject","_class_wxMaximizeEvent",SwigwxMaximizeEventTowxObject}, { "_wxObject","_wxMaximizeEvent",SwigwxMaximizeEventTowxObject}, - { "_wxObject","_class_wxIconizeEvent",SwigwxIconizeEventTowxObject}, { "_wxObject","_wxIconizeEvent",SwigwxIconizeEventTowxObject}, - { "_wxObject","_class_wxShowEvent",SwigwxShowEventTowxObject}, { "_wxObject","_wxShowEvent",SwigwxShowEventTowxObject}, - { "_wxObject","_class_wxMenuEvent",SwigwxMenuEventTowxObject}, { "_wxObject","_wxMenuEvent",SwigwxMenuEventTowxObject}, - { "_wxObject","_class_wxInitDialogEvent",SwigwxInitDialogEventTowxObject}, { "_wxObject","_wxInitDialogEvent",SwigwxInitDialogEventTowxObject}, - { "_wxObject","_class_wxActivateEvent",SwigwxActivateEventTowxObject}, { "_wxObject","_wxActivateEvent",SwigwxActivateEventTowxObject}, - { "_wxObject","_class_wxFocusEvent",SwigwxFocusEventTowxObject}, { "_wxObject","_wxFocusEvent",SwigwxFocusEventTowxObject}, - { "_wxObject","_class_wxEraseEvent",SwigwxEraseEventTowxObject}, { "_wxObject","_wxEraseEvent",SwigwxEraseEventTowxObject}, - { "_wxObject","_class_wxPaintEvent",SwigwxPaintEventTowxObject}, { "_wxObject","_wxPaintEvent",SwigwxPaintEventTowxObject}, - { "_wxObject","_class_wxMoveEvent",SwigwxMoveEventTowxObject}, { "_wxObject","_wxMoveEvent",SwigwxMoveEventTowxObject}, - { "_wxObject","_class_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxObject}, { "_wxObject","_wxNavigationKeyEvent",SwigwxNavigationKeyEventTowxObject}, - { "_wxObject","_class_wxKeyEvent",SwigwxKeyEventTowxObject}, { "_wxObject","_wxKeyEvent",SwigwxKeyEventTowxObject}, - { "_wxObject","_class_wxMouseEvent",SwigwxMouseEventTowxObject}, { "_wxObject","_wxMouseEvent",SwigwxMouseEventTowxObject}, - { "_wxObject","_class_wxSpinEvent",SwigwxSpinEventTowxObject}, { "_wxObject","_wxSpinEvent",SwigwxSpinEventTowxObject}, - { "_wxObject","_class_wxScrollWinEvent",SwigwxScrollWinEventTowxObject}, { "_wxObject","_wxScrollWinEvent",SwigwxScrollWinEventTowxObject}, - { "_wxObject","_class_wxScrollEvent",SwigwxScrollEventTowxObject}, { "_wxObject","_wxScrollEvent",SwigwxScrollEventTowxObject}, - { "_wxObject","_class_wxCommandEvent",SwigwxCommandEventTowxObject}, { "_wxObject","_wxCommandEvent",SwigwxCommandEventTowxObject}, - { "_wxObject","_class_wxCloseEvent",SwigwxCloseEventTowxObject}, { "_wxObject","_wxCloseEvent",SwigwxCloseEventTowxObject}, - { "_wxObject","_class_wxSizeEvent",SwigwxSizeEventTowxObject}, { "_wxObject","_wxSizeEvent",SwigwxSizeEventTowxObject}, - { "_wxObject","_class_wxEvent",SwigwxEventTowxObject}, { "_wxObject","_wxEvent",SwigwxEventTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -7562,8 +7336,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_class_wxScrollEvent","_class_wxSpinEvent",SwigwxSpinEventTowxScrollEvent}, - { "_class_wxScrollEvent","_wxSpinEvent",SwigwxSpinEventTowxScrollEvent}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, { "_wxWindowID","_time_t",0}, @@ -7598,20 +7370,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxPyCommandEvent",SwigwxPyCommandEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxPyCommandEvent",SwigwxPyCommandEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxTextUrlEvent",SwigwxTextUrlEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxTextUrlEvent",SwigwxTextUrlEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxWindowDestroyEvent",SwigwxWindowDestroyEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxWindowCreateEvent",SwigwxWindowCreateEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxWindowCreateEvent",SwigwxWindowCreateEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxNotifyEvent",SwigwxNotifyEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxNotifyEvent",SwigwxNotifyEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxSpinEvent",SwigwxSpinEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxSpinEvent",SwigwxSpinEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxScrollEvent",SwigwxScrollEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxScrollEvent",SwigwxScrollEventTowxCommandEvent}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/filesys.cpp b/wxPython/src/gtk/filesys.cpp index 03736590c2..65567475e3 100644 --- a/wxPython/src/gtk/filesys.cpp +++ b/wxPython/src/gtk/filesys.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -59,47 +61,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2216,20 +2199,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxObject}, - { "_class_wxObject","_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxObject}, - { "_class_wxObject","_class_wxZipFSHandler",SwigwxZipFSHandlerTowxObject}, - { "_class_wxObject","_wxZipFSHandler",SwigwxZipFSHandlerTowxObject}, - { "_class_wxObject","_class_wxInternetFSHandler",SwigwxInternetFSHandlerTowxObject}, - { "_class_wxObject","_wxInternetFSHandler",SwigwxInternetFSHandlerTowxObject}, - { "_class_wxObject","_class_wxFileSystem",SwigwxFileSystemTowxObject}, - { "_class_wxObject","_wxFileSystem",SwigwxFileSystemTowxObject}, - { "_class_wxObject","_class_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxObject}, - { "_class_wxObject","_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxObject}, - { "_class_wxObject","_class_wxFileSystemHandler",SwigwxFileSystemHandlerTowxObject}, - { "_class_wxObject","_wxFileSystemHandler",SwigwxFileSystemHandlerTowxObject}, - { "_class_wxObject","_class_wxFSFile",SwigwxFSFileTowxObject}, - { "_class_wxObject","_wxFSFile",SwigwxFSFileTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2266,19 +2235,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxObject}, { "_wxObject","_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxObject}, - { "_wxObject","_class_wxZipFSHandler",SwigwxZipFSHandlerTowxObject}, { "_wxObject","_wxZipFSHandler",SwigwxZipFSHandlerTowxObject}, - { "_wxObject","_class_wxInternetFSHandler",SwigwxInternetFSHandlerTowxObject}, { "_wxObject","_wxInternetFSHandler",SwigwxInternetFSHandlerTowxObject}, - { "_wxObject","_class_wxFileSystem",SwigwxFileSystemTowxObject}, { "_wxObject","_wxFileSystem",SwigwxFileSystemTowxObject}, - { "_wxObject","_class_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxObject}, { "_wxObject","_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxObject}, - { "_wxObject","_class_wxFileSystemHandler",SwigwxFileSystemHandlerTowxObject}, { "_wxObject","_wxFileSystemHandler",SwigwxFileSystemHandlerTowxObject}, - { "_wxObject","_class_wxFSFile",SwigwxFSFileTowxObject}, { "_wxObject","_wxFSFile",SwigwxFSFileTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -2294,13 +2256,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFileSystemHandler","_class_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxFileSystemHandler}, { "_wxFileSystemHandler","_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxFileSystemHandler}, - { "_wxFileSystemHandler","_class_wxZipFSHandler",SwigwxZipFSHandlerTowxFileSystemHandler}, { "_wxFileSystemHandler","_wxZipFSHandler",SwigwxZipFSHandlerTowxFileSystemHandler}, - { "_wxFileSystemHandler","_class_wxInternetFSHandler",SwigwxInternetFSHandlerTowxFileSystemHandler}, { "_wxFileSystemHandler","_wxInternetFSHandler",SwigwxInternetFSHandlerTowxFileSystemHandler}, - { "_wxFileSystemHandler","_class_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxFileSystemHandler}, { "_wxFileSystemHandler","_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxFileSystemHandler}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -2339,14 +2297,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxFileSystemHandler","_class_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_wxMemoryFSHandler",SwigwxMemoryFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_class_wxZipFSHandler",SwigwxZipFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_wxZipFSHandler",SwigwxZipFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_class_wxInternetFSHandler",SwigwxInternetFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_wxInternetFSHandler",SwigwxInternetFSHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_class_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxFileSystemHandler}, - { "_class_wxFileSystemHandler","_wxPyFileSystemHandler",SwigwxPyFileSystemHandlerTowxFileSystemHandler}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/frames.cpp b/wxPython/src/gtk/frames.cpp index b95c3bd079..cc1738fec3 100644 --- a/wxPython/src/gtk/frames.cpp +++ b/wxPython/src/gtk/frames.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2252,29 +2235,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxTipWindow",SwigwxTipWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxTipWindow",SwigwxTipWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxMiniFrame",SwigwxMiniFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMiniFrame",SwigwxMiniFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxDialog",SwigwxDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxDialog",SwigwxDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxFrame",SwigwxFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxFrame",SwigwxFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxTopLevelWindow",SwigwxTopLevelWindowTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxTipWindow",SwigwxTipWindowTowxObject}, - { "_class_wxObject","_wxTipWindow",SwigwxTipWindowTowxObject}, - { "_class_wxObject","_class_wxMiniFrame",SwigwxMiniFrameTowxObject}, - { "_class_wxObject","_wxMiniFrame",SwigwxMiniFrameTowxObject}, - { "_class_wxObject","_class_wxDialog",SwigwxDialogTowxObject}, - { "_class_wxObject","_wxDialog",SwigwxDialogTowxObject}, - { "_class_wxObject","_class_wxFrame",SwigwxFrameTowxObject}, - { "_class_wxObject","_wxFrame",SwigwxFrameTowxObject}, - { "_class_wxObject","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxObject}, - { "_class_wxObject","_wxTopLevelWindow",SwigwxTopLevelWindowTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2282,13 +2245,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTopLevelWindow","_class_wxTipWindow",SwigwxTipWindowTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxTipWindow",SwigwxTipWindowTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxMiniFrame",SwigwxMiniFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxMiniFrame",SwigwxMiniFrameTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxDialog",SwigwxDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxDialog",SwigwxDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxFrame",SwigwxFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxFrame",SwigwxFrameTowxTopLevelWindow}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, @@ -2312,38 +2271,15 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTopLevelWindow","_class_wxTipWindow",SwigwxTipWindowTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxTipWindow",SwigwxTipWindowTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxMiniFrame",SwigwxMiniFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxMiniFrame",SwigwxMiniFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxDialog",SwigwxDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxDialog",SwigwxDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxFrame",SwigwxFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxFrame",SwigwxFrameTowxTopLevelWindow}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxTipWindow",SwigwxTipWindowTowxWindow}, - { "_class_wxWindow","_wxTipWindow",SwigwxTipWindowTowxWindow}, - { "_class_wxWindow","_class_wxMiniFrame",SwigwxMiniFrameTowxWindow}, - { "_class_wxWindow","_wxMiniFrame",SwigwxMiniFrameTowxWindow}, - { "_class_wxWindow","_class_wxDialog",SwigwxDialogTowxWindow}, - { "_class_wxWindow","_wxDialog",SwigwxDialogTowxWindow}, - { "_class_wxWindow","_class_wxFrame",SwigwxFrameTowxWindow}, - { "_class_wxWindow","_wxFrame",SwigwxFrameTowxWindow}, - { "_class_wxWindow","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxWindow}, - { "_class_wxWindow","_wxTopLevelWindow",SwigwxTopLevelWindowTowxWindow}, - { "_wxObject","_class_wxTipWindow",SwigwxTipWindowTowxObject}, { "_wxObject","_wxTipWindow",SwigwxTipWindowTowxObject}, - { "_wxObject","_class_wxMiniFrame",SwigwxMiniFrameTowxObject}, { "_wxObject","_wxMiniFrame",SwigwxMiniFrameTowxObject}, - { "_wxObject","_class_wxDialog",SwigwxDialogTowxObject}, { "_wxObject","_wxDialog",SwigwxDialogTowxObject}, - { "_wxObject","_class_wxFrame",SwigwxFrameTowxObject}, { "_wxObject","_wxFrame",SwigwxFrameTowxObject}, - { "_wxObject","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxObject}, { "_wxObject","_wxTopLevelWindow",SwigwxTopLevelWindowTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -2358,9 +2294,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFrame","_class_wxTipWindow",SwigwxTipWindowTowxFrame}, { "_wxFrame","_wxTipWindow",SwigwxTipWindowTowxFrame}, - { "_wxFrame","_class_wxMiniFrame",SwigwxMiniFrameTowxFrame}, { "_wxFrame","_wxMiniFrame",SwigwxMiniFrameTowxFrame}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -2396,30 +2330,16 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxTipWindow",SwigwxTipWindowTowxEvtHandler}, { "_wxEvtHandler","_wxTipWindow",SwigwxTipWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxMiniFrame",SwigwxMiniFrameTowxEvtHandler}, { "_wxEvtHandler","_wxMiniFrame",SwigwxMiniFrameTowxEvtHandler}, - { "_wxEvtHandler","_class_wxDialog",SwigwxDialogTowxEvtHandler}, { "_wxEvtHandler","_wxDialog",SwigwxDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxFrame",SwigwxFrameTowxEvtHandler}, { "_wxEvtHandler","_wxFrame",SwigwxFrameTowxEvtHandler}, - { "_wxEvtHandler","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxEvtHandler}, { "_wxEvtHandler","_wxTopLevelWindow",SwigwxTopLevelWindowTowxEvtHandler}, - { "_wxWindow","_class_wxTipWindow",SwigwxTipWindowTowxWindow}, { "_wxWindow","_wxTipWindow",SwigwxTipWindowTowxWindow}, - { "_wxWindow","_class_wxMiniFrame",SwigwxMiniFrameTowxWindow}, { "_wxWindow","_wxMiniFrame",SwigwxMiniFrameTowxWindow}, - { "_wxWindow","_class_wxDialog",SwigwxDialogTowxWindow}, { "_wxWindow","_wxDialog",SwigwxDialogTowxWindow}, - { "_wxWindow","_class_wxFrame",SwigwxFrameTowxWindow}, { "_wxWindow","_wxFrame",SwigwxFrameTowxWindow}, - { "_wxWindow","_class_wxTopLevelWindow",SwigwxTopLevelWindowTowxWindow}, { "_wxWindow","_wxTopLevelWindow",SwigwxTopLevelWindowTowxWindow}, - { "_class_wxFrame","_class_wxTipWindow",SwigwxTipWindowTowxFrame}, - { "_class_wxFrame","_wxTipWindow",SwigwxTipWindowTowxFrame}, - { "_class_wxFrame","_class_wxMiniFrame",SwigwxMiniFrameTowxFrame}, - { "_class_wxFrame","_wxMiniFrame",SwigwxMiniFrameTowxFrame}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/gdi.cpp b/wxPython/src/gtk/gdi.cpp index bc68332332..74e72d8e84 100644 --- a/wxPython/src/gtk/gdi.cpp +++ b/wxPython/src/gtk/gdi.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -64,47 +66,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -224,6 +207,13 @@ public: private: wxDash* m_dash; }; + +static void wxDC_GetBoundingBox(wxDC* dc, int* x1, int* y1, int* x2, int* y2) { + *x1 = dc->MinX(); + *y1 = dc->MinY(); + *x2 = dc->MaxX(); + *y2 = dc->MaxY(); +} // Alternate 'constructor' wxMemoryDC* wxMemoryDCFromDC(wxDC* oldDC) { return new wxMemoryDC(oldDC); @@ -8661,6 +8651,289 @@ static PyObject *_wrap_wxDC_ResetBoundingBox(PyObject *self, PyObject *args, PyO return _resultobj; } +static PyObject *_wrap_wxDC_GetBoundingBox(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxDC * _arg0; + int * _arg1; + int temp; + int * _arg2; + int temp0; + int * _arg3; + int temp1; + int * _arg4; + int temp2; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; +{ + _arg1 = &temp; +} +{ + _arg2 = &temp0; +} +{ + _arg3 = &temp1; +} +{ + _arg4 = &temp2; +} + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDC_GetBoundingBox",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC_GetBoundingBox. Expected _wxDC_p."); + return NULL; + } + } +{ + wxPy_BEGIN_ALLOW_THREADS; + wxDC_GetBoundingBox(_arg0,_arg1,_arg2,_arg3,_arg4); + + wxPy_END_ALLOW_THREADS; + if (PyErr_Occurred()) return NULL; +} Py_INCREF(Py_None); + _resultobj = Py_None; +{ + PyObject *o; + o = PyInt_FromLong((long) (*_arg1)); + _resultobj = t_output_helper(_resultobj, o); +} +{ + PyObject *o; + o = PyInt_FromLong((long) (*_arg2)); + _resultobj = t_output_helper(_resultobj, o); +} +{ + PyObject *o; + o = PyInt_FromLong((long) (*_arg3)); + _resultobj = t_output_helper(_resultobj, o); +} +{ + PyObject *o; + o = PyInt_FromLong((long) (*_arg4)); + _resultobj = t_output_helper(_resultobj, o); +} + return _resultobj; +} + +static PyObject * wxDC__DrawPointList(wxDC *self,PyObject * pyPoints,PyObject * pyPens) { + bool isFastSeq = PyList_Check(pyPoints) || PyTuple_Check(pyPoints); + bool isFastPens = PyList_Check(pyPens) || PyTuple_Check(pyPens); + int numObjs = 0; + int numPens = 0; + wxPen* pen; + PyObject* obj; + int x1, y1; + int i = 0; + + if (!PySequence_Check(pyPoints)) { + goto err0; + } + if (!PySequence_Check(pyPens)) { + goto err1; + } + numObjs = PySequence_Length(pyPoints); + numPens = PySequence_Length(pyPens); + + for (i = 0; i < numObjs; i++) { + // Use a new pen? + if (i < numPens) { + if (isFastPens) { + obj = PySequence_Fast_GET_ITEM(pyPens, i); + } + else { + obj = PySequence_GetItem(pyPens, i); + } + if (SWIG_GetPtrObj(obj, (void **) &pen, "_wxPen_p")) { + if (!isFastPens) + Py_DECREF(obj); + goto err1; + } + + self->SetPen(*pen); + if (!isFastPens) + Py_DECREF(obj); + } + + // Get the point coordinants + if (isFastSeq) { + obj = PySequence_Fast_GET_ITEM(pyPoints, i); + } + else { + obj = PySequence_GetItem(pyPoints, i); + } + if (! _2int_seq_helper(obj, &x1, &y1)) { + if (!isFastPens) + Py_DECREF(obj); + goto err0; + } + + // Now draw the point + self->DrawPoint(x1, y1); + + if (!isFastSeq) + Py_DECREF(obj); + } + + Py_INCREF(Py_None); + return Py_None; + + err1: + PyErr_SetString(PyExc_TypeError, "Expected a sequence of wxPens"); + return NULL; + err0: + PyErr_SetString(PyExc_TypeError, "Expected a sequence of (x,y) sequences."); + return NULL; + } +static PyObject *_wrap_wxDC__DrawPointList(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + PyObject * _result; + wxDC * _arg0; + PyObject * _arg1; + PyObject * _arg2; + PyObject * _argo0 = 0; + PyObject * _obj1 = 0; + PyObject * _obj2 = 0; + char *_kwnames[] = { "self","pyPoints","pyPens", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDC__DrawPointList",_kwnames,&_argo0,&_obj1,&_obj2)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC__DrawPointList. Expected _wxDC_p."); + return NULL; + } + } +{ + _arg1 = _obj1; +} +{ + _arg2 = _obj2; +} +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = (PyObject *)wxDC__DrawPointList(_arg0,_arg1,_arg2); + + wxPy_END_ALLOW_THREADS; + if (PyErr_Occurred()) return NULL; +}{ + _resultobj = _result; +} + return _resultobj; +} + +static PyObject * wxDC__DrawLineList(wxDC *self,PyObject * pyLines,PyObject * pyPens) { + bool isFastSeq = PyList_Check(pyLines) || PyTuple_Check(pyLines); + bool isFastPens = PyList_Check(pyPens) || PyTuple_Check(pyPens); + int numObjs = 0; + int numPens = 0; + wxPen* pen; + PyObject* obj; + int x1, y1, x2, y2; + int i = 0; + + if (!PySequence_Check(pyLines)) { + goto err0; + } + if (!PySequence_Check(pyPens)) { + goto err1; + } + numObjs = PySequence_Length(pyLines); + numPens = PySequence_Length(pyPens); + + for (i = 0; i < numObjs; i++) { + // Use a new pen? + if (i < numPens) { + if (isFastPens) { + obj = PySequence_Fast_GET_ITEM(pyPens, i); + } + else { + obj = PySequence_GetItem(pyPens, i); + } + if (SWIG_GetPtrObj(obj, (void **) &pen, "_wxPen_p")) { + if (!isFastPens) + Py_DECREF(obj); + goto err1; + } + + self->SetPen(*pen); + if (!isFastPens) + Py_DECREF(obj); + } + + // Get the line coordinants + if (isFastSeq) { + obj = PySequence_Fast_GET_ITEM(pyLines, i); + } + else { + obj = PySequence_GetItem(pyLines, i); + } + if (! _4int_seq_helper(obj, &x1, &y1, &x2, &y2)) { + if (!isFastPens) + Py_DECREF(obj); + goto err0; + } + + // Now draw the line + self->DrawLine(x1, y1, x2, y2); + + if (!isFastSeq) + Py_DECREF(obj); + } + + Py_INCREF(Py_None); + return Py_None; + + err1: + PyErr_SetString(PyExc_TypeError, "Expected a sequence of wxPens"); + return NULL; + err0: + PyErr_SetString(PyExc_TypeError, "Expected a sequence of (x1,y1, x2,y2) sequences."); + return NULL; + } +static PyObject *_wrap_wxDC__DrawLineList(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + PyObject * _result; + wxDC * _arg0; + PyObject * _arg1; + PyObject * _arg2; + PyObject * _argo0 = 0; + PyObject * _obj1 = 0; + PyObject * _obj2 = 0; + char *_kwnames[] = { "self","pyLines","pyPens", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDC__DrawLineList",_kwnames,&_argo0,&_obj1,&_obj2)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC__DrawLineList. Expected _wxDC_p."); + return NULL; + } + } +{ + _arg1 = _obj1; +} +{ + _arg2 = _obj2; +} +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = (PyObject *)wxDC__DrawLineList(_arg0,_arg1,_arg2); + + wxPy_END_ALLOW_THREADS; + if (PyErr_Occurred()) return NULL; +}{ + _resultobj = _result; +} + return _resultobj; +} + static void *SwigwxMemoryDCTowxDC(void *ptr) { wxMemoryDC *src; wxDC *dest; @@ -10882,6 +11155,9 @@ static PyMethodDef gdicMethods[] = { { "new_wxScreenDC", (PyCFunction) _wrap_new_wxScreenDC, METH_VARARGS | METH_KEYWORDS }, { "wxMemoryDC_SelectObject", (PyCFunction) _wrap_wxMemoryDC_SelectObject, METH_VARARGS | METH_KEYWORDS }, { "new_wxMemoryDC", (PyCFunction) _wrap_new_wxMemoryDC, METH_VARARGS | METH_KEYWORDS }, + { "wxDC__DrawLineList", (PyCFunction) _wrap_wxDC__DrawLineList, METH_VARARGS | METH_KEYWORDS }, + { "wxDC__DrawPointList", (PyCFunction) _wrap_wxDC__DrawPointList, METH_VARARGS | METH_KEYWORDS }, + { "wxDC_GetBoundingBox", (PyCFunction) _wrap_wxDC_GetBoundingBox, METH_VARARGS | METH_KEYWORDS }, { "wxDC_ResetBoundingBox", (PyCFunction) _wrap_wxDC_ResetBoundingBox, METH_VARARGS | METH_KEYWORDS }, { "wxDC_CalcBoundingBox", (PyCFunction) _wrap_wxDC_CalcBoundingBox, METH_VARARGS | METH_KEYWORDS }, { "wxDC_SetAxisOrientation", (PyCFunction) _wrap_wxDC_SetAxisOrientation, METH_VARARGS | METH_KEYWORDS }, @@ -11119,91 +11395,25 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_wxPen","_class_wxPyPen",SwigwxPyPenTowxPen}, { "_wxPen","_wxPyPen",SwigwxPyPenTowxPen}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_wxGDIObject","_class_wxRegion",SwigwxRegionTowxGDIObject}, { "_wxGDIObject","_wxRegion",SwigwxRegionTowxGDIObject}, - { "_wxGDIObject","_class_wxPalette",SwigwxPaletteTowxGDIObject}, { "_wxGDIObject","_wxPalette",SwigwxPaletteTowxGDIObject}, - { "_wxGDIObject","_class_wxBrush",SwigwxBrushTowxGDIObject}, { "_wxGDIObject","_wxBrush",SwigwxBrushTowxGDIObject}, - { "_wxGDIObject","_class_wxPyPen",SwigwxPyPenTowxGDIObject}, { "_wxGDIObject","_wxPyPen",SwigwxPyPenTowxGDIObject}, - { "_wxGDIObject","_class_wxPen",SwigwxPenTowxGDIObject}, { "_wxGDIObject","_wxPen",SwigwxPenTowxGDIObject}, - { "_wxGDIObject","_class_wxFont",SwigwxFontTowxGDIObject}, { "_wxGDIObject","_wxFont",SwigwxFontTowxGDIObject}, - { "_wxGDIObject","_class_wxCursor",SwigwxCursorTowxGDIObject}, { "_wxGDIObject","_wxCursor",SwigwxCursorTowxGDIObject}, - { "_wxGDIObject","_class_wxIcon",SwigwxIconTowxGDIObject}, { "_wxGDIObject","_wxIcon",SwigwxIconTowxGDIObject}, - { "_wxGDIObject","_class_wxBitmap",SwigwxBitmapTowxGDIObject}, { "_wxGDIObject","_wxBitmap",SwigwxBitmapTowxGDIObject}, - { "_wxDC","_class_wxPostScriptDC",SwigwxPostScriptDCTowxDC}, { "_wxDC","_wxPostScriptDC",SwigwxPostScriptDCTowxDC}, - { "_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC}, { "_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC}, - { "_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC}, { "_wxDC","_wxPaintDC",SwigwxPaintDCTowxDC}, - { "_wxDC","_class_wxClientDC",SwigwxClientDCTowxDC}, { "_wxDC","_wxClientDC",SwigwxClientDCTowxDC}, - { "_wxDC","_class_wxScreenDC",SwigwxScreenDCTowxDC}, { "_wxDC","_wxScreenDC",SwigwxScreenDCTowxDC}, - { "_wxDC","_class_wxMemoryDC",SwigwxMemoryDCTowxDC}, { "_wxDC","_wxMemoryDC",SwigwxMemoryDCTowxDC}, - { "_class_wxObject","_class_wxRegionIterator",SwigwxRegionIteratorTowxObject}, - { "_class_wxObject","_wxRegionIterator",SwigwxRegionIteratorTowxObject}, - { "_class_wxObject","_class_wxRegion",SwigwxRegionTowxObject}, - { "_class_wxObject","_wxRegion",SwigwxRegionTowxObject}, - { "_class_wxObject","_class_wxImageList",SwigwxImageListTowxObject}, - { "_class_wxObject","_wxImageList",SwigwxImageListTowxObject}, - { "_class_wxObject","_class_wxPalette",SwigwxPaletteTowxObject}, - { "_class_wxObject","_wxPalette",SwigwxPaletteTowxObject}, - { "_class_wxObject","_class_wxPostScriptDC",SwigwxPostScriptDCTowxObject}, - { "_class_wxObject","_wxPostScriptDC",SwigwxPostScriptDCTowxObject}, - { "_class_wxObject","_class_wxWindowDC",SwigwxWindowDCTowxObject}, - { "_class_wxObject","_wxWindowDC",SwigwxWindowDCTowxObject}, - { "_class_wxObject","_class_wxPaintDC",SwigwxPaintDCTowxObject}, - { "_class_wxObject","_wxPaintDC",SwigwxPaintDCTowxObject}, - { "_class_wxObject","_class_wxClientDC",SwigwxClientDCTowxObject}, - { "_class_wxObject","_wxClientDC",SwigwxClientDCTowxObject}, - { "_class_wxObject","_class_wxScreenDC",SwigwxScreenDCTowxObject}, - { "_class_wxObject","_wxScreenDC",SwigwxScreenDCTowxObject}, - { "_class_wxObject","_class_wxMemoryDC",SwigwxMemoryDCTowxObject}, - { "_class_wxObject","_wxMemoryDC",SwigwxMemoryDCTowxObject}, - { "_class_wxObject","_class_wxDC",SwigwxDCTowxObject}, - { "_class_wxObject","_wxDC",SwigwxDCTowxObject}, - { "_class_wxObject","_class_wxBrushList",SwigwxBrushListTowxObject}, - { "_class_wxObject","_wxBrushList",SwigwxBrushListTowxObject}, - { "_class_wxObject","_class_wxBrush",SwigwxBrushTowxObject}, - { "_class_wxObject","_wxBrush",SwigwxBrushTowxObject}, - { "_class_wxObject","_class_wxPenList",SwigwxPenListTowxObject}, - { "_class_wxObject","_wxPenList",SwigwxPenListTowxObject}, - { "_class_wxObject","_class_wxPyPen",SwigwxPyPenTowxObject}, - { "_class_wxObject","_wxPyPen",SwigwxPyPenTowxObject}, - { "_class_wxObject","_class_wxPen",SwigwxPenTowxObject}, - { "_class_wxObject","_wxPen",SwigwxPenTowxObject}, - { "_class_wxObject","_class_wxColourDatabase",SwigwxColourDatabaseTowxObject}, - { "_class_wxObject","_wxColourDatabase",SwigwxColourDatabaseTowxObject}, - { "_class_wxObject","_class_wxColour",SwigwxColourTowxObject}, - { "_class_wxObject","_wxColour",SwigwxColourTowxObject}, - { "_class_wxObject","_class_wxFontList",SwigwxFontListTowxObject}, - { "_class_wxObject","_wxFontList",SwigwxFontListTowxObject}, - { "_class_wxObject","_class_wxFont",SwigwxFontTowxObject}, - { "_class_wxObject","_wxFont",SwigwxFontTowxObject}, - { "_class_wxObject","_class_wxCursor",SwigwxCursorTowxObject}, - { "_class_wxObject","_wxCursor",SwigwxCursorTowxObject}, - { "_class_wxObject","_class_wxIcon",SwigwxIconTowxObject}, - { "_class_wxObject","_wxIcon",SwigwxIconTowxObject}, - { "_class_wxObject","_class_wxMask",SwigwxMaskTowxObject}, - { "_class_wxObject","_wxMask",SwigwxMaskTowxObject}, - { "_class_wxObject","_class_wxBitmap",SwigwxBitmapTowxObject}, - { "_class_wxObject","_wxBitmap",SwigwxBitmapTowxObject}, - { "_class_wxObject","_class_wxGDIObject",SwigwxGDIObjectTowxObject}, - { "_class_wxObject","_wxGDIObject",SwigwxGDIObjectTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -11227,18 +11437,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_int",0}, { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, - { "_class_wxDC","_class_wxPostScriptDC",SwigwxPostScriptDCTowxDC}, - { "_class_wxDC","_wxPostScriptDC",SwigwxPostScriptDCTowxDC}, - { "_class_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC}, - { "_class_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC}, - { "_class_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC}, - { "_class_wxDC","_wxPaintDC",SwigwxPaintDCTowxDC}, - { "_class_wxDC","_class_wxClientDC",SwigwxClientDCTowxDC}, - { "_class_wxDC","_wxClientDC",SwigwxClientDCTowxDC}, - { "_class_wxDC","_class_wxScreenDC",SwigwxScreenDCTowxDC}, - { "_class_wxDC","_wxScreenDC",SwigwxScreenDCTowxDC}, - { "_class_wxDC","_class_wxMemoryDC",SwigwxMemoryDCTowxDC}, - { "_class_wxDC","_wxMemoryDC",SwigwxMemoryDCTowxDC}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, @@ -11250,55 +11448,30 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxRegionIterator",SwigwxRegionIteratorTowxObject}, { "_wxObject","_wxRegionIterator",SwigwxRegionIteratorTowxObject}, - { "_wxObject","_class_wxRegion",SwigwxRegionTowxObject}, { "_wxObject","_wxRegion",SwigwxRegionTowxObject}, - { "_wxObject","_class_wxImageList",SwigwxImageListTowxObject}, { "_wxObject","_wxImageList",SwigwxImageListTowxObject}, - { "_wxObject","_class_wxPalette",SwigwxPaletteTowxObject}, { "_wxObject","_wxPalette",SwigwxPaletteTowxObject}, - { "_wxObject","_class_wxPostScriptDC",SwigwxPostScriptDCTowxObject}, { "_wxObject","_wxPostScriptDC",SwigwxPostScriptDCTowxObject}, - { "_wxObject","_class_wxWindowDC",SwigwxWindowDCTowxObject}, { "_wxObject","_wxWindowDC",SwigwxWindowDCTowxObject}, - { "_wxObject","_class_wxPaintDC",SwigwxPaintDCTowxObject}, { "_wxObject","_wxPaintDC",SwigwxPaintDCTowxObject}, - { "_wxObject","_class_wxClientDC",SwigwxClientDCTowxObject}, { "_wxObject","_wxClientDC",SwigwxClientDCTowxObject}, - { "_wxObject","_class_wxScreenDC",SwigwxScreenDCTowxObject}, { "_wxObject","_wxScreenDC",SwigwxScreenDCTowxObject}, - { "_wxObject","_class_wxMemoryDC",SwigwxMemoryDCTowxObject}, { "_wxObject","_wxMemoryDC",SwigwxMemoryDCTowxObject}, - { "_wxObject","_class_wxDC",SwigwxDCTowxObject}, { "_wxObject","_wxDC",SwigwxDCTowxObject}, - { "_wxObject","_class_wxBrushList",SwigwxBrushListTowxObject}, { "_wxObject","_wxBrushList",SwigwxBrushListTowxObject}, - { "_wxObject","_class_wxBrush",SwigwxBrushTowxObject}, { "_wxObject","_wxBrush",SwigwxBrushTowxObject}, - { "_wxObject","_class_wxPenList",SwigwxPenListTowxObject}, { "_wxObject","_wxPenList",SwigwxPenListTowxObject}, - { "_wxObject","_class_wxPyPen",SwigwxPyPenTowxObject}, { "_wxObject","_wxPyPen",SwigwxPyPenTowxObject}, - { "_wxObject","_class_wxPen",SwigwxPenTowxObject}, { "_wxObject","_wxPen",SwigwxPenTowxObject}, - { "_wxObject","_class_wxColourDatabase",SwigwxColourDatabaseTowxObject}, { "_wxObject","_wxColourDatabase",SwigwxColourDatabaseTowxObject}, - { "_wxObject","_class_wxColour",SwigwxColourTowxObject}, { "_wxObject","_wxColour",SwigwxColourTowxObject}, - { "_wxObject","_class_wxFontList",SwigwxFontListTowxObject}, { "_wxObject","_wxFontList",SwigwxFontListTowxObject}, - { "_wxObject","_class_wxFont",SwigwxFontTowxObject}, { "_wxObject","_wxFont",SwigwxFontTowxObject}, - { "_wxObject","_class_wxCursor",SwigwxCursorTowxObject}, { "_wxObject","_wxCursor",SwigwxCursorTowxObject}, - { "_wxObject","_class_wxIcon",SwigwxIconTowxObject}, { "_wxObject","_wxIcon",SwigwxIconTowxObject}, - { "_wxObject","_class_wxMask",SwigwxMaskTowxObject}, { "_wxObject","_wxMask",SwigwxMaskTowxObject}, - { "_wxObject","_class_wxBitmap",SwigwxBitmapTowxObject}, { "_wxObject","_wxBitmap",SwigwxBitmapTowxObject}, - { "_wxObject","_class_wxGDIObject",SwigwxGDIObjectTowxObject}, { "_wxObject","_wxGDIObject",SwigwxGDIObjectTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -11310,8 +11483,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_int","_uint",0}, { "_unsigned_int","_wxWindowID",0}, { "_unsigned_int","_int",0}, - { "_class_wxPen","_class_wxPyPen",SwigwxPyPenTowxPen}, - { "_class_wxPen","_wxPyPen",SwigwxPyPenTowxPen}, { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, @@ -11324,24 +11495,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxWindowID","_int",0}, { "_wxWindowID","_signed_int",0}, { "_wxWindowID","_unsigned_int",0}, - { "_class_wxGDIObject","_class_wxRegion",SwigwxRegionTowxGDIObject}, - { "_class_wxGDIObject","_wxRegion",SwigwxRegionTowxGDIObject}, - { "_class_wxGDIObject","_class_wxPalette",SwigwxPaletteTowxGDIObject}, - { "_class_wxGDIObject","_wxPalette",SwigwxPaletteTowxGDIObject}, - { "_class_wxGDIObject","_class_wxBrush",SwigwxBrushTowxGDIObject}, - { "_class_wxGDIObject","_wxBrush",SwigwxBrushTowxGDIObject}, - { "_class_wxGDIObject","_class_wxPyPen",SwigwxPyPenTowxGDIObject}, - { "_class_wxGDIObject","_wxPyPen",SwigwxPyPenTowxGDIObject}, - { "_class_wxGDIObject","_class_wxPen",SwigwxPenTowxGDIObject}, - { "_class_wxGDIObject","_wxPen",SwigwxPenTowxGDIObject}, - { "_class_wxGDIObject","_class_wxFont",SwigwxFontTowxGDIObject}, - { "_class_wxGDIObject","_wxFont",SwigwxFontTowxGDIObject}, - { "_class_wxGDIObject","_class_wxCursor",SwigwxCursorTowxGDIObject}, - { "_class_wxGDIObject","_wxCursor",SwigwxCursorTowxGDIObject}, - { "_class_wxGDIObject","_class_wxIcon",SwigwxIconTowxGDIObject}, - { "_class_wxGDIObject","_wxIcon",SwigwxIconTowxGDIObject}, - { "_class_wxGDIObject","_class_wxBitmap",SwigwxBitmapTowxGDIObject}, - { "_class_wxGDIObject","_wxBitmap",SwigwxBitmapTowxGDIObject}, { "_int","_wxCoord",0}, { "_int","_wxPrintQuality",0}, { "_int","_time_t",0}, diff --git a/wxPython/src/gtk/gdi.py b/wxPython/src/gtk/gdi.py index c1020e8062..13eb1f7ed8 100644 --- a/wxPython/src/gtk/gdi.py +++ b/wxPython/src/gtk/gdi.py @@ -845,8 +845,36 @@ class wxDCPtr(wxObjectPtr): def ResetBoundingBox(self, *_args, **_kwargs): val = apply(gdic.wxDC_ResetBoundingBox,(self,) + _args, _kwargs) return val + def GetBoundingBox(self, *_args, **_kwargs): + val = apply(gdic.wxDC_GetBoundingBox,(self,) + _args, _kwargs) + return val + def _DrawPointList(self, *_args, **_kwargs): + val = apply(gdic.wxDC__DrawPointList,(self,) + _args, _kwargs) + return val + def _DrawLineList(self, *_args, **_kwargs): + val = apply(gdic.wxDC__DrawLineList,(self,) + _args, _kwargs) + return val def __repr__(self): return "" % (self.this,) + + def DrawPointList(self, points, pens=None): + if pens is None: + pens = [] + elif isinstance(pens, wxPenPtr): + pens = [pens] + elif len(pens) != len(points): + raise ValueError('points and pens must have same length') + return self._DrawPointList(points, pens) + + def DrawLineList(self, lines, pens=None): + if pens is None: + pens = [] + elif isinstance(pens, wxPenPtr): + pens = [pens] + elif len(pens) != len(lines): + raise ValueError('lines and pens must have same length') + return self._DrawLineList(lines, pens) + class wxDC(wxDCPtr): def __init__(self,this): self.this = this diff --git a/wxPython/src/gtk/grid.cpp b/wxPython/src/gtk/grid.cpp index 3b35438d0e..d78f35d834 100644 --- a/wxPython/src/gtk/grid.cpp +++ b/wxPython/src/gtk/grid.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -14393,32 +14376,11 @@ static PyMethodDef gridcMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxEvent}, { "_wxEvent","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxEvent}, - { "_wxEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxEvent}, { "_wxEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxEvent}, - { "_wxEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxEvent}, { "_wxEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxEvent}, - { "_wxEvent","_class_wxGridEvent",SwigwxGridEventTowxEvent}, { "_wxEvent","_wxGridEvent",SwigwxGridEventTowxEvent}, { "_signed_long","_long",0}, - { "_class_wxGridCellRenderer","_class_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellBoolRenderer",SwigwxGridCellBoolRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellBoolRenderer",SwigwxGridCellBoolRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxGridCellStringRenderer",SwigwxGridCellStringRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxGridCellStringRenderer",SwigwxGridCellStringRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_class_wxPyGridCellRenderer",SwigwxPyGridCellRendererTowxGridCellRenderer}, - { "_class_wxGridCellRenderer","_wxPyGridCellRenderer",SwigwxPyGridCellRendererTowxGridCellRenderer}, - { "_wxGridCellChoiceEditor","_class_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellChoiceEditor}, { "_wxGridCellChoiceEditor","_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellChoiceEditor}, { "_wxPrintQuality","_WXGRIDSELECTIONMODES",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -14430,33 +14392,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxGrid",SwigwxGridTowxEvtHandler}, - { "_class_wxEvtHandler","_wxGrid",SwigwxGridTowxEvtHandler}, - { "_wxNotifyEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxNotifyEvent}, - { "_wxNotifyEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxNotifyEvent}, - { "_wxNotifyEvent","_class_wxGridEvent",SwigwxGridEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxGridEvent",SwigwxGridEventTowxNotifyEvent}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxObject}, - { "_class_wxObject","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxObject}, - { "_class_wxObject","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxObject}, - { "_class_wxObject","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxObject}, - { "_class_wxObject","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxObject}, - { "_class_wxObject","_wxGridSizeEvent",SwigwxGridSizeEventTowxObject}, - { "_class_wxObject","_class_wxGridEvent",SwigwxGridEventTowxObject}, - { "_class_wxObject","_wxGridEvent",SwigwxGridEventTowxObject}, - { "_class_wxObject","_class_wxGrid",SwigwxGridTowxObject}, - { "_class_wxObject","_wxGrid",SwigwxGridTowxObject}, - { "_class_wxObject","_class_wxGridStringTable",SwigwxGridStringTableTowxObject}, - { "_class_wxObject","_wxGridStringTable",SwigwxGridStringTableTowxObject}, - { "_class_wxObject","_class_wxPyGridTableBase",SwigwxPyGridTableBaseTowxObject}, - { "_class_wxObject","_wxPyGridTableBase",SwigwxPyGridTableBaseTowxObject}, - { "_class_wxObject","_class_wxGridTableBase",SwigwxGridTableBaseTowxObject}, - { "_class_wxObject","_wxGridTableBase",SwigwxGridTableBaseTowxObject}, { "_size_t","_WXGRIDSELECTIONMODES",0}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, @@ -14465,7 +14406,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxPanel","_class_wxGrid",SwigwxGridTowxPanel}, { "_wxPanel","_wxGrid",SwigwxGridTowxPanel}, { "_uint","_WXGRIDSELECTIONMODES",0}, { "_uint","_wxCoord",0}, @@ -14476,45 +14416,18 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxEvent}, - { "_class_wxEvent","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxEvent}, - { "_class_wxEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxEvent}, - { "_class_wxEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxEvent}, - { "_class_wxEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxEvent}, - { "_class_wxEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxEvent}, - { "_class_wxEvent","_class_wxGridEvent",SwigwxGridEventTowxEvent}, - { "_class_wxEvent","_wxGridEvent",SwigwxGridEventTowxEvent}, - { "_class_wxGridCellChoiceEditor","_class_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellChoiceEditor}, - { "_class_wxGridCellChoiceEditor","_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellChoiceEditor}, - { "_wxCommandEvent","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxCommandEvent}, { "_wxCommandEvent","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxCommandEvent}, { "_wxCommandEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxCommandEvent}, { "_wxCommandEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxGridEvent",SwigwxGridEventTowxCommandEvent}, { "_wxCommandEvent","_wxGridEvent",SwigwxGridEventTowxCommandEvent}, { "_char","_wxChar",0}, - { "_wxGridCellStringRenderer","_class_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellStringRenderer}, { "_wxGridCellStringRenderer","_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellStringRenderer}, - { "_wxGridCellStringRenderer","_class_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellStringRenderer}, { "_wxGridCellStringRenderer","_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellStringRenderer}, - { "_wxGridCellStringRenderer","_class_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellStringRenderer}, { "_wxGridCellStringRenderer","_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellStringRenderer}, - { "_wxGridCellStringRenderer","_class_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellStringRenderer}, { "_wxGridCellStringRenderer","_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellStringRenderer}, - { "_wxGridCellStringRenderer","_class_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellStringRenderer}, { "_wxGridCellStringRenderer","_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellStringRenderer}, - { "_class_wxNotifyEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_class_wxGridEvent",SwigwxGridEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxGridEvent",SwigwxGridEventTowxNotifyEvent}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, - { "_wxGridTableBase","_class_wxGridStringTable",SwigwxGridStringTableTowxGridTableBase}, { "_wxGridTableBase","_wxGridStringTable",SwigwxGridStringTableTowxGridTableBase}, - { "_wxGridTableBase","_class_wxPyGridTableBase",SwigwxPyGridTableBaseTowxGridTableBase}, { "_wxGridTableBase","_wxPyGridTableBase",SwigwxPyGridTableBaseTowxGridTableBase}, { "_EBool","_WXGRIDSELECTIONMODES",0}, { "_EBool","_wxCoord",0}, @@ -14522,12 +14435,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_signed_int",0}, { "_EBool","_int",0}, { "_EBool","_wxWindowID",0}, - { "_class_wxGridCellTextEditor","_class_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellTextEditor}, - { "_class_wxGridCellTextEditor","_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellTextEditor}, - { "_class_wxGridCellTextEditor","_class_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellTextEditor}, - { "_class_wxGridCellTextEditor","_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellTextEditor}, - { "_class_wxGridCellTextEditor","_class_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellTextEditor}, - { "_class_wxGridCellTextEditor","_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellTextEditor}, { "_unsigned_long","_long",0}, { "_WXGRIDSELECTIONMODES","_int",0}, { "_WXGRIDSELECTIONMODES","_signed_int",0}, @@ -14540,72 +14447,36 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXGRIDSELECTIONMODES","_wxPrintQuality",0}, { "_WXGRIDSELECTIONMODES","_wxCoord",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxGridCellStringRenderer","_class_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_class_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_class_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_class_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_class_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellStringRenderer}, - { "_class_wxGridCellStringRenderer","_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellStringRenderer}, - { "_class_wxPanel","_class_wxGrid",SwigwxGridTowxPanel}, - { "_class_wxPanel","_wxGrid",SwigwxGridTowxPanel}, { "_signed_int","_WXGRIDSELECTIONMODES",0}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_wxGridCellEditor","_class_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellChoiceEditor",SwigwxGridCellChoiceEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellChoiceEditor",SwigwxGridCellChoiceEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellBoolEditor",SwigwxGridCellBoolEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellBoolEditor",SwigwxGridCellBoolEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxGridCellTextEditor",SwigwxGridCellTextEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxGridCellTextEditor",SwigwxGridCellTextEditorTowxGridCellEditor}, - { "_wxGridCellEditor","_class_wxPyGridCellEditor",SwigwxPyGridCellEditorTowxGridCellEditor}, { "_wxGridCellEditor","_wxPyGridCellEditor",SwigwxPyGridCellEditorTowxGridCellEditor}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, - { "_wxGridCellAttrProvider","_class_wxPyGridCellAttrProvider",SwigwxPyGridCellAttrProviderTowxGridCellAttrProvider}, { "_wxGridCellAttrProvider","_wxPyGridCellAttrProvider",SwigwxPyGridCellAttrProviderTowxGridCellAttrProvider}, - { "_class_wxGridTableBase","_class_wxGridStringTable",SwigwxGridStringTableTowxGridTableBase}, - { "_class_wxGridTableBase","_wxGridStringTable",SwigwxGridStringTableTowxGridTableBase}, - { "_class_wxGridTableBase","_class_wxPyGridTableBase",SwigwxPyGridTableBaseTowxGridTableBase}, - { "_class_wxGridTableBase","_wxPyGridTableBase",SwigwxPyGridTableBaseTowxGridTableBase}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxGrid",SwigwxGridTowxWindow}, - { "_class_wxWindow","_wxGrid",SwigwxGridTowxWindow}, - { "_wxObject","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxObject}, { "_wxObject","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxObject}, - { "_wxObject","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxObject}, { "_wxObject","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxObject}, - { "_wxObject","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxObject}, { "_wxObject","_wxGridSizeEvent",SwigwxGridSizeEventTowxObject}, - { "_wxObject","_class_wxGridEvent",SwigwxGridEventTowxObject}, { "_wxObject","_wxGridEvent",SwigwxGridEventTowxObject}, - { "_wxObject","_class_wxGrid",SwigwxGridTowxObject}, { "_wxObject","_wxGrid",SwigwxGridTowxObject}, - { "_wxObject","_class_wxGridStringTable",SwigwxGridStringTableTowxObject}, { "_wxObject","_wxGridStringTable",SwigwxGridStringTableTowxObject}, - { "_wxObject","_class_wxPyGridTableBase",SwigwxPyGridTableBaseTowxObject}, { "_wxObject","_wxPyGridTableBase",SwigwxPyGridTableBaseTowxObject}, - { "_wxObject","_class_wxGridTableBase",SwigwxGridTableBaseTowxObject}, { "_wxObject","_wxGridTableBase",SwigwxGridTableBaseTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, - { "_wxScrolledWindow","_class_wxGrid",SwigwxGridTowxScrolledWindow}, { "_wxScrolledWindow","_wxGrid",SwigwxGridTowxScrolledWindow}, { "_unsigned_char","_byte",0}, { "_unsigned_int","_WXGRIDSELECTIONMODES",0}, @@ -14647,24 +14518,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_class_wxGridCellEditor","_class_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellEnumEditor",SwigwxGridCellEnumEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellChoiceEditor",SwigwxGridCellChoiceEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellChoiceEditor",SwigwxGridCellChoiceEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellBoolEditor",SwigwxGridCellBoolEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellBoolEditor",SwigwxGridCellBoolEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxGridCellTextEditor",SwigwxGridCellTextEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxGridCellTextEditor",SwigwxGridCellTextEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_class_wxPyGridCellEditor",SwigwxPyGridCellEditorTowxGridCellEditor}, - { "_class_wxGridCellEditor","_wxPyGridCellEditor",SwigwxPyGridCellEditorTowxGridCellEditor}, - { "_class_wxGridCellAttrProvider","_class_wxPyGridCellAttrProvider",SwigwxPyGridCellAttrProviderTowxGridCellAttrProvider}, - { "_class_wxGridCellAttrProvider","_wxPyGridCellAttrProvider",SwigwxPyGridCellAttrProviderTowxGridCellAttrProvider}, { "_wxCoord","_WXGRIDSELECTIONMODES",0}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, @@ -14675,41 +14528,18 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxGridCellRenderer","_class_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellAutoWrapStringRenderer",SwigwxGridCellAutoWrapStringRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellEnumRenderer",SwigwxGridCellEnumRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellDateTimeRenderer",SwigwxGridCellDateTimeRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellBoolRenderer",SwigwxGridCellBoolRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellBoolRenderer",SwigwxGridCellBoolRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellFloatRenderer",SwigwxGridCellFloatRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellNumberRenderer",SwigwxGridCellNumberRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxGridCellStringRenderer",SwigwxGridCellStringRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxGridCellStringRenderer",SwigwxGridCellStringRendererTowxGridCellRenderer}, - { "_wxGridCellRenderer","_class_wxPyGridCellRenderer",SwigwxPyGridCellRendererTowxGridCellRenderer}, { "_wxGridCellRenderer","_wxPyGridCellRenderer",SwigwxPyGridCellRendererTowxGridCellRenderer}, - { "_wxGridCellTextEditor","_class_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellTextEditor}, { "_wxGridCellTextEditor","_wxGridCellAutoWrapStringEditor",SwigwxGridCellAutoWrapStringEditorTowxGridCellTextEditor}, - { "_wxGridCellTextEditor","_class_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellTextEditor}, { "_wxGridCellTextEditor","_wxGridCellFloatEditor",SwigwxGridCellFloatEditorTowxGridCellTextEditor}, - { "_wxGridCellTextEditor","_class_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellTextEditor}, { "_wxGridCellTextEditor","_wxGridCellNumberEditor",SwigwxGridCellNumberEditorTowxGridCellTextEditor}, - { "_class_wxCommandEvent","_class_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxGridEditorCreatedEvent",SwigwxGridEditorCreatedEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxGridRangeSelectEvent",SwigwxGridRangeSelectEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxGridSizeEvent",SwigwxGridSizeEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxGridSizeEvent",SwigwxGridSizeEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxGridEvent",SwigwxGridEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxGridEvent",SwigwxGridEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxGrid",SwigwxGridTowxEvtHandler}, { "_wxEvtHandler","_wxGrid",SwigwxGridTowxEvtHandler}, - { "_class_wxScrolledWindow","_class_wxGrid",SwigwxGridTowxScrolledWindow}, - { "_class_wxScrolledWindow","_wxGrid",SwigwxGridTowxScrolledWindow}, - { "_wxWindow","_class_wxGrid",SwigwxGridTowxWindow}, { "_wxWindow","_wxGrid",SwigwxGridTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/help.cpp b/wxPython/src/gtk/help.cpp index 7d53dc3cc1..d1dc4457dc 100644 --- a/wxPython/src/gtk/help.cpp +++ b/wxPython/src/gtk/help.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -56,47 +58,28 @@ extern PyObject *SWIG_newvarlink(void); #include "export.h" #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -1131,9 +1114,7 @@ static PyMethodDef helpcMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxEvent}, { "_wxEvent","_wxContextMenuEvent",SwigwxContextMenuEventTowxEvent}, - { "_wxEvent","_class_wxHelpEvent",SwigwxHelpEventTowxEvent}, { "_wxEvent","_wxHelpEvent",SwigwxHelpEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -1145,21 +1126,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxEvtHandler}, - { "_class_wxEvtHandler","_wxContextHelpButton",SwigwxContextHelpButtonTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_wxBitmapButton","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxBitmapButton}, { "_wxBitmapButton","_wxContextHelpButton",SwigwxContextHelpButtonTowxBitmapButton}, - { "_class_wxObject","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxObject}, - { "_class_wxObject","_wxContextHelpButton",SwigwxContextHelpButtonTowxObject}, - { "_class_wxObject","_class_wxContextHelp",SwigwxContextHelpTowxObject}, - { "_class_wxObject","_wxContextHelp",SwigwxContextHelpTowxObject}, - { "_class_wxObject","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxObject}, - { "_class_wxObject","_wxContextMenuEvent",SwigwxContextMenuEventTowxObject}, - { "_class_wxObject","_class_wxHelpEvent",SwigwxHelpEventTowxObject}, - { "_class_wxObject","_wxHelpEvent",SwigwxHelpEventTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -1175,18 +1145,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxEvent}, - { "_class_wxEvent","_wxContextMenuEvent",SwigwxContextMenuEventTowxEvent}, - { "_class_wxEvent","_class_wxHelpEvent",SwigwxHelpEventTowxEvent}, - { "_class_wxEvent","_wxHelpEvent",SwigwxHelpEventTowxEvent}, - { "_wxCommandEvent","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxCommandEvent}, { "_wxCommandEvent","_wxContextMenuEvent",SwigwxContextMenuEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxHelpEvent",SwigwxHelpEventTowxCommandEvent}, { "_wxCommandEvent","_wxHelpEvent",SwigwxHelpEventTowxCommandEvent}, - { "_class_wxButton","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxButton}, - { "_class_wxButton","_wxContextHelpButton",SwigwxContextHelpButtonTowxButton}, { "_char","_wxChar",0}, - { "_wxHelpProvider","_class_wxSimpleHelpProvider",SwigwxSimpleHelpProviderTowxHelpProvider}, { "_wxHelpProvider","_wxSimpleHelpProvider",SwigwxSimpleHelpProviderTowxHelpProvider}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, @@ -1206,20 +1167,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxWindow}, - { "_class_wxWindow","_wxContextHelpButton",SwigwxContextHelpButtonTowxWindow}, - { "_wxObject","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxObject}, { "_wxObject","_wxContextHelpButton",SwigwxContextHelpButtonTowxObject}, - { "_wxObject","_class_wxContextHelp",SwigwxContextHelpTowxObject}, { "_wxObject","_wxContextHelp",SwigwxContextHelpTowxObject}, - { "_wxObject","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxObject}, { "_wxObject","_wxContextMenuEvent",SwigwxContextMenuEventTowxObject}, - { "_wxObject","_class_wxHelpEvent",SwigwxHelpEventTowxObject}, { "_wxObject","_wxHelpEvent",SwigwxHelpEventTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxControl}, { "_wxControl","_wxContextHelpButton",SwigwxContextHelpButtonTowxControl}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -1231,8 +1185,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_class_wxBitmapButton","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxBitmapButton}, - { "_class_wxBitmapButton","_wxContextHelpButton",SwigwxContextHelpButtonTowxBitmapButton}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, { "_wxWindowID","_time_t",0}, @@ -1258,10 +1210,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_wxButton","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxButton}, { "_wxButton","_wxContextHelpButton",SwigwxContextHelpButtonTowxButton}, - { "_class_wxControl","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxControl}, - { "_class_wxControl","_wxContextHelpButton",SwigwxContextHelpButtonTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -1271,15 +1220,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxContextMenuEvent",SwigwxContextMenuEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxContextMenuEvent",SwigwxContextMenuEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxHelpEvent",SwigwxHelpEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxHelpEvent",SwigwxHelpEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxEvtHandler}, { "_wxEvtHandler","_wxContextHelpButton",SwigwxContextHelpButtonTowxEvtHandler}, - { "_class_wxHelpProvider","_class_wxSimpleHelpProvider",SwigwxSimpleHelpProviderTowxHelpProvider}, - { "_class_wxHelpProvider","_wxSimpleHelpProvider",SwigwxSimpleHelpProviderTowxHelpProvider}, - { "_wxWindow","_class_wxContextHelpButton",SwigwxContextHelpButtonTowxWindow}, { "_wxWindow","_wxContextHelpButton",SwigwxContextHelpButtonTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/html.cpp b/wxPython/src/gtk/html.cpp index db74c73a63..f996b096e5 100644 --- a/wxPython/src/gtk/html.cpp +++ b/wxPython/src/gtk/html.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -63,47 +65,28 @@ extern PyObject *SWIG_newvarlink(void); #include "printfw.h" -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -4232,6 +4215,57 @@ static PyObject *_wrap_wxHtmlWindow_LoadPage(PyObject *self, PyObject *args, PyO return _resultobj; } +#define wxHtmlWindow_AppendToPage(_swigobj,_swigarg0) (_swigobj->AppendToPage(_swigarg0)) +static PyObject *_wrap_wxHtmlWindow_AppendToPage(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxPyHtmlWindow * _arg0; + wxString * _arg1; + PyObject * _argo0 = 0; + PyObject * _obj1 = 0; + char *_kwnames[] = { "self","source", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxHtmlWindow_AppendToPage",_kwnames,&_argo0,&_obj1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyHtmlWindow_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxHtmlWindow_AppendToPage. Expected _wxPyHtmlWindow_p."); + return NULL; + } + } +{ +#if PYTHON_API_VERSION >= 1009 + char* tmpPtr; int tmpSize; + if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) { + PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + return NULL; + } + if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1) + return NULL; + _arg1 = new wxString(tmpPtr, tmpSize); +#else + if (!PyString_Check(_obj1)) { + PyErr_SetString(PyExc_TypeError, wxStringErrorMsg); + return NULL; + } + _arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1)); +#endif +} +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = (bool )wxHtmlWindow_AppendToPage(_arg0,*_arg1); + + wxPy_END_ALLOW_THREADS; +} _resultobj = Py_BuildValue("i",_result); +{ + if (_obj1) + delete _arg1; +} + return _resultobj; +} + #define wxHtmlWindow_GetOpenedPage(_swigobj) (_swigobj->GetOpenedPage()) static PyObject *_wrap_wxHtmlWindow_GetOpenedPage(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -6228,6 +6262,7 @@ static PyMethodDef htmlcMethods[] = { { "wxHtmlWindow_GetOpenedPageTitle", (PyCFunction) _wrap_wxHtmlWindow_GetOpenedPageTitle, METH_VARARGS | METH_KEYWORDS }, { "wxHtmlWindow_GetOpenedAnchor", (PyCFunction) _wrap_wxHtmlWindow_GetOpenedAnchor, METH_VARARGS | METH_KEYWORDS }, { "wxHtmlWindow_GetOpenedPage", (PyCFunction) _wrap_wxHtmlWindow_GetOpenedPage, METH_VARARGS | METH_KEYWORDS }, + { "wxHtmlWindow_AppendToPage", (PyCFunction) _wrap_wxHtmlWindow_AppendToPage, METH_VARARGS | METH_KEYWORDS }, { "wxHtmlWindow_LoadPage", (PyCFunction) _wrap_wxHtmlWindow_LoadPage, METH_VARARGS | METH_KEYWORDS }, { "wxHtmlWindow_SetPage", (PyCFunction) _wrap_wxHtmlWindow_SetPage, METH_VARARGS | METH_KEYWORDS }, { "wxHtmlWindow__setCallbackInfo", (PyCFunction) _wrap_wxHtmlWindow__setCallbackInfo, METH_VARARGS | METH_KEYWORDS }, @@ -6347,8 +6382,6 @@ static PyMethodDef htmlcMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_class_wxHtmlParser","_class_wxHtmlWinParser",SwigwxHtmlWinParserTowxHtmlParser}, - { "_class_wxHtmlParser","_wxHtmlWinParser",SwigwxHtmlWinParserTowxHtmlParser}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, { "_wxPrintQuality","_int",0}, @@ -6359,45 +6392,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxEvtHandler}, { "_byte","_unsigned_char",0}, - { "_wxPyPrintout","_class_wxHtmlPrintout",SwigwxHtmlPrintoutTowxPyPrintout}, { "_wxPyPrintout","_wxHtmlPrintout",SwigwxHtmlPrintoutTowxPyPrintout}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxHtmlEasyPrinting",SwigwxHtmlEasyPrintingTowxObject}, - { "_class_wxObject","_wxHtmlEasyPrinting",SwigwxHtmlEasyPrintingTowxObject}, - { "_class_wxObject","_class_wxHtmlPrintout",SwigwxHtmlPrintoutTowxObject}, - { "_class_wxObject","_wxHtmlPrintout",SwigwxHtmlPrintoutTowxObject}, - { "_class_wxObject","_class_wxHtmlDCRenderer",SwigwxHtmlDCRendererTowxObject}, - { "_class_wxObject","_wxHtmlDCRenderer",SwigwxHtmlDCRendererTowxObject}, - { "_class_wxObject","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxObject}, - { "_class_wxObject","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxObject}, - { "_class_wxObject","_class_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxObject}, - { "_class_wxObject","_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxObject}, - { "_class_wxObject","_class_wxHtmlFontCell",SwigwxHtmlFontCellTowxObject}, - { "_class_wxObject","_wxHtmlFontCell",SwigwxHtmlFontCellTowxObject}, - { "_class_wxObject","_class_wxHtmlColourCell",SwigwxHtmlColourCellTowxObject}, - { "_class_wxObject","_wxHtmlColourCell",SwigwxHtmlColourCellTowxObject}, - { "_class_wxObject","_class_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxObject}, - { "_class_wxObject","_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxObject}, - { "_class_wxObject","_class_wxHtmlWordCell",SwigwxHtmlWordCellTowxObject}, - { "_class_wxObject","_wxHtmlWordCell",SwigwxHtmlWordCellTowxObject}, - { "_class_wxObject","_class_wxHtmlCell",SwigwxHtmlCellTowxObject}, - { "_class_wxObject","_wxHtmlCell",SwigwxHtmlCellTowxObject}, - { "_class_wxObject","_class_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxObject}, - { "_class_wxObject","_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxObject}, - { "_class_wxObject","_class_wxPyHtmlTagHandler",SwigwxPyHtmlTagHandlerTowxObject}, - { "_class_wxObject","_wxPyHtmlTagHandler",SwigwxPyHtmlTagHandlerTowxObject}, - { "_class_wxObject","_class_wxHtmlWinParser",SwigwxHtmlWinParserTowxObject}, - { "_class_wxObject","_wxHtmlWinParser",SwigwxHtmlWinParserTowxObject}, - { "_class_wxObject","_class_wxHtmlParser",SwigwxHtmlParserTowxObject}, - { "_class_wxObject","_wxHtmlParser",SwigwxHtmlParserTowxObject}, - { "_class_wxObject","_class_wxHtmlTag",SwigwxHtmlTagTowxObject}, - { "_class_wxObject","_wxHtmlTag",SwigwxHtmlTagTowxObject}, - { "_class_wxObject","_class_wxHtmlLinkInfo",SwigwxHtmlLinkInfoTowxObject}, - { "_class_wxObject","_wxHtmlLinkInfo",SwigwxHtmlLinkInfoTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -6405,10 +6403,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxPanel","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxPanel}, { "_wxPanel","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxPanel}, - { "_class_wxPyPrintout","_class_wxHtmlPrintout",SwigwxHtmlPrintoutTowxPyPrintout}, - { "_class_wxPyPrintout","_wxHtmlPrintout",SwigwxHtmlPrintoutTowxPyPrintout}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, { "_uint","_time_t",0}, @@ -6417,19 +6412,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_wxHtmlCell","_class_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxHtmlCell}, { "_wxHtmlCell","_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxHtmlCell}, - { "_wxHtmlCell","_class_wxHtmlFontCell",SwigwxHtmlFontCellTowxHtmlCell}, { "_wxHtmlCell","_wxHtmlFontCell",SwigwxHtmlFontCellTowxHtmlCell}, - { "_wxHtmlCell","_class_wxHtmlColourCell",SwigwxHtmlColourCellTowxHtmlCell}, { "_wxHtmlCell","_wxHtmlColourCell",SwigwxHtmlColourCellTowxHtmlCell}, - { "_wxHtmlCell","_class_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxHtmlCell}, { "_wxHtmlCell","_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxHtmlCell}, - { "_wxHtmlCell","_class_wxHtmlWordCell",SwigwxHtmlWordCellTowxHtmlCell}, { "_wxHtmlCell","_wxHtmlWordCell",SwigwxHtmlWordCellTowxHtmlCell}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, - { "_wxPyHtmlTagHandler","_class_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxPyHtmlTagHandler}, { "_wxPyHtmlTagHandler","_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxPyHtmlTagHandler}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, @@ -6438,8 +6427,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxPanel","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxPanel}, - { "_class_wxPanel","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxPanel}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, @@ -6449,58 +6436,27 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, - { "_class_wxPyHtmlTagHandler","_class_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxPyHtmlTagHandler}, - { "_class_wxPyHtmlTagHandler","_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxPyHtmlTagHandler}, { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxWindow}, - { "_class_wxWindow","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxWindow}, - { "_wxObject","_class_wxHtmlEasyPrinting",SwigwxHtmlEasyPrintingTowxObject}, { "_wxObject","_wxHtmlEasyPrinting",SwigwxHtmlEasyPrintingTowxObject}, - { "_wxObject","_class_wxHtmlPrintout",SwigwxHtmlPrintoutTowxObject}, { "_wxObject","_wxHtmlPrintout",SwigwxHtmlPrintoutTowxObject}, - { "_wxObject","_class_wxHtmlDCRenderer",SwigwxHtmlDCRendererTowxObject}, { "_wxObject","_wxHtmlDCRenderer",SwigwxHtmlDCRendererTowxObject}, - { "_wxObject","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxObject}, { "_wxObject","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxObject}, - { "_wxObject","_class_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxObject}, { "_wxObject","_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxObject}, - { "_wxObject","_class_wxHtmlFontCell",SwigwxHtmlFontCellTowxObject}, { "_wxObject","_wxHtmlFontCell",SwigwxHtmlFontCellTowxObject}, - { "_wxObject","_class_wxHtmlColourCell",SwigwxHtmlColourCellTowxObject}, { "_wxObject","_wxHtmlColourCell",SwigwxHtmlColourCellTowxObject}, - { "_wxObject","_class_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxObject}, { "_wxObject","_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxObject}, - { "_wxObject","_class_wxHtmlWordCell",SwigwxHtmlWordCellTowxObject}, { "_wxObject","_wxHtmlWordCell",SwigwxHtmlWordCellTowxObject}, - { "_wxObject","_class_wxHtmlCell",SwigwxHtmlCellTowxObject}, { "_wxObject","_wxHtmlCell",SwigwxHtmlCellTowxObject}, - { "_wxObject","_class_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxObject}, { "_wxObject","_wxPyHtmlWinTagHandler",SwigwxPyHtmlWinTagHandlerTowxObject}, - { "_wxObject","_class_wxPyHtmlTagHandler",SwigwxPyHtmlTagHandlerTowxObject}, { "_wxObject","_wxPyHtmlTagHandler",SwigwxPyHtmlTagHandlerTowxObject}, - { "_wxObject","_class_wxHtmlWinParser",SwigwxHtmlWinParserTowxObject}, { "_wxObject","_wxHtmlWinParser",SwigwxHtmlWinParserTowxObject}, - { "_wxObject","_class_wxHtmlParser",SwigwxHtmlParserTowxObject}, { "_wxObject","_wxHtmlParser",SwigwxHtmlParserTowxObject}, - { "_wxObject","_class_wxHtmlTag",SwigwxHtmlTagTowxObject}, { "_wxObject","_wxHtmlTag",SwigwxHtmlTagTowxObject}, - { "_wxObject","_class_wxHtmlLinkInfo",SwigwxHtmlLinkInfoTowxObject}, { "_wxObject","_wxHtmlLinkInfo",SwigwxHtmlLinkInfoTowxObject}, - { "_class_wxHtmlCell","_class_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxHtmlCell}, - { "_class_wxHtmlCell","_wxHtmlWidgetCell",SwigwxHtmlWidgetCellTowxHtmlCell}, - { "_class_wxHtmlCell","_class_wxHtmlFontCell",SwigwxHtmlFontCellTowxHtmlCell}, - { "_class_wxHtmlCell","_wxHtmlFontCell",SwigwxHtmlFontCellTowxHtmlCell}, - { "_class_wxHtmlCell","_class_wxHtmlColourCell",SwigwxHtmlColourCellTowxHtmlCell}, - { "_class_wxHtmlCell","_wxHtmlColourCell",SwigwxHtmlColourCellTowxHtmlCell}, - { "_class_wxHtmlCell","_class_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxHtmlCell}, - { "_class_wxHtmlCell","_wxHtmlContainerCell",SwigwxHtmlContainerCellTowxHtmlCell}, - { "_class_wxHtmlCell","_class_wxHtmlWordCell",SwigwxHtmlWordCellTowxHtmlCell}, - { "_class_wxHtmlCell","_wxHtmlWordCell",SwigwxHtmlWordCellTowxHtmlCell}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, - { "_wxScrolledWindow","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxScrolledWindow}, { "_wxScrolledWindow","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxScrolledWindow}, { "_unsigned_char","_byte",0}, { "_unsigned_int","_wxCoord",0}, @@ -6551,13 +6507,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxHtmlParser","_class_wxHtmlWinParser",SwigwxHtmlWinParserTowxHtmlParser}, { "_wxHtmlParser","_wxHtmlWinParser",SwigwxHtmlWinParserTowxHtmlParser}, - { "_wxEvtHandler","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxEvtHandler}, { "_wxEvtHandler","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxEvtHandler}, - { "_class_wxScrolledWindow","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxScrolledWindow}, - { "_class_wxScrolledWindow","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxScrolledWindow}, - { "_wxWindow","_class_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxWindow}, { "_wxWindow","_wxPyHtmlWindow",SwigwxPyHtmlWindowTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/html.py b/wxPython/src/gtk/html.py index 77afb80d45..2c2c6c31cd 100644 --- a/wxPython/src/gtk/html.py +++ b/wxPython/src/gtk/html.py @@ -520,6 +520,9 @@ class wxHtmlWindowPtr(wxScrolledWindowPtr): def LoadPage(self, *_args, **_kwargs): val = apply(htmlc.wxHtmlWindow_LoadPage,(self,) + _args, _kwargs) return val + def AppendToPage(self, *_args, **_kwargs): + val = apply(htmlc.wxHtmlWindow_AppendToPage,(self,) + _args, _kwargs) + return val def GetOpenedPage(self, *_args, **_kwargs): val = apply(htmlc.wxHtmlWindow_GetOpenedPage,(self,) + _args, _kwargs) return val diff --git a/wxPython/src/gtk/htmlhelp.cpp b/wxPython/src/gtk/htmlhelp.cpp index 58237236ba..0b1a156f02 100644 --- a/wxPython/src/gtk/htmlhelp.cpp +++ b/wxPython/src/gtk/htmlhelp.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -61,47 +63,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2535,17 +2518,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxEvtHandler}, - { "_class_wxEvtHandler","_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxObject}, - { "_class_wxObject","_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxObject}, - { "_class_wxObject","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxObject}, - { "_class_wxObject","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2553,7 +2528,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTopLevelWindow","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxTopLevelWindow}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, @@ -2577,8 +2551,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTopLevelWindow","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxTopLevelWindow}, { "_WXTYPE","_wxDateTime_t",0}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, @@ -2586,11 +2558,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxWindow}, - { "_class_wxWindow","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxWindow}, - { "_wxObject","_class_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxObject}, { "_wxObject","_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxObject}, - { "_wxObject","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxObject}, { "_wxObject","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -2606,7 +2574,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFrame","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxFrame}, { "_wxFrame","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxFrame}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -2645,14 +2612,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxEvtHandler}, { "_wxEvtHandler","_wxHtmlHelpController",SwigwxHtmlHelpControllerTowxEvtHandler}, - { "_wxEvtHandler","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxEvtHandler}, { "_wxEvtHandler","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxEvtHandler}, - { "_wxWindow","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxWindow}, { "_wxWindow","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxWindow}, - { "_class_wxFrame","_class_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxFrame}, - { "_class_wxFrame","_wxHtmlHelpFrame",SwigwxHtmlHelpFrameTowxFrame}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/image.cpp b/wxPython/src/gtk/image.cpp index b77efd75c1..c89b012144 100644 --- a/wxPython/src/gtk/image.cpp +++ b/wxPython/src/gtk/image.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -56,47 +58,28 @@ extern PyObject *SWIG_newvarlink(void); #include "helpers.h" #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2451,41 +2434,16 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_wxImageHandler","_class_wxTIFFHandler",SwigwxTIFFHandlerTowxImageHandler}, { "_wxImageHandler","_wxTIFFHandler",SwigwxTIFFHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxPCXHandler",SwigwxPCXHandlerTowxImageHandler}, { "_wxImageHandler","_wxPCXHandler",SwigwxPCXHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxPNMHandler",SwigwxPNMHandlerTowxImageHandler}, { "_wxImageHandler","_wxPNMHandler",SwigwxPNMHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxGIFHandler",SwigwxGIFHandlerTowxImageHandler}, { "_wxImageHandler","_wxGIFHandler",SwigwxGIFHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxBMPHandler",SwigwxBMPHandlerTowxImageHandler}, { "_wxImageHandler","_wxBMPHandler",SwigwxBMPHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxJPEGHandler",SwigwxJPEGHandlerTowxImageHandler}, { "_wxImageHandler","_wxJPEGHandler",SwigwxJPEGHandlerTowxImageHandler}, - { "_wxImageHandler","_class_wxPNGHandler",SwigwxPNGHandlerTowxImageHandler}, { "_wxImageHandler","_wxPNGHandler",SwigwxPNGHandlerTowxImageHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxImage",SwigwxImageTowxObject}, - { "_class_wxObject","_wxImage",SwigwxImageTowxObject}, - { "_class_wxObject","_class_wxTIFFHandler",SwigwxTIFFHandlerTowxObject}, - { "_class_wxObject","_wxTIFFHandler",SwigwxTIFFHandlerTowxObject}, - { "_class_wxObject","_class_wxPCXHandler",SwigwxPCXHandlerTowxObject}, - { "_class_wxObject","_wxPCXHandler",SwigwxPCXHandlerTowxObject}, - { "_class_wxObject","_class_wxPNMHandler",SwigwxPNMHandlerTowxObject}, - { "_class_wxObject","_wxPNMHandler",SwigwxPNMHandlerTowxObject}, - { "_class_wxObject","_class_wxGIFHandler",SwigwxGIFHandlerTowxObject}, - { "_class_wxObject","_wxGIFHandler",SwigwxGIFHandlerTowxObject}, - { "_class_wxObject","_class_wxBMPHandler",SwigwxBMPHandlerTowxObject}, - { "_class_wxObject","_wxBMPHandler",SwigwxBMPHandlerTowxObject}, - { "_class_wxObject","_class_wxJPEGHandler",SwigwxJPEGHandlerTowxObject}, - { "_class_wxObject","_wxJPEGHandler",SwigwxJPEGHandlerTowxObject}, - { "_class_wxObject","_class_wxPNGHandler",SwigwxPNGHandlerTowxObject}, - { "_class_wxObject","_wxPNGHandler",SwigwxPNGHandlerTowxObject}, - { "_class_wxObject","_class_wxImageHandler",SwigwxImageHandlerTowxObject}, - { "_class_wxObject","_wxImageHandler",SwigwxImageHandlerTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2520,40 +2478,17 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxImage",SwigwxImageTowxObject}, { "_wxObject","_wxImage",SwigwxImageTowxObject}, - { "_wxObject","_class_wxTIFFHandler",SwigwxTIFFHandlerTowxObject}, { "_wxObject","_wxTIFFHandler",SwigwxTIFFHandlerTowxObject}, - { "_wxObject","_class_wxPCXHandler",SwigwxPCXHandlerTowxObject}, { "_wxObject","_wxPCXHandler",SwigwxPCXHandlerTowxObject}, - { "_wxObject","_class_wxPNMHandler",SwigwxPNMHandlerTowxObject}, { "_wxObject","_wxPNMHandler",SwigwxPNMHandlerTowxObject}, - { "_wxObject","_class_wxGIFHandler",SwigwxGIFHandlerTowxObject}, { "_wxObject","_wxGIFHandler",SwigwxGIFHandlerTowxObject}, - { "_wxObject","_class_wxBMPHandler",SwigwxBMPHandlerTowxObject}, { "_wxObject","_wxBMPHandler",SwigwxBMPHandlerTowxObject}, - { "_wxObject","_class_wxJPEGHandler",SwigwxJPEGHandlerTowxObject}, { "_wxObject","_wxJPEGHandler",SwigwxJPEGHandlerTowxObject}, - { "_wxObject","_class_wxPNGHandler",SwigwxPNGHandlerTowxObject}, { "_wxObject","_wxPNGHandler",SwigwxPNGHandlerTowxObject}, - { "_wxObject","_class_wxImageHandler",SwigwxImageHandlerTowxObject}, { "_wxObject","_wxImageHandler",SwigwxImageHandlerTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, - { "_class_wxImageHandler","_class_wxTIFFHandler",SwigwxTIFFHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxTIFFHandler",SwigwxTIFFHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxPCXHandler",SwigwxPCXHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxPCXHandler",SwigwxPCXHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxPNMHandler",SwigwxPNMHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxPNMHandler",SwigwxPNMHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxGIFHandler",SwigwxGIFHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxGIFHandler",SwigwxGIFHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxBMPHandler",SwigwxBMPHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxBMPHandler",SwigwxBMPHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxJPEGHandler",SwigwxJPEGHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxJPEGHandler",SwigwxJPEGHandlerTowxImageHandler}, - { "_class_wxImageHandler","_class_wxPNGHandler",SwigwxPNGHandlerTowxImageHandler}, - { "_class_wxImageHandler","_wxPNGHandler",SwigwxPNGHandlerTowxImageHandler}, { "_unsigned_char","_byte",0}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, diff --git a/wxPython/src/gtk/mdi.cpp b/wxPython/src/gtk/mdi.cpp index d6d8f56ebb..de1f803157 100644 --- a/wxPython/src/gtk/mdi.cpp +++ b/wxPython/src/gtk/mdi.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -55,47 +57,28 @@ extern PyObject *SWIG_newvarlink(void); #include "helpers.h" -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -1040,21 +1023,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMDIClientWindow",SwigwxMDIClientWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMDIChildFrame",SwigwxMDIChildFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMDIParentFrame",SwigwxMDIParentFrameTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxObject}, - { "_class_wxObject","_wxMDIClientWindow",SwigwxMDIClientWindowTowxObject}, - { "_class_wxObject","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxObject}, - { "_class_wxObject","_wxMDIChildFrame",SwigwxMDIChildFrameTowxObject}, - { "_class_wxObject","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxObject}, - { "_class_wxObject","_wxMDIParentFrame",SwigwxMDIParentFrameTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -1062,9 +1033,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTopLevelWindow","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxMDIChildFrame",SwigwxMDIChildFrameTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxMDIParentFrame",SwigwxMDIParentFrameTowxTopLevelWindow}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, @@ -1088,26 +1057,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTopLevelWindow","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxMDIChildFrame",SwigwxMDIChildFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxMDIParentFrame",SwigwxMDIParentFrameTowxTopLevelWindow}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxWindow}, - { "_class_wxWindow","_wxMDIClientWindow",SwigwxMDIClientWindowTowxWindow}, - { "_class_wxWindow","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxWindow}, - { "_class_wxWindow","_wxMDIChildFrame",SwigwxMDIChildFrameTowxWindow}, - { "_class_wxWindow","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxWindow}, - { "_class_wxWindow","_wxMDIParentFrame",SwigwxMDIParentFrameTowxWindow}, - { "_wxObject","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxObject}, { "_wxObject","_wxMDIClientWindow",SwigwxMDIClientWindowTowxObject}, - { "_wxObject","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxObject}, { "_wxObject","_wxMDIChildFrame",SwigwxMDIChildFrameTowxObject}, - { "_wxObject","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxObject}, { "_wxObject","_wxMDIParentFrame",SwigwxMDIParentFrameTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -1122,9 +1078,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFrame","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxFrame}, { "_wxFrame","_wxMDIChildFrame",SwigwxMDIChildFrameTowxFrame}, - { "_wxFrame","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxFrame}, { "_wxFrame","_wxMDIParentFrame",SwigwxMDIParentFrameTowxFrame}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -1160,22 +1114,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxEvtHandler}, { "_wxEvtHandler","_wxMDIClientWindow",SwigwxMDIClientWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxEvtHandler}, { "_wxEvtHandler","_wxMDIChildFrame",SwigwxMDIChildFrameTowxEvtHandler}, - { "_wxEvtHandler","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxEvtHandler}, { "_wxEvtHandler","_wxMDIParentFrame",SwigwxMDIParentFrameTowxEvtHandler}, - { "_wxWindow","_class_wxMDIClientWindow",SwigwxMDIClientWindowTowxWindow}, { "_wxWindow","_wxMDIClientWindow",SwigwxMDIClientWindowTowxWindow}, - { "_wxWindow","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxWindow}, { "_wxWindow","_wxMDIChildFrame",SwigwxMDIChildFrameTowxWindow}, - { "_wxWindow","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxWindow}, { "_wxWindow","_wxMDIParentFrame",SwigwxMDIParentFrameTowxWindow}, - { "_class_wxFrame","_class_wxMDIChildFrame",SwigwxMDIChildFrameTowxFrame}, - { "_class_wxFrame","_wxMDIChildFrame",SwigwxMDIChildFrameTowxFrame}, - { "_class_wxFrame","_class_wxMDIParentFrame",SwigwxMDIParentFrameTowxFrame}, - { "_class_wxFrame","_wxMDIParentFrame",SwigwxMDIParentFrameTowxFrame}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/misc.cpp b/wxPython/src/gtk/misc.cpp index abefb81588..0192a4439a 100644 --- a/wxPython/src/gtk/misc.cpp +++ b/wxPython/src/gtk/misc.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -58,47 +60,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -4216,14 +4199,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxBusyInfo",SwigwxBusyInfoTowxObject}, - { "_class_wxObject","_wxBusyInfo",SwigwxBusyInfoTowxObject}, - { "_class_wxObject","_class_wxAcceleratorTable",SwigwxAcceleratorTableTowxObject}, - { "_class_wxObject","_wxAcceleratorTable",SwigwxAcceleratorTableTowxObject}, - { "_class_wxObject","_class_wxLayoutConstraints",SwigwxLayoutConstraintsTowxObject}, - { "_class_wxObject","_wxLayoutConstraints",SwigwxLayoutConstraintsTowxObject}, - { "_class_wxObject","_class_wxIndividualLayoutConstraint",SwigwxIndividualLayoutConstraintTowxObject}, - { "_class_wxObject","_wxIndividualLayoutConstraint",SwigwxIndividualLayoutConstraintTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -4256,13 +4231,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxBusyInfo",SwigwxBusyInfoTowxObject}, { "_wxObject","_wxBusyInfo",SwigwxBusyInfoTowxObject}, - { "_wxObject","_class_wxAcceleratorTable",SwigwxAcceleratorTableTowxObject}, { "_wxObject","_wxAcceleratorTable",SwigwxAcceleratorTableTowxObject}, - { "_wxObject","_class_wxLayoutConstraints",SwigwxLayoutConstraintsTowxObject}, { "_wxObject","_wxLayoutConstraints",SwigwxLayoutConstraintsTowxObject}, - { "_wxObject","_class_wxIndividualLayoutConstraint",SwigwxIndividualLayoutConstraintTowxObject}, { "_wxObject","_wxIndividualLayoutConstraint",SwigwxIndividualLayoutConstraintTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, diff --git a/wxPython/src/gtk/misc2.cpp b/wxPython/src/gtk/misc2.cpp index acece44966..0c602832a8 100644 --- a/wxPython/src/gtk/misc2.cpp +++ b/wxPython/src/gtk/misc2.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -69,47 +71,28 @@ extern PyObject *SWIG_newvarlink(void); #include #endif -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -7610,7 +7593,6 @@ static PyMethodDef misc2cMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxProcessEvent",SwigwxProcessEventTowxEvent}, { "_wxEvent","_wxProcessEvent",SwigwxProcessEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -7622,37 +7604,15 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPyProcess",SwigwxPyProcessTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyProcess",SwigwxPyProcessTowxEvtHandler}, - { "_wxLog","_class_wxPyLog",SwigwxPyLogTowxLog}, { "_wxLog","_wxPyLog",SwigwxPyLogTowxLog}, - { "_wxLog","_class_wxLogChain",SwigwxLogChainTowxLog}, { "_wxLog","_wxLogChain",SwigwxLogChainTowxLog}, - { "_wxLog","_class_wxLogWindow",SwigwxLogWindowTowxLog}, { "_wxLog","_wxLogWindow",SwigwxLogWindowTowxLog}, - { "_wxLog","_class_wxLogGui",SwigwxLogGuiTowxLog}, { "_wxLog","_wxLogGui",SwigwxLogGuiTowxLog}, - { "_wxLog","_class_wxLogTextCtrl",SwigwxLogTextCtrlTowxLog}, { "_wxLog","_wxLogTextCtrl",SwigwxLogTextCtrlTowxLog}, - { "_wxLog","_class_wxLogStderr",SwigwxLogStderrTowxLog}, { "_wxLog","_wxLogStderr",SwigwxLogStderrTowxLog}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxWave",SwigwxWaveTowxObject}, - { "_class_wxObject","_wxWave",SwigwxWaveTowxObject}, - { "_class_wxObject","_class_wxJoystick",SwigwxJoystickTowxObject}, - { "_class_wxObject","_wxJoystick",SwigwxJoystickTowxObject}, - { "_class_wxObject","_class_wxPyProcess",SwigwxPyProcessTowxObject}, - { "_class_wxObject","_wxPyProcess",SwigwxPyProcessTowxObject}, - { "_class_wxObject","_class_wxProcessEvent",SwigwxProcessEventTowxObject}, - { "_class_wxObject","_wxProcessEvent",SwigwxProcessEventTowxObject}, - { "_class_wxObject","_class_wxPyTimer",SwigwxPyTimerTowxObject}, - { "_class_wxObject","_wxPyTimer",SwigwxPyTimerTowxObject}, - { "_class_wxObject","_class_wxGenericDragImage",SwigwxGenericDragImageTowxObject}, - { "_class_wxObject","_wxGenericDragImage",SwigwxGenericDragImageTowxObject}, - { "_class_wxObject","_class_wxToolTip",SwigwxToolTipTowxObject}, - { "_class_wxObject","_wxToolTip",SwigwxToolTipTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -7668,8 +7628,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxProcessEvent",SwigwxProcessEventTowxEvent}, - { "_class_wxEvent","_wxProcessEvent",SwigwxProcessEventTowxEvent}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, @@ -7687,38 +7645,18 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, - { "_wxTipProvider","_class_wxPyTipProvider",SwigwxPyTipProviderTowxTipProvider}, { "_wxTipProvider","_wxPyTipProvider",SwigwxPyTipProviderTowxTipProvider}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxWave",SwigwxWaveTowxObject}, { "_wxObject","_wxWave",SwigwxWaveTowxObject}, - { "_wxObject","_class_wxJoystick",SwigwxJoystickTowxObject}, { "_wxObject","_wxJoystick",SwigwxJoystickTowxObject}, - { "_wxObject","_class_wxPyProcess",SwigwxPyProcessTowxObject}, { "_wxObject","_wxPyProcess",SwigwxPyProcessTowxObject}, - { "_wxObject","_class_wxProcessEvent",SwigwxProcessEventTowxObject}, { "_wxObject","_wxProcessEvent",SwigwxProcessEventTowxObject}, - { "_wxObject","_class_wxPyTimer",SwigwxPyTimerTowxObject}, { "_wxObject","_wxPyTimer",SwigwxPyTimerTowxObject}, - { "_wxObject","_class_wxGenericDragImage",SwigwxGenericDragImageTowxObject}, { "_wxObject","_wxGenericDragImage",SwigwxGenericDragImageTowxObject}, - { "_wxObject","_class_wxToolTip",SwigwxToolTipTowxObject}, { "_wxObject","_wxToolTip",SwigwxToolTipTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, - { "_class_wxLog","_class_wxPyLog",SwigwxPyLogTowxLog}, - { "_class_wxLog","_wxPyLog",SwigwxPyLogTowxLog}, - { "_class_wxLog","_class_wxLogChain",SwigwxLogChainTowxLog}, - { "_class_wxLog","_wxLogChain",SwigwxLogChainTowxLog}, - { "_class_wxLog","_class_wxLogWindow",SwigwxLogWindowTowxLog}, - { "_class_wxLog","_wxLogWindow",SwigwxLogWindowTowxLog}, - { "_class_wxLog","_class_wxLogGui",SwigwxLogGuiTowxLog}, - { "_class_wxLog","_wxLogGui",SwigwxLogGuiTowxLog}, - { "_class_wxLog","_class_wxLogTextCtrl",SwigwxLogTextCtrlTowxLog}, - { "_class_wxLog","_wxLogTextCtrl",SwigwxLogTextCtrlTowxLog}, - { "_class_wxLog","_class_wxLogStderr",SwigwxLogStderrTowxLog}, - { "_class_wxLog","_wxLogStderr",SwigwxLogStderrTowxLog}, { "_unsigned_char","_byte",0}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -7764,9 +7702,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxTipProvider","_class_wxPyTipProvider",SwigwxPyTipProviderTowxTipProvider}, - { "_class_wxTipProvider","_wxPyTipProvider",SwigwxPyTipProviderTowxTipProvider}, - { "_wxEvtHandler","_class_wxPyProcess",SwigwxPyProcessTowxEvtHandler}, { "_wxEvtHandler","_wxPyProcess",SwigwxPyProcessTowxEvtHandler}, {0,0,0}}; diff --git a/wxPython/src/gtk/printfw.cpp b/wxPython/src/gtk/printfw.cpp index dbd3a3d37a..b328b4a73d 100644 --- a/wxPython/src/gtk/printfw.cpp +++ b/wxPython/src/gtk/printfw.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -59,47 +61,28 @@ extern PyObject *SWIG_newvarlink(void); #include "printfw.h" -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -5323,33 +5306,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPreviewFrame",SwigwxPreviewFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPreviewFrame",SwigwxPreviewFrameTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPrintDialog",SwigwxPrintDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPrintDialog",SwigwxPrintDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPageSetupDialog",SwigwxPageSetupDialogTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxPreviewFrame",SwigwxPreviewFrameTowxObject}, - { "_class_wxObject","_wxPreviewFrame",SwigwxPreviewFrameTowxObject}, - { "_class_wxObject","_class_wxPrintPreview",SwigwxPrintPreviewTowxObject}, - { "_class_wxObject","_wxPrintPreview",SwigwxPrintPreviewTowxObject}, - { "_class_wxObject","_class_wxPrinter",SwigwxPrinterTowxObject}, - { "_class_wxObject","_wxPrinter",SwigwxPrinterTowxObject}, - { "_class_wxObject","_class_wxPyPrintout",SwigwxPyPrintoutTowxObject}, - { "_class_wxObject","_wxPyPrintout",SwigwxPyPrintoutTowxObject}, - { "_class_wxObject","_class_wxPrintDialog",SwigwxPrintDialogTowxObject}, - { "_class_wxObject","_wxPrintDialog",SwigwxPrintDialogTowxObject}, - { "_class_wxObject","_class_wxPrintDialogData",SwigwxPrintDialogDataTowxObject}, - { "_class_wxObject","_wxPrintDialogData",SwigwxPrintDialogDataTowxObject}, - { "_class_wxObject","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxObject}, - { "_class_wxObject","_wxPageSetupDialog",SwigwxPageSetupDialogTowxObject}, - { "_class_wxObject","_class_wxPageSetupDialogData",SwigwxPageSetupDialogDataTowxObject}, - { "_class_wxObject","_wxPageSetupDialogData",SwigwxPageSetupDialogDataTowxObject}, - { "_class_wxObject","_class_wxPrintData",SwigwxPrintDataTowxObject}, - { "_class_wxObject","_wxPrintData",SwigwxPrintDataTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -5357,16 +5316,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxTopLevelWindow","_class_wxPreviewFrame",SwigwxPreviewFrameTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxPreviewFrame",SwigwxPreviewFrameTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxPrintDialog",SwigwxPrintDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxPrintDialog",SwigwxPrintDialogTowxTopLevelWindow}, - { "_wxTopLevelWindow","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxTopLevelWindow}, { "_wxTopLevelWindow","_wxPageSetupDialog",SwigwxPageSetupDialogTowxTopLevelWindow}, - { "_class_wxDialog","_class_wxPrintDialog",SwigwxPrintDialogTowxDialog}, - { "_class_wxDialog","_wxPrintDialog",SwigwxPrintDialogTowxDialog}, - { "_class_wxDialog","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxDialog}, - { "_class_wxDialog","_wxPageSetupDialog",SwigwxPageSetupDialogTowxDialog}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, { "_uint","_time_t",0}, @@ -5389,40 +5341,19 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_signed_int","_EBool",0}, { "_signed_int","_wxWindowID",0}, { "_signed_int","_int",0}, - { "_class_wxTopLevelWindow","_class_wxPreviewFrame",SwigwxPreviewFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxPreviewFrame",SwigwxPreviewFrameTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxPrintDialog",SwigwxPrintDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxPrintDialog",SwigwxPrintDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxTopLevelWindow}, - { "_class_wxTopLevelWindow","_wxPageSetupDialog",SwigwxPageSetupDialogTowxTopLevelWindow}, { "_WXTYPE","_short",0}, { "_WXTYPE","_signed_short",0}, { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxPreviewFrame",SwigwxPreviewFrameTowxWindow}, - { "_class_wxWindow","_wxPreviewFrame",SwigwxPreviewFrameTowxWindow}, - { "_class_wxWindow","_class_wxPrintDialog",SwigwxPrintDialogTowxWindow}, - { "_class_wxWindow","_wxPrintDialog",SwigwxPrintDialogTowxWindow}, - { "_class_wxWindow","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxWindow}, - { "_class_wxWindow","_wxPageSetupDialog",SwigwxPageSetupDialogTowxWindow}, - { "_wxObject","_class_wxPreviewFrame",SwigwxPreviewFrameTowxObject}, { "_wxObject","_wxPreviewFrame",SwigwxPreviewFrameTowxObject}, - { "_wxObject","_class_wxPrintPreview",SwigwxPrintPreviewTowxObject}, { "_wxObject","_wxPrintPreview",SwigwxPrintPreviewTowxObject}, - { "_wxObject","_class_wxPrinter",SwigwxPrinterTowxObject}, { "_wxObject","_wxPrinter",SwigwxPrinterTowxObject}, - { "_wxObject","_class_wxPyPrintout",SwigwxPyPrintoutTowxObject}, { "_wxObject","_wxPyPrintout",SwigwxPyPrintoutTowxObject}, - { "_wxObject","_class_wxPrintDialog",SwigwxPrintDialogTowxObject}, { "_wxObject","_wxPrintDialog",SwigwxPrintDialogTowxObject}, - { "_wxObject","_class_wxPrintDialogData",SwigwxPrintDialogDataTowxObject}, { "_wxObject","_wxPrintDialogData",SwigwxPrintDialogDataTowxObject}, - { "_wxObject","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxObject}, { "_wxObject","_wxPageSetupDialog",SwigwxPageSetupDialogTowxObject}, - { "_wxObject","_class_wxPageSetupDialogData",SwigwxPageSetupDialogDataTowxObject}, { "_wxObject","_wxPageSetupDialogData",SwigwxPageSetupDialogDataTowxObject}, - { "_wxObject","_class_wxPrintData",SwigwxPrintDataTowxObject}, { "_wxObject","_wxPrintData",SwigwxPrintDataTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -5434,14 +5365,11 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_int","_uint",0}, { "_unsigned_int","_wxWindowID",0}, { "_unsigned_int","_int",0}, - { "_wxDialog","_class_wxPrintDialog",SwigwxPrintDialogTowxDialog}, { "_wxDialog","_wxPrintDialog",SwigwxPrintDialogTowxDialog}, - { "_wxDialog","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxDialog}, { "_wxDialog","_wxPageSetupDialog",SwigwxPageSetupDialogTowxDialog}, { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_wxFrame","_class_wxPreviewFrame",SwigwxPreviewFrameTowxFrame}, { "_wxFrame","_wxPreviewFrame",SwigwxPreviewFrameTowxFrame}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, @@ -5477,20 +5405,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxPreviewFrame",SwigwxPreviewFrameTowxEvtHandler}, { "_wxEvtHandler","_wxPreviewFrame",SwigwxPreviewFrameTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPrintDialog",SwigwxPrintDialogTowxEvtHandler}, { "_wxEvtHandler","_wxPrintDialog",SwigwxPrintDialogTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxEvtHandler}, { "_wxEvtHandler","_wxPageSetupDialog",SwigwxPageSetupDialogTowxEvtHandler}, - { "_wxWindow","_class_wxPreviewFrame",SwigwxPreviewFrameTowxWindow}, { "_wxWindow","_wxPreviewFrame",SwigwxPreviewFrameTowxWindow}, - { "_wxWindow","_class_wxPrintDialog",SwigwxPrintDialogTowxWindow}, { "_wxWindow","_wxPrintDialog",SwigwxPrintDialogTowxWindow}, - { "_wxWindow","_class_wxPageSetupDialog",SwigwxPageSetupDialogTowxWindow}, { "_wxWindow","_wxPageSetupDialog",SwigwxPageSetupDialogTowxWindow}, - { "_class_wxFrame","_class_wxPreviewFrame",SwigwxPreviewFrameTowxFrame}, - { "_class_wxFrame","_wxPreviewFrame",SwigwxPreviewFrameTowxFrame}, {0,0,0}}; static PyObject *SWIG_globals; diff --git a/wxPython/src/gtk/sizers.cpp b/wxPython/src/gtk/sizers.cpp index 959e7a355e..a28dec6250 100644 --- a/wxPython/src/gtk/sizers.cpp +++ b/wxPython/src/gtk/sizers.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2974,36 +2957,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxSizer","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxSizer}, - { "_class_wxSizer","_wxFlexGridSizer",SwigwxFlexGridSizerTowxSizer}, - { "_class_wxSizer","_class_wxGridSizer",SwigwxGridSizerTowxSizer}, - { "_class_wxSizer","_wxGridSizer",SwigwxGridSizerTowxSizer}, - { "_class_wxSizer","_class_wxNotebookSizer",SwigwxNotebookSizerTowxSizer}, - { "_class_wxSizer","_wxNotebookSizer",SwigwxNotebookSizerTowxSizer}, - { "_class_wxSizer","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxSizer}, - { "_class_wxSizer","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxSizer}, - { "_class_wxSizer","_class_wxBoxSizer",SwigwxBoxSizerTowxSizer}, - { "_class_wxSizer","_wxBoxSizer",SwigwxBoxSizerTowxSizer}, - { "_class_wxSizer","_class_wxPySizer",SwigwxPySizerTowxSizer}, - { "_class_wxSizer","_wxPySizer",SwigwxPySizerTowxSizer}, - { "_wxGridSizer","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxGridSizer}, { "_wxGridSizer","_wxFlexGridSizer",SwigwxFlexGridSizerTowxGridSizer}, - { "_class_wxObject","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxObject}, - { "_class_wxObject","_wxFlexGridSizer",SwigwxFlexGridSizerTowxObject}, - { "_class_wxObject","_class_wxGridSizer",SwigwxGridSizerTowxObject}, - { "_class_wxObject","_wxGridSizer",SwigwxGridSizerTowxObject}, - { "_class_wxObject","_class_wxNotebookSizer",SwigwxNotebookSizerTowxObject}, - { "_class_wxObject","_wxNotebookSizer",SwigwxNotebookSizerTowxObject}, - { "_class_wxObject","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxObject}, - { "_class_wxObject","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxObject}, - { "_class_wxObject","_class_wxBoxSizer",SwigwxBoxSizerTowxObject}, - { "_class_wxObject","_wxBoxSizer",SwigwxBoxSizerTowxObject}, - { "_class_wxObject","_class_wxPySizer",SwigwxPySizerTowxObject}, - { "_class_wxObject","_wxPySizer",SwigwxPySizerTowxObject}, - { "_class_wxObject","_class_wxSizer",SwigwxSizerTowxObject}, - { "_class_wxObject","_wxSizer",SwigwxSizerTowxObject}, - { "_class_wxObject","_class_wxSizerItem",SwigwxSizerItemTowxObject}, - { "_class_wxObject","_wxSizerItem",SwigwxSizerItemTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -3019,7 +2973,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_wxBoxSizer","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxBoxSizer}, { "_wxBoxSizer","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxBoxSizer}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, @@ -3040,24 +2993,14 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxObject}, { "_wxObject","_wxFlexGridSizer",SwigwxFlexGridSizerTowxObject}, - { "_wxObject","_class_wxGridSizer",SwigwxGridSizerTowxObject}, { "_wxObject","_wxGridSizer",SwigwxGridSizerTowxObject}, - { "_wxObject","_class_wxNotebookSizer",SwigwxNotebookSizerTowxObject}, { "_wxObject","_wxNotebookSizer",SwigwxNotebookSizerTowxObject}, - { "_wxObject","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxObject}, { "_wxObject","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxObject}, - { "_wxObject","_class_wxBoxSizer",SwigwxBoxSizerTowxObject}, { "_wxObject","_wxBoxSizer",SwigwxBoxSizerTowxObject}, - { "_wxObject","_class_wxPySizer",SwigwxPySizerTowxObject}, { "_wxObject","_wxPySizer",SwigwxPySizerTowxObject}, - { "_wxObject","_class_wxSizer",SwigwxSizerTowxObject}, { "_wxObject","_wxSizer",SwigwxSizerTowxObject}, - { "_wxObject","_class_wxSizerItem",SwigwxSizerItemTowxObject}, { "_wxObject","_wxSizerItem",SwigwxSizerItemTowxObject}, - { "_class_wxBoxSizer","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxBoxSizer}, - { "_class_wxBoxSizer","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxBoxSizer}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, @@ -3071,8 +3014,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_short","_WXTYPE",0}, { "_short","_unsigned_short",0}, { "_short","_signed_short",0}, - { "_class_wxGridSizer","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxGridSizer}, - { "_class_wxGridSizer","_wxFlexGridSizer",SwigwxFlexGridSizerTowxGridSizer}, { "_wxWindowID","_wxCoord",0}, { "_wxWindowID","_wxPrintQuality",0}, { "_wxWindowID","_time_t",0}, @@ -3107,17 +3048,11 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxSizer","_class_wxFlexGridSizer",SwigwxFlexGridSizerTowxSizer}, { "_wxSizer","_wxFlexGridSizer",SwigwxFlexGridSizerTowxSizer}, - { "_wxSizer","_class_wxGridSizer",SwigwxGridSizerTowxSizer}, { "_wxSizer","_wxGridSizer",SwigwxGridSizerTowxSizer}, - { "_wxSizer","_class_wxNotebookSizer",SwigwxNotebookSizerTowxSizer}, { "_wxSizer","_wxNotebookSizer",SwigwxNotebookSizerTowxSizer}, - { "_wxSizer","_class_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxSizer}, { "_wxSizer","_wxStaticBoxSizer",SwigwxStaticBoxSizerTowxSizer}, - { "_wxSizer","_class_wxBoxSizer",SwigwxBoxSizerTowxSizer}, { "_wxSizer","_wxBoxSizer",SwigwxBoxSizerTowxSizer}, - { "_wxSizer","_class_wxPySizer",SwigwxPySizerTowxSizer}, { "_wxSizer","_wxPySizer",SwigwxPySizerTowxSizer}, {0,0,0}}; diff --git a/wxPython/src/gtk/stattool.cpp b/wxPython/src/gtk/stattool.cpp index 2ccb8f17b6..407ec36437 100644 --- a/wxPython/src/gtk/stattool.cpp +++ b/wxPython/src/gtk/stattool.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -137,26 +120,20 @@ static void *SwigwxStatusBarTowxObject(void *ptr) { return (void *) dest; } -#define new_wxStatusBar(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5) (new wxStatusBar(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5)) +#define new_wxStatusBar(_swigarg0,_swigarg1,_swigarg2,_swigarg3) (new wxStatusBar(_swigarg0,_swigarg1,_swigarg2,_swigarg3)) static PyObject *_wrap_new_wxStatusBar(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; wxStatusBar * _result; wxWindow * _arg0; - wxWindowID _arg1; - wxPoint * _arg2 = (wxPoint *) &wxDefaultPosition; - wxSize * _arg3 = (wxSize *) &wxDefaultSize; - long _arg4 = (long ) wxST_SIZEGRIP; - char * _arg5 = (char *) "statusBar"; + wxWindowID _arg1 = (wxWindowID ) -1; + long _arg2 = (long ) wxST_SIZEGRIP; + char * _arg3 = (char *) "statusBar"; PyObject * _argo0 = 0; - wxPoint temp; - PyObject * _obj2 = 0; - wxSize temp0; - PyObject * _obj3 = 0; - char *_kwnames[] = { "parent","id","pos","size","style","name", NULL }; + char *_kwnames[] = { "parent","id","style","name", NULL }; char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi|OOls:new_wxStatusBar",_kwnames,&_argo0,&_arg1,&_obj2,&_obj3,&_arg4,&_arg5)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|ils:new_wxStatusBar",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -165,21 +142,9 @@ static PyObject *_wrap_new_wxStatusBar(PyObject *self, PyObject *args, PyObject return NULL; } } - if (_obj2) -{ - _arg2 = &temp; - if (! wxPoint_helper(_obj2, &_arg2)) - return NULL; -} - if (_obj3) -{ - _arg3 = &temp0; - if (! wxSize_helper(_obj3, &_arg3)) - return NULL; -} { wxPy_BEGIN_ALLOW_THREADS; - _result = (wxStatusBar *)new_wxStatusBar(_arg0,_arg1,*_arg2,*_arg3,_arg4,_arg5); + _result = (wxStatusBar *)new_wxStatusBar(_arg0,_arg1,_arg2,_arg3); wxPy_END_ALLOW_THREADS; if (PyErr_Occurred()) return NULL; @@ -3571,31 +3536,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxEvtHandler}, - { "_class_wxEvtHandler","_wxToolBarSimple",SwigwxToolBarSimpleTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxToolBar",SwigwxToolBarTowxEvtHandler}, - { "_class_wxEvtHandler","_wxToolBar",SwigwxToolBarTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxToolBarBase",SwigwxToolBarBaseTowxEvtHandler}, - { "_class_wxEvtHandler","_wxToolBarBase",SwigwxToolBarBaseTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxStatusBar",SwigwxStatusBarTowxEvtHandler}, - { "_class_wxEvtHandler","_wxStatusBar",SwigwxStatusBarTowxEvtHandler}, - { "_class_wxToolBarBase","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxToolBarBase}, - { "_class_wxToolBarBase","_wxToolBarSimple",SwigwxToolBarSimpleTowxToolBarBase}, - { "_class_wxToolBarBase","_class_wxToolBar",SwigwxToolBarTowxToolBarBase}, - { "_class_wxToolBarBase","_wxToolBar",SwigwxToolBarTowxToolBarBase}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxObject}, - { "_class_wxObject","_wxToolBarSimple",SwigwxToolBarSimpleTowxObject}, - { "_class_wxObject","_class_wxToolBar",SwigwxToolBarTowxObject}, - { "_class_wxObject","_wxToolBar",SwigwxToolBarTowxObject}, - { "_class_wxObject","_class_wxToolBarBase",SwigwxToolBarBaseTowxObject}, - { "_class_wxObject","_wxToolBarBase",SwigwxToolBarBaseTowxObject}, - { "_class_wxObject","_class_wxToolBarToolBase",SwigwxToolBarToolBaseTowxObject}, - { "_class_wxObject","_wxToolBarToolBase",SwigwxToolBarToolBaseTowxObject}, - { "_class_wxObject","_class_wxStatusBar",SwigwxStatusBarTowxObject}, - { "_class_wxObject","_wxStatusBar",SwigwxStatusBarTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -3630,32 +3573,16 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxWindow}, - { "_class_wxWindow","_wxToolBarSimple",SwigwxToolBarSimpleTowxWindow}, - { "_class_wxWindow","_class_wxToolBar",SwigwxToolBarTowxWindow}, - { "_class_wxWindow","_wxToolBar",SwigwxToolBarTowxWindow}, - { "_class_wxWindow","_class_wxToolBarBase",SwigwxToolBarBaseTowxWindow}, - { "_class_wxWindow","_wxToolBarBase",SwigwxToolBarBaseTowxWindow}, - { "_class_wxWindow","_class_wxStatusBar",SwigwxStatusBarTowxWindow}, - { "_class_wxWindow","_wxStatusBar",SwigwxStatusBarTowxWindow}, - { "_wxObject","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxObject}, { "_wxObject","_wxToolBarSimple",SwigwxToolBarSimpleTowxObject}, - { "_wxObject","_class_wxToolBar",SwigwxToolBarTowxObject}, { "_wxObject","_wxToolBar",SwigwxToolBarTowxObject}, - { "_wxObject","_class_wxToolBarBase",SwigwxToolBarBaseTowxObject}, { "_wxObject","_wxToolBarBase",SwigwxToolBarBaseTowxObject}, - { "_wxObject","_class_wxToolBarToolBase",SwigwxToolBarToolBaseTowxObject}, { "_wxObject","_wxToolBarToolBase",SwigwxToolBarToolBaseTowxObject}, - { "_wxObject","_class_wxStatusBar",SwigwxStatusBarTowxObject}, { "_wxObject","_wxStatusBar",SwigwxStatusBarTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxControl}, { "_wxControl","_wxToolBarSimple",SwigwxToolBarSimpleTowxControl}, - { "_wxControl","_class_wxToolBar",SwigwxToolBarTowxControl}, { "_wxControl","_wxToolBar",SwigwxToolBarTowxControl}, - { "_wxControl","_class_wxToolBarBase",SwigwxToolBarBaseTowxControl}, { "_wxControl","_wxToolBarBase",SwigwxToolBarBaseTowxControl}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -3692,16 +3619,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_wxToolBarBase","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxToolBarBase}, { "_wxToolBarBase","_wxToolBarSimple",SwigwxToolBarSimpleTowxToolBarBase}, - { "_wxToolBarBase","_class_wxToolBar",SwigwxToolBarTowxToolBarBase}, { "_wxToolBarBase","_wxToolBar",SwigwxToolBarTowxToolBarBase}, - { "_class_wxControl","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxControl}, - { "_class_wxControl","_wxToolBarSimple",SwigwxToolBarSimpleTowxControl}, - { "_class_wxControl","_class_wxToolBar",SwigwxToolBarTowxControl}, - { "_class_wxControl","_wxToolBar",SwigwxToolBarTowxControl}, - { "_class_wxControl","_class_wxToolBarBase",SwigwxToolBarBaseTowxControl}, - { "_class_wxControl","_wxToolBarBase",SwigwxToolBarBaseTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -3711,21 +3630,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxEvtHandler}, { "_wxEvtHandler","_wxToolBarSimple",SwigwxToolBarSimpleTowxEvtHandler}, - { "_wxEvtHandler","_class_wxToolBar",SwigwxToolBarTowxEvtHandler}, { "_wxEvtHandler","_wxToolBar",SwigwxToolBarTowxEvtHandler}, - { "_wxEvtHandler","_class_wxToolBarBase",SwigwxToolBarBaseTowxEvtHandler}, { "_wxEvtHandler","_wxToolBarBase",SwigwxToolBarBaseTowxEvtHandler}, - { "_wxEvtHandler","_class_wxStatusBar",SwigwxStatusBarTowxEvtHandler}, { "_wxEvtHandler","_wxStatusBar",SwigwxStatusBarTowxEvtHandler}, - { "_wxWindow","_class_wxToolBarSimple",SwigwxToolBarSimpleTowxWindow}, { "_wxWindow","_wxToolBarSimple",SwigwxToolBarSimpleTowxWindow}, - { "_wxWindow","_class_wxToolBar",SwigwxToolBarTowxWindow}, { "_wxWindow","_wxToolBar",SwigwxToolBarTowxWindow}, - { "_wxWindow","_class_wxToolBarBase",SwigwxToolBarBaseTowxWindow}, { "_wxWindow","_wxToolBarBase",SwigwxToolBarBaseTowxWindow}, - { "_wxWindow","_class_wxStatusBar",SwigwxStatusBarTowxWindow}, { "_wxWindow","_wxStatusBar",SwigwxStatusBarTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/streams.cpp b/wxPython/src/gtk/streams.cpp index 1d20a2ebe5..c0a3342bd5 100644 --- a/wxPython/src/gtk/streams.cpp +++ b/wxPython/src/gtk/streams.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; diff --git a/wxPython/src/gtk/utils.cpp b/wxPython/src/gtk/utils.cpp index 1777df58c6..f1177364c5 100644 --- a/wxPython/src/gtk/utils.cpp +++ b/wxPython/src/gtk/utils.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -58,47 +60,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -7977,9 +7960,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_int","_uint",0}, { "_unsigned_int","_wxWindowID",0}, { "_unsigned_int","_int",0}, - { "_wxConfigBase","_class_wxFileConfig",SwigwxFileConfigTowxConfigBase}, { "_wxConfigBase","_wxFileConfig",SwigwxFileConfigTowxConfigBase}, - { "_wxConfigBase","_class_wxConfig",SwigwxConfigTowxConfigBase}, { "_wxConfigBase","_wxConfig",SwigwxConfigTowxConfigBase}, { "_short","_wxDateTime_t",0}, { "_short","_WXTYPE",0}, @@ -8013,10 +7994,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_class_wxConfigBase","_class_wxFileConfig",SwigwxFileConfigTowxConfigBase}, - { "_class_wxConfigBase","_wxFileConfig",SwigwxFileConfigTowxConfigBase}, - { "_class_wxConfigBase","_class_wxConfig",SwigwxConfigTowxConfigBase}, - { "_class_wxConfigBase","_wxConfig",SwigwxConfigTowxConfigBase}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, diff --git a/wxPython/src/gtk/windows.cpp b/wxPython/src/gtk/windows.cpp index d94baee7bf..f66b8f4562 100644 --- a/wxPython/src/gtk/windows.cpp +++ b/wxPython/src/gtk/windows.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -57,47 +59,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -10244,41 +10227,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxMenuBar",SwigwxMenuBarTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMenuBar",SwigwxMenuBarTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxMenu",SwigwxMenuTowxEvtHandler}, - { "_class_wxEvtHandler","_wxMenu",SwigwxMenuTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxScrolledWindow",SwigwxScrolledWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxScrolledWindow",SwigwxScrolledWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPanel",SwigwxPanelTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPanel",SwigwxPanelTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxWindow",SwigwxWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxWindow",SwigwxWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPyValidator",SwigwxPyValidatorTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyValidator",SwigwxPyValidatorTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxValidator",SwigwxValidatorTowxEvtHandler}, - { "_class_wxEvtHandler","_wxValidator",SwigwxValidatorTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxMenuItem",SwigwxMenuItemTowxObject}, - { "_class_wxObject","_wxMenuItem",SwigwxMenuItemTowxObject}, - { "_class_wxObject","_class_wxMenuBar",SwigwxMenuBarTowxObject}, - { "_class_wxObject","_wxMenuBar",SwigwxMenuBarTowxObject}, - { "_class_wxObject","_class_wxMenu",SwigwxMenuTowxObject}, - { "_class_wxObject","_wxMenu",SwigwxMenuTowxObject}, - { "_class_wxObject","_class_wxScrolledWindow",SwigwxScrolledWindowTowxObject}, - { "_class_wxObject","_wxScrolledWindow",SwigwxScrolledWindowTowxObject}, - { "_class_wxObject","_class_wxPanel",SwigwxPanelTowxObject}, - { "_class_wxObject","_wxPanel",SwigwxPanelTowxObject}, - { "_class_wxObject","_class_wxWindow",SwigwxWindowTowxObject}, - { "_class_wxObject","_wxWindow",SwigwxWindowTowxObject}, - { "_class_wxObject","_class_wxPyValidator",SwigwxPyValidatorTowxObject}, - { "_class_wxObject","_wxPyValidator",SwigwxPyValidatorTowxObject}, - { "_class_wxObject","_class_wxValidator",SwigwxValidatorTowxObject}, - { "_class_wxObject","_wxValidator",SwigwxValidatorTowxObject}, - { "_class_wxObject","_class_wxEvtHandler",SwigwxEvtHandlerTowxObject}, - { "_class_wxObject","_wxEvtHandler",SwigwxEvtHandlerTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -10286,7 +10237,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxPanel","_class_wxScrolledWindow",SwigwxScrolledWindowTowxPanel}, { "_wxPanel","_wxScrolledWindow",SwigwxScrolledWindowTowxPanel}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, @@ -10297,8 +10247,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, { "_char","_wxChar",0}, - { "_class_wxValidator","_class_wxPyValidator",SwigwxPyValidatorTowxValidator}, - { "_class_wxValidator","_wxPyValidator",SwigwxPyValidatorTowxValidator}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, @@ -10307,8 +10255,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxPanel","_class_wxScrolledWindow",SwigwxScrolledWindowTowxPanel}, - { "_class_wxPanel","_wxScrolledWindow",SwigwxScrolledWindowTowxPanel}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, @@ -10319,29 +10265,14 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxMenuBar",SwigwxMenuBarTowxWindow}, - { "_class_wxWindow","_wxMenuBar",SwigwxMenuBarTowxWindow}, - { "_class_wxWindow","_class_wxScrolledWindow",SwigwxScrolledWindowTowxWindow}, - { "_class_wxWindow","_wxScrolledWindow",SwigwxScrolledWindowTowxWindow}, - { "_class_wxWindow","_class_wxPanel",SwigwxPanelTowxWindow}, - { "_class_wxWindow","_wxPanel",SwigwxPanelTowxWindow}, - { "_wxObject","_class_wxMenuItem",SwigwxMenuItemTowxObject}, { "_wxObject","_wxMenuItem",SwigwxMenuItemTowxObject}, - { "_wxObject","_class_wxMenuBar",SwigwxMenuBarTowxObject}, { "_wxObject","_wxMenuBar",SwigwxMenuBarTowxObject}, - { "_wxObject","_class_wxMenu",SwigwxMenuTowxObject}, { "_wxObject","_wxMenu",SwigwxMenuTowxObject}, - { "_wxObject","_class_wxScrolledWindow",SwigwxScrolledWindowTowxObject}, { "_wxObject","_wxScrolledWindow",SwigwxScrolledWindowTowxObject}, - { "_wxObject","_class_wxPanel",SwigwxPanelTowxObject}, { "_wxObject","_wxPanel",SwigwxPanelTowxObject}, - { "_wxObject","_class_wxWindow",SwigwxWindowTowxObject}, { "_wxObject","_wxWindow",SwigwxWindowTowxObject}, - { "_wxObject","_class_wxPyValidator",SwigwxPyValidatorTowxObject}, { "_wxObject","_wxPyValidator",SwigwxPyValidatorTowxObject}, - { "_wxObject","_class_wxValidator",SwigwxValidatorTowxObject}, { "_wxObject","_wxValidator",SwigwxValidatorTowxObject}, - { "_wxObject","_class_wxEvtHandler",SwigwxEvtHandlerTowxObject}, { "_wxObject","_wxEvtHandler",SwigwxEvtHandlerTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -10381,7 +10312,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_wxValidator","_class_wxPyValidator",SwigwxPyValidatorTowxValidator}, { "_wxValidator","_wxPyValidator",SwigwxPyValidatorTowxValidator}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, @@ -10392,25 +10322,15 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxMenuBar",SwigwxMenuBarTowxEvtHandler}, { "_wxEvtHandler","_wxMenuBar",SwigwxMenuBarTowxEvtHandler}, - { "_wxEvtHandler","_class_wxMenu",SwigwxMenuTowxEvtHandler}, { "_wxEvtHandler","_wxMenu",SwigwxMenuTowxEvtHandler}, - { "_wxEvtHandler","_class_wxScrolledWindow",SwigwxScrolledWindowTowxEvtHandler}, { "_wxEvtHandler","_wxScrolledWindow",SwigwxScrolledWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPanel",SwigwxPanelTowxEvtHandler}, { "_wxEvtHandler","_wxPanel",SwigwxPanelTowxEvtHandler}, - { "_wxEvtHandler","_class_wxWindow",SwigwxWindowTowxEvtHandler}, { "_wxEvtHandler","_wxWindow",SwigwxWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPyValidator",SwigwxPyValidatorTowxEvtHandler}, { "_wxEvtHandler","_wxPyValidator",SwigwxPyValidatorTowxEvtHandler}, - { "_wxEvtHandler","_class_wxValidator",SwigwxValidatorTowxEvtHandler}, { "_wxEvtHandler","_wxValidator",SwigwxValidatorTowxEvtHandler}, - { "_wxWindow","_class_wxMenuBar",SwigwxMenuBarTowxWindow}, { "_wxWindow","_wxMenuBar",SwigwxMenuBarTowxWindow}, - { "_wxWindow","_class_wxScrolledWindow",SwigwxScrolledWindowTowxWindow}, { "_wxWindow","_wxScrolledWindow",SwigwxScrolledWindowTowxWindow}, - { "_wxWindow","_class_wxPanel",SwigwxPanelTowxWindow}, { "_wxWindow","_wxPanel",SwigwxPanelTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/windows2.cpp b/wxPython/src/gtk/windows2.cpp index 9f91eecc59..b7f391859c 100644 --- a/wxPython/src/gtk/windows2.cpp +++ b/wxPython/src/gtk/windows2.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -64,47 +66,28 @@ extern PyObject *SWIG_newvarlink(void); #include #endif -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2222,9 +2205,7 @@ static PyMethodDef windows2cMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxSplitterEvent",SwigwxSplitterEventTowxEvent}, { "_wxEvent","_wxSplitterEvent",SwigwxSplitterEventTowxEvent}, - { "_wxEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxEvent}, { "_wxEvent","_wxNotebookEvent",SwigwxNotebookEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -2236,23 +2217,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxSplitterWindow",SwigwxSplitterWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSplitterWindow",SwigwxSplitterWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxNotebook",SwigwxNotebookTowxEvtHandler}, - { "_class_wxEvtHandler","_wxNotebook",SwigwxNotebookTowxEvtHandler}, - { "_wxNotifyEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxNotifyEvent}, { "_wxNotifyEvent","_wxNotebookEvent",SwigwxNotebookEventTowxNotifyEvent}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxSplitterWindow",SwigwxSplitterWindowTowxObject}, - { "_class_wxObject","_wxSplitterWindow",SwigwxSplitterWindowTowxObject}, - { "_class_wxObject","_class_wxSplitterEvent",SwigwxSplitterEventTowxObject}, - { "_class_wxObject","_wxSplitterEvent",SwigwxSplitterEventTowxObject}, - { "_class_wxObject","_class_wxNotebook",SwigwxNotebookTowxObject}, - { "_class_wxObject","_wxNotebook",SwigwxNotebookTowxObject}, - { "_class_wxObject","_class_wxNotebookEvent",SwigwxNotebookEventTowxObject}, - { "_class_wxObject","_wxNotebookEvent",SwigwxNotebookEventTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2268,17 +2236,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxSplitterEvent",SwigwxSplitterEventTowxEvent}, - { "_class_wxEvent","_wxSplitterEvent",SwigwxSplitterEventTowxEvent}, - { "_class_wxEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxEvent}, - { "_class_wxEvent","_wxNotebookEvent",SwigwxNotebookEventTowxEvent}, - { "_wxCommandEvent","_class_wxSplitterEvent",SwigwxSplitterEventTowxCommandEvent}, { "_wxCommandEvent","_wxSplitterEvent",SwigwxSplitterEventTowxCommandEvent}, - { "_wxCommandEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxCommandEvent}, { "_wxCommandEvent","_wxNotebookEvent",SwigwxNotebookEventTowxCommandEvent}, { "_char","_wxChar",0}, - { "_class_wxNotifyEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxNotifyEvent}, - { "_class_wxNotifyEvent","_wxNotebookEvent",SwigwxNotebookEventTowxNotifyEvent}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, { "_EBool","_wxCoord",0}, { "_EBool","_wxPrintQuality",0}, @@ -2297,22 +2257,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxSplitterWindow",SwigwxSplitterWindowTowxWindow}, - { "_class_wxWindow","_wxSplitterWindow",SwigwxSplitterWindowTowxWindow}, - { "_class_wxWindow","_class_wxNotebook",SwigwxNotebookTowxWindow}, - { "_class_wxWindow","_wxNotebook",SwigwxNotebookTowxWindow}, - { "_wxObject","_class_wxSplitterWindow",SwigwxSplitterWindowTowxObject}, { "_wxObject","_wxSplitterWindow",SwigwxSplitterWindowTowxObject}, - { "_wxObject","_class_wxSplitterEvent",SwigwxSplitterEventTowxObject}, { "_wxObject","_wxSplitterEvent",SwigwxSplitterEventTowxObject}, - { "_wxObject","_class_wxNotebook",SwigwxNotebookTowxObject}, { "_wxObject","_wxNotebook",SwigwxNotebookTowxObject}, - { "_wxObject","_class_wxNotebookEvent",SwigwxNotebookEventTowxObject}, { "_wxObject","_wxNotebookEvent",SwigwxNotebookEventTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, { "_unsigned_char","_byte",0}, - { "_wxControl","_class_wxNotebook",SwigwxNotebookTowxControl}, { "_wxControl","_wxNotebook",SwigwxNotebookTowxControl}, { "_unsigned_int","_wxCoord",0}, { "_unsigned_int","_wxPrintQuality",0}, @@ -2349,8 +2300,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_time_t","_wxWindowID",0}, { "_time_t","_uint",0}, { "_time_t","_size_t",0}, - { "_class_wxControl","_class_wxNotebook",SwigwxNotebookTowxControl}, - { "_class_wxControl","_wxNotebook",SwigwxNotebookTowxControl}, { "_wxCoord","_int",0}, { "_wxCoord","_signed_int",0}, { "_wxCoord","_unsigned_int",0}, @@ -2360,17 +2309,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxSplitterEvent",SwigwxSplitterEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxSplitterEvent",SwigwxSplitterEventTowxCommandEvent}, - { "_class_wxCommandEvent","_class_wxNotebookEvent",SwigwxNotebookEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxNotebookEvent",SwigwxNotebookEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxSplitterWindow",SwigwxSplitterWindowTowxEvtHandler}, { "_wxEvtHandler","_wxSplitterWindow",SwigwxSplitterWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxNotebook",SwigwxNotebookTowxEvtHandler}, { "_wxEvtHandler","_wxNotebook",SwigwxNotebookTowxEvtHandler}, - { "_wxWindow","_class_wxSplitterWindow",SwigwxSplitterWindowTowxWindow}, { "_wxWindow","_wxSplitterWindow",SwigwxSplitterWindowTowxWindow}, - { "_wxWindow","_class_wxNotebook",SwigwxNotebookTowxWindow}, { "_wxWindow","_wxNotebook",SwigwxNotebookTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/windows3.cpp b/wxPython/src/gtk/windows3.cpp index a6bde0b65e..49a8218c1e 100644 --- a/wxPython/src/gtk/windows3.cpp +++ b/wxPython/src/gtk/windows3.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -58,47 +60,28 @@ extern PyObject *SWIG_newvarlink(void); #include #include -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -2480,11 +2463,8 @@ static PyMethodDef windows3cMethods[] = { * This table is used by the pointer type-checker */ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { - { "_wxEvent","_class_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxEvent}, { "_wxEvent","_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxEvent}, - { "_wxEvent","_class_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxEvent}, { "_wxEvent","_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxEvent}, - { "_wxEvent","_class_wxSashEvent",SwigwxSashEventTowxEvent}, { "_wxEvent","_wxSashEvent",SwigwxSashEventTowxEvent}, { "_signed_long","_long",0}, { "_wxPrintQuality","_wxCoord",0}, @@ -2496,35 +2476,10 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxPopupWindow",SwigwxPopupWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPopupWindow",SwigwxPopupWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_class_wxSashWindow",SwigwxSashWindowTowxEvtHandler}, - { "_class_wxEvtHandler","_wxSashWindow",SwigwxSashWindowTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_wxSashWindow","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxSashWindow}, { "_wxSashWindow","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxSashWindow}, - { "_class_wxObject","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxObject}, - { "_class_wxObject","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxObject}, - { "_class_wxObject","_class_wxPopupWindow",SwigwxPopupWindowTowxObject}, - { "_class_wxObject","_wxPopupWindow",SwigwxPopupWindowTowxObject}, - { "_class_wxObject","_class_wxLayoutAlgorithm",SwigwxLayoutAlgorithmTowxObject}, - { "_class_wxObject","_wxLayoutAlgorithm",SwigwxLayoutAlgorithmTowxObject}, - { "_class_wxObject","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxObject}, - { "_class_wxObject","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxObject}, - { "_class_wxObject","_class_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxObject}, - { "_class_wxObject","_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxObject}, - { "_class_wxObject","_class_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxObject}, - { "_class_wxObject","_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxObject}, - { "_class_wxObject","_class_wxSashWindow",SwigwxSashWindowTowxObject}, - { "_class_wxObject","_wxSashWindow",SwigwxSashWindowTowxObject}, - { "_class_wxObject","_class_wxSashEvent",SwigwxSashEventTowxObject}, - { "_class_wxObject","_wxSashEvent",SwigwxSashEventTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -2532,10 +2487,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_size_t","_int",0}, { "_size_t","_wxWindowID",0}, { "_size_t","_uint",0}, - { "_wxPopupWindow","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxPopupWindow}, { "_wxPopupWindow","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxPopupWindow}, - { "_class_wxSashWindow","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxSashWindow}, - { "_class_wxSashWindow","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxSashWindow}, { "_uint","_wxCoord",0}, { "_uint","_wxPrintQuality",0}, { "_uint","_time_t",0}, @@ -2544,13 +2496,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_uint","_int",0}, { "_uint","_wxWindowID",0}, { "_wxChar","_char",0}, - { "_class_wxEvent","_class_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxEvent}, - { "_class_wxEvent","_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxEvent}, - { "_class_wxEvent","_class_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxEvent}, - { "_class_wxEvent","_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxEvent}, - { "_class_wxEvent","_class_wxSashEvent",SwigwxSashEventTowxEvent}, - { "_class_wxEvent","_wxSashEvent",SwigwxSashEventTowxEvent}, - { "_wxCommandEvent","_class_wxSashEvent",SwigwxSashEventTowxCommandEvent}, { "_wxCommandEvent","_wxSashEvent",SwigwxSashEventTowxCommandEvent}, { "_char","_wxChar",0}, { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, @@ -2561,8 +2506,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_EBool","_wxWindowID",0}, { "_unsigned_long","_long",0}, { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, - { "_class_wxPopupWindow","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxPopupWindow}, - { "_class_wxPopupWindow","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxPopupWindow}, { "_signed_int","_wxCoord",0}, { "_signed_int","_wxPrintQuality",0}, { "_signed_int","_EBool",0}, @@ -2573,29 +2516,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_WXTYPE","_unsigned_short",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_class_wxWindow","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxWindow}, - { "_class_wxWindow","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxWindow}, - { "_class_wxWindow","_class_wxPopupWindow",SwigwxPopupWindowTowxWindow}, - { "_class_wxWindow","_wxPopupWindow",SwigwxPopupWindowTowxWindow}, - { "_class_wxWindow","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxWindow}, - { "_class_wxWindow","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxWindow}, - { "_class_wxWindow","_class_wxSashWindow",SwigwxSashWindowTowxWindow}, - { "_class_wxWindow","_wxSashWindow",SwigwxSashWindowTowxWindow}, - { "_wxObject","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxObject}, { "_wxObject","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxObject}, - { "_wxObject","_class_wxPopupWindow",SwigwxPopupWindowTowxObject}, { "_wxObject","_wxPopupWindow",SwigwxPopupWindowTowxObject}, - { "_wxObject","_class_wxLayoutAlgorithm",SwigwxLayoutAlgorithmTowxObject}, { "_wxObject","_wxLayoutAlgorithm",SwigwxLayoutAlgorithmTowxObject}, - { "_wxObject","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxObject}, { "_wxObject","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxObject}, - { "_wxObject","_class_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxObject}, { "_wxObject","_wxCalculateLayoutEvent",SwigwxCalculateLayoutEventTowxObject}, - { "_wxObject","_class_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxObject}, { "_wxObject","_wxQueryLayoutInfoEvent",SwigwxQueryLayoutInfoEventTowxObject}, - { "_wxObject","_class_wxSashWindow",SwigwxSashWindowTowxObject}, { "_wxObject","_wxSashWindow",SwigwxSashWindowTowxObject}, - { "_wxObject","_class_wxSashEvent",SwigwxSashEventTowxObject}, { "_wxObject","_wxSashEvent",SwigwxSashEventTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -2644,23 +2571,13 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_class_wxCommandEvent","_class_wxSashEvent",SwigwxSashEventTowxCommandEvent}, - { "_class_wxCommandEvent","_wxSashEvent",SwigwxSashEventTowxCommandEvent}, - { "_wxEvtHandler","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxEvtHandler}, { "_wxEvtHandler","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxPopupWindow",SwigwxPopupWindowTowxEvtHandler}, { "_wxEvtHandler","_wxPopupWindow",SwigwxPopupWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxEvtHandler}, { "_wxEvtHandler","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxEvtHandler}, - { "_wxEvtHandler","_class_wxSashWindow",SwigwxSashWindowTowxEvtHandler}, { "_wxEvtHandler","_wxSashWindow",SwigwxSashWindowTowxEvtHandler}, - { "_wxWindow","_class_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxWindow}, { "_wxWindow","_wxPyPopupTransientWindow",SwigwxPyPopupTransientWindowTowxWindow}, - { "_wxWindow","_class_wxPopupWindow",SwigwxPopupWindowTowxWindow}, { "_wxWindow","_wxPopupWindow",SwigwxPopupWindowTowxWindow}, - { "_wxWindow","_class_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxWindow}, { "_wxWindow","_wxSashLayoutWindow",SwigwxSashLayoutWindowTowxWindow}, - { "_wxWindow","_class_wxSashWindow",SwigwxSashWindowTowxWindow}, { "_wxWindow","_wxSashWindow",SwigwxSashWindowTowxWindow}, {0,0,0}}; diff --git a/wxPython/src/gtk/wx.cpp b/wxPython/src/gtk/wx.cpp index b8e3ee4c3a..d9e099b9e3 100644 --- a/wxPython/src/gtk/wx.cpp +++ b/wxPython/src/gtk/wx.cpp @@ -27,19 +27,21 @@ # define SWIGEXPORT(a) __declspec(dllexport) a # else # if defined(__BORLANDC__) -# define SWIGEXPORT(a) a _export +# define SWIGEXPORT(a) a _export # else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a # endif # endif #else -# define SWIGEXPORT(a) a +# define SWIGEXPORT(a) a #endif +#include "Python.h" + #ifdef __cplusplus extern "C" { #endif -#include "Python.h" + extern void SWIG_MakePtr(char *, void *, char *); extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); extern char *SWIG_GetPtr(char *, void **, char *); @@ -55,47 +57,28 @@ extern PyObject *SWIG_newvarlink(void); #include "helpers.h" -static PyObject* l_output_helper(PyObject* target, PyObject* o) { - PyObject* o2; - if (!target) { - target = o; - } else if (target == Py_None) { - Py_DECREF(Py_None); - target = o; - } else { - if (!PyList_Check(target)) { - o2 = target; - target = PyList_New(0); - PyList_Append(target, o2); - Py_XDECREF(o2); - } - PyList_Append(target,o); - Py_XDECREF(o); - } - return target; -} static PyObject* t_output_helper(PyObject* target, PyObject* o) { PyObject* o2; PyObject* o3; - if (!target) { + if (!target) { target = o; - } else if (target == Py_None) { + } else if (target == Py_None) { Py_DECREF(Py_None); target = o; - } else { + } 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); + o3 = PyTuple_New(1); + PyTuple_SetItem(o3, 0, o); o2 = target; - target = PySequence_Concat(o2, o3); - Py_DECREF(o2); + target = PySequence_Concat(o2, o3); + Py_DECREF(o2); Py_DECREF(o3); } return target; @@ -1750,13 +1733,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxPrintQuality","_EBool",0}, { "_wxPrintQuality","_size_t",0}, { "_wxPrintQuality","_time_t",0}, - { "_class_wxEvtHandler","_class_wxPyApp",SwigwxPyAppTowxEvtHandler}, - { "_class_wxEvtHandler","_wxPyApp",SwigwxPyAppTowxEvtHandler}, { "_byte","_unsigned_char",0}, { "_long","_unsigned_long",0}, { "_long","_signed_long",0}, - { "_class_wxObject","_class_wxPyApp",SwigwxPyAppTowxObject}, - { "_class_wxObject","_wxPyApp",SwigwxPyAppTowxObject}, { "_size_t","_wxCoord",0}, { "_size_t","_wxPrintQuality",0}, { "_size_t","_time_t",0}, @@ -1793,7 +1772,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_unsigned_short","_wxDateTime_t",0}, { "_unsigned_short","_WXTYPE",0}, { "_unsigned_short","_short",0}, - { "_wxObject","_class_wxPyApp",SwigwxPyAppTowxObject}, { "_wxObject","_wxPyApp",SwigwxPyAppTowxObject}, { "_signed_short","_WXTYPE",0}, { "_signed_short","_short",0}, @@ -1846,7 +1824,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { { "_wxCoord","_size_t",0}, { "_wxCoord","_time_t",0}, { "_wxCoord","_wxPrintQuality",0}, - { "_wxEvtHandler","_class_wxPyApp",SwigwxPyAppTowxEvtHandler}, { "_wxEvtHandler","_wxPyApp",SwigwxPyAppTowxEvtHandler}, {0,0,0}}; -- 2.45.2