X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/09ee8e72b22be844ae4f3467787878d63ee6bf38..2356708db31b737c6eae53c2316b642aa5a2e68d:/utils/wxPython/SWIG.patches/SWIG.patch diff --git a/utils/wxPython/SWIG.patches/SWIG.patch b/utils/wxPython/SWIG.patches/SWIG.patch index 539916bc5f..a50235c64b 100644 --- a/utils/wxPython/SWIG.patches/SWIG.patch +++ b/utils/wxPython/SWIG.patches/SWIG.patch @@ -1,12 +1,12 @@ -*** cplus.cxx.old Mon Feb 02 14:55:42 1998 ---- cplus.cxx Fri Aug 28 12:02:50 1998 +*** cplus.cxx.old Mon Feb 02 15:55:42 1998 +--- cplus.cxx Fri Aug 28 13:02:50 1998 *************** *** 581,612 **** // Class for managing class members (internally) // ---------------------------------------------------------------------- - + static char *inherit_base_class = 0; - + - class CPP_class { - public: - char *classname; // Real class name @@ -28,7 +28,7 @@ - CPP_member *members; // Linked list of members - CPP_class *next; // Next class - static CPP_class *classlist; // List of all classes stored - + ! CPP_class(char *name, char *ctype) { CPP_class *c; classname = copy_string(name); @@ -37,12 +37,12 @@ --- 581,593 ---- // Class for managing class members (internally) // ---------------------------------------------------------------------- - + static char *inherit_base_class = 0; + CPP_class *CPP_class::classlist = 0; + CPP_class *current_class; - - + + ! CPP_class::CPP_class(char *name, char *ctype) { CPP_class *c; classname = copy_string(name); @@ -53,20 +53,20 @@ // ------------------------------------------------------------------------------ // Add a new C++ member to this class // ------------------------------------------------------------------------------ - + ! void add_member(CPP_member *m) { CPP_member *cm; - + // Set base class where this was defined - if (inherit_base_class) + if (inherit_base_class) --- 623,631 ---- // ------------------------------------------------------------------------------ // Add a new C++ member to this class // ------------------------------------------------------------------------------ - + ! void CPP_class::add_member(CPP_member *m) { CPP_member *cm; - + // Set base class where this was defined if (inherit_base_class) *************** @@ -74,7 +74,7 @@ // ------------------------------------------------------------------------------ // Search for a member with the given name. Returns the member on success, 0 on failure // ------------------------------------------------------------------------------ - + ! CPP_member *search_member(char *name) { CPP_member *m; char *c; @@ -84,7 +84,7 @@ // ------------------------------------------------------------------------------ // Search for a member with the given name. Returns the member on success, 0 on failure // ------------------------------------------------------------------------------ - + ! CPP_member *CPP_class::search_member(char *name) { CPP_member *m; char *c; @@ -95,7 +95,7 @@ // ------------------------------------------------------------------------------ // Inherit. Put all the declarations associated with this class into the current // ------------------------------------------------------------------------------ - + ! void inherit_decls(int mode) { CPP_member *m; m = members; @@ -105,7 +105,7 @@ // ------------------------------------------------------------------------------ // Inherit. Put all the declarations associated with this class into the current // ------------------------------------------------------------------------------ - + ! void CPP_class::inherit_decls(int mode) { CPP_member *m; m = members; @@ -114,9 +114,9 @@ *************** *** 696,704 **** // ------------------------------------------------------------------------------ - // Emit all of the declarations associated with this class + // Emit all of the declarations associated with this class // ------------------------------------------------------------------------------ - + ! void emit_decls() { CPP_member *m = members; int last_scope = name_scope(0); @@ -126,7 +126,7 @@ // ------------------------------------------------------------------------------ // Emit all of the declarations associated with this class // ------------------------------------------------------------------------------ - + ! void CPP_class::emit_decls() { CPP_member *m = members; int last_scope = name_scope(0); @@ -134,10 +134,10 @@ while (m) { *************** *** 713,721 **** - // ------------------------------------------------------------------------------ + // ------------------------------------------------------------------------------ // Search for a given class in the list // ------------------------------------------------------------------------------ - + ! static CPP_class *search(char *name) { CPP_class *c; c = classlist; @@ -147,7 +147,7 @@ // ------------------------------------------------------------------------------ // Search for a given class in the list // ------------------------------------------------------------------------------ - + ! CPP_class *CPP_class::search(char *name) { CPP_class *c; c = classlist; @@ -158,22 +158,22 @@ // Add default constructors and destructors // // ------------------------------------------------------------------------------ - + ! void create_default() { if (!generate_default) return; - + // Try to generate a constructor if not available. - + --- 710,718 ---- // Add default constructors and destructors // // ------------------------------------------------------------------------------ - + ! void CPP_class::create_default() { if (!generate_default) return; - + // Try to generate a constructor if not available. - + *************** *** 751,764 **** // ------------------------------------------------------------------------------ @@ -182,21 +182,21 @@ // ------------------------------------------------------------------------------ - static void create_all(); - }; -- +- - CPP_class *CPP_class::classlist = 0; - static CPP_class *current_class; -- +- void CPP_class::create_all() { CPP_class *c; c = classlist; while (c) { --- 732,739 ---- -*** vector.cxx.old Fri Aug 28 14:23:16 1998 ---- vector.cxx Fri Aug 28 14:46:52 1998 +*** vector.cxx.old Fri Aug 28 15:23:16 1998 +--- vector.cxx Fri Aug 28 15:46:52 1998 *************** *** 0 **** --- 1,182 ---- -+ ++ + /******************************************************************************* + * Simplified Wrapper and Interface Generator (SWIG) + * @@ -237,9 +237,9 @@ + * SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + * + *******************************************************************************/ -+ ++ + #include "internal.h" -+ ++ + /******************************************************************************* + * $Header$ + * @@ -249,9 +249,9 @@ + * successful. Should be made more robust... + * + *******************************************************************************/ -+ ++ + void* Vector::s_nullPtr = NULL; -+ ++ + // ----------------------------------------------------------------------------- + // Vector::Vector(size_t allocSize = 8) + // @@ -263,7 +263,7 @@ + // + // Side Effects : None + // ----------------------------------------------------------------------------- -+ ++ + Vector::Vector(size_t allocSize) + : m_size(allocSize), + m_count(0), @@ -276,27 +276,27 @@ + m_data[i] = 0; + } + } -+ -+ ++ ++ + // ----------------------------------------------------------------------------- + // Vector::~Vector + // + // Destructor. Only cleans up the vector, not its contents! + // + // ----------------------------------------------------------------------------- -+ -+ ++ ++ + Vector::~Vector() { + if (m_data) { + delete [] m_data; + } -+ ++ + m_data = 0; + m_size = m_count = 0; + } -+ -+ -+ ++ ++ ++ + // ----------------------------------------------------------------------------- + // size_t Vector::extend(size_t newSize) + // @@ -306,48 +306,48 @@ + // Returns the new allocated size. + // + // ----------------------------------------------------------------------------- -+ ++ + #define GRANULARITY 16 -+ ++ + size_t Vector::extend(size_t newSize) { -+ ++ + if (newSize > m_size) { + newSize = newSize + (GRANULARITY - (newSize % GRANULARITY)); -+ ++ + void** temp = new void*[newSize]; + memcpy(temp, m_data, m_size*sizeof(void*)); -+ ++ + int i; + for (i=m_size; i= m_size) { + extend(m_count + 1); + } -+ ++ + m_data[m_count] = object; + m_count += 1; -+ ++ + return m_count; + } -+ -+ ++ ++ + // ----------------------------------------------------------------------------- + // Vector::operator[] (size_t idx) + // @@ -355,134 +355,176 @@ + // of the vector, returns a reference to s_nullPtr. + // + // ----------------------------------------------------------------------------- -+ ++ + void*& Vector::operator[] (size_t idx) { + if (idx >= m_size) { + s_nullPtr = 0; + return s_nullPtr; + } -+ ++ + return m_data[idx]; + } -+ -+ ++ ++ + /*********************************************************************** + * + * -- Revision History + * $Log$ -+ * Revision 1.1 1998/10/03 05:56:03 RD -+ * *** empty log message *** ++ * Revision 1.3 1999/07/31 07:54:05 RD ++ * wxPython 2.1b1: ++ * ++ * Added the missing wxWindow.GetUpdateRegion() method. ++ * ++ * Made a new change in SWIG (update your patches everybody) that ++ * provides a fix for global shadow objects that get an exception in ++ * their __del__ when their extension module has already been deleted. ++ * It was only a 1 line change in .../SWIG/Modules/pycpp.cxx at about ++ * line 496 if you want to do it by hand. ++ * ++ * It is now possible to run through MainLoop more than once in any one ++ * process. The cleanup that used to happen as MainLoop completed (and ++ * prevented it from running again) has been delayed until the wxc module ++ * is being unloaded by Python. ++ * ++ * wxWindow.PopupMenu() now takes a wxPoint instead of x,y. Added ++ * wxWindow.PopupMenuXY to be consistent with some other methods. ++ * ++ * Added wxGrid.SetEditInPlace and wxGrid.GetEditInPlace. ++ * ++ * You can now provide your own app.MainLoop method. See ++ * wxPython/demo/demoMainLoop.py for an example and some explaination. ++ * ++ * Got the in-place-edit for the wxTreeCtrl fixed and added some demo ++ * code to show how to use it. ++ * ++ * Put the wxIcon constructor back in for GTK as it now has one that ++ * matches MSW's. ++ * ++ * Added wxGrid.GetCells ++ * ++ * Added wxSystemSettings static methods as functions with names like ++ * wxSystemSettings_GetSystemColour. ++ * ++ * Removed wxPyMenu since using menu callbacks have been depreciated in ++ * wxWindows. Use wxMenu and events instead. ++ * ++ * Added alternate wxBitmap constructor (for MSW only) as ++ * wxBitmapFromData(data, type, width, height, depth = 1) ++ * ++ * Added a helper function named wxPyTypeCast that can convert shadow ++ * objects of one type into shadow objects of another type. (Like doing ++ * a down-cast.) See the implementation in wx.py for some docs. + * + * + ***********************************************************************/ -+ -+ -+ -+ -+ -+ -*** makefile.msc.old Mon Jun 23 15:15:32 1997 ---- makefile.msc Fri Aug 28 10:21:58 1998 ++ ++ ++ ++ ++ ++ +*** makefile.msc.old Mon Jun 23 16:15:32 1997 +--- makefile.msc Fri Aug 28 11:21:58 1998 *************** *** 33,50 **** # Normally, you shouldn't have to change anything below this point # ######################################################################## - + LIBOBJS = main.obj scanner.obj symbol.obj include.obj types.obj parms.obj emit.obj newdoc.obj ascii.obj \ ! html.obj latex.obj cplus.obj lang.obj hash.obj sstring.obj wrapfunc.obj getopt.obj comment.obj typemap.obj naming.obj - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx emit.cxx \ ! newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx \ sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIBNAME = ..\libswig.lib INCLUDE = -I../Include -I$(STD_INC) ! CFLAGS = -Zi -nologo -DSWIG_LIB="\"$(SWIG_LIB)\"" -DSWIG_CC="\"$(CC)\"" -DMSDOS -DSTDC_HEADERS=1 -DHAVE_LIBDL=1 $(SWIG_OPTS) LD_FLAGS = -VERBOSE - - + + # --- 33,50 ---- # Normally, you shouldn't have to change anything below this point # ######################################################################## - + LIBOBJS = main.obj scanner.obj symbol.obj include.obj types.obj parms.obj emit.obj newdoc.obj ascii.obj \ ! html.obj latex.obj cplus.obj lang.obj hash.obj vector.obj sstring.obj wrapfunc.obj getopt.obj comment.obj typemap.obj naming.obj - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx emit.cxx \ ! newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx vector.cxx \ sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIBNAME = ..\libswig.lib INCLUDE = -I../Include -I$(STD_INC) ! CFLAGS = -Zi -nologo -DSWIG_LIB="\"$(SWIG_LIB)\"" -DSWIG_CC="\"$(CC)\"" -DMSDOS -DSTDC_HEADERS=1 -DHAVE_LIBDL=1 $(SWIG_OPTS) $(OTHERFLAGS) LD_FLAGS = -VERBOSE - - + + # -*** makefile.bc.old Sun Jan 04 12:49:24 1998 ---- makefile.bc Fri Aug 28 14:42:58 1998 +*** makefile.bc.old Sun Jan 04 13:49:24 1998 +--- makefile.bc Fri Aug 28 15:42:58 1998 *************** *** 34,47 **** ######################################################################## - + LIBOBJS = main.obj scanner.obj symbol.obj include.obj types.obj parms.obj \ emit.obj newdoc.obj ascii.obj \ ! html.obj latex.obj cplus.obj lang.obj hash.obj sstring.obj \ wrapfunc.obj getopt.obj comment.obj typemap.obj naming.obj - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx \ emit.cxx newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx \ ! sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIBNAME = ..\libswig.lib INCLUDE = -I../Include -I$(STD_INC) --- 34,47 ---- ######################################################################## - + LIBOBJS = main.obj scanner.obj symbol.obj include.obj types.obj parms.obj \ emit.obj newdoc.obj ascii.obj \ ! html.obj latex.obj cplus.obj lang.obj hash.obj vector.obj sstring.obj \ wrapfunc.obj getopt.obj comment.obj typemap.obj naming.obj - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx \ emit.cxx newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx \ ! vector.cxx sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIBNAME = ..\libswig.lib INCLUDE = -I../Include -I$(STD_INC) -*** Makefile.in.old Wed May 28 22:56:56 1997 ---- Makefile.in Fri Aug 28 14:43:36 1998 +*** Makefile.in.old Wed May 28 23:56:56 1997 +--- Makefile.in Fri Aug 28 15:43:36 1998 *************** *** 51,63 **** # Normally, you shouldn't have to change anything below this point # ######################################################################## - + LIBOBJS = main.o scanner.o symbol.o include.o types.o parms.o emit.o newdoc.o ascii.o \ ! html.o latex.o cplus.o lang.o hash.o sstring.o wrapfunc.o getopt.o comment.o \ typemap.o naming.o - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx emit.cxx \ ! newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx \ sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIB = ../libswig.a --- 51,63 ---- # Normally, you shouldn't have to change anything below this point # ######################################################################## - + LIBOBJS = main.o scanner.o symbol.o include.o types.o parms.o emit.o newdoc.o ascii.o \ ! html.o latex.o cplus.o lang.o hash.o vector.o sstring.o wrapfunc.o getopt.o comment.o \ typemap.o naming.o - + LIBSRCS = main.cxx scanner.cxx symbol.cxx include.cxx types.cxx parms.cxx emit.cxx \ ! newdoc.cxx ascii.cxx html.cxx latex.cxx cplus.cxx lang.cxx hash.cxx vector.cxx \ sstring.cxx wrapfunc.cxx getopt.cxx comment.cxx typemap.cxx naming.cxx - + LIBHEADERS = internal.h ../Include/swig.h latex.h ascii.h html.h nodoc.h LIB = ../libswig.a