Merged wxPython 2.4.x to the 2.5 branch (Finally!!!)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19793 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -260,10 +260,15 @@ void PYTHON::cpp_destructor(char *name, char *newname) {
|
||||
else realname = name;
|
||||
}
|
||||
|
||||
*pyclass << tab4 << "def __del__(self," << module << "=" << module << "):\n";
|
||||
char* dfname = name_destroy(realname);
|
||||
|
||||
*pyclass << tab4 << "def __del__(self, " << "delfunc=" << module<< "." << dfname << "):\n";
|
||||
emitAddPragmas(*pyclass,"__del__",tab8);
|
||||
*pyclass << tab8 << "if self.thisown == 1 :\n"
|
||||
<< tab8 << tab4 << module << "." << name_destroy(realname) << "(self)\n";
|
||||
*pyclass << tab8 << "if self.thisown == 1:\n"
|
||||
<< tab8 << tab4 << "try:\n"
|
||||
<< tab8 << tab8 << "delfunc(self)\n"
|
||||
<< tab8 << tab4 << "except:\n"
|
||||
<< tab8 << tab8 << "pass\n";
|
||||
|
||||
have_destructor = 1;
|
||||
if (doc_entry) {
|
||||
|
@@ -484,9 +484,13 @@ PYTHON::get_pointer(char *iname, char *srcname, char *src, char *dest,
|
||||
|
||||
// Now get the pointer value from the string and save in dest
|
||||
|
||||
f << tab4 << "if (" << src << ") {\n"
|
||||
<< tab8 << "if (" << src << " == Py_None) { " << dest << " = NULL; }\n"
|
||||
<< tab8 << "else if (SWIG_GetPtrObj(" << src << ",(void **) &" << dest << ",";
|
||||
if (t->is_reference)
|
||||
f << tab4 << "if (" << src << ") {\n"
|
||||
<< tab8 << "if (SWIG_GetPtrObj(" << src << ",(void **) &" << dest << ",";
|
||||
else
|
||||
f << tab4 << "if (" << src << ") {\n"
|
||||
<< tab8 << "if (" << src << " == Py_None) { " << dest << " = NULL; }\n"
|
||||
<< tab8 << "else if (SWIG_GetPtrObj(" << src << ",(void **) &" << dest << ",";
|
||||
|
||||
// If we're passing a void pointer, we give the pointer conversion a NULL
|
||||
// pointer, otherwise pass in the expected type.
|
||||
|
1
wxPython/wxSWIG/swig_lib/perl5/.cvsignore
Normal file
1
wxPython/wxSWIG/swig_lib/perl5/.cvsignore
Normal file
@@ -0,0 +1 @@
|
||||
Makefile
|
1
wxPython/wxSWIG/swig_lib/python/.cvsignore
Normal file
1
wxPython/wxSWIG/swig_lib/python/.cvsignore
Normal file
@@ -0,0 +1 @@
|
||||
Makefile
|
@@ -1,3 +1,5 @@
|
||||
#include "Python.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
/* Definitions for Windows/Unix exporting */
|
||||
@@ -15,12 +17,9 @@
|
||||
# define SWIGEXPORT(a) a
|
||||
#endif
|
||||
|
||||
#include "Python.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void SWIG_MakePtr(char *, void *, char *);
|
||||
extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *));
|
||||
extern char *SWIG_GetPtr(char *, void **, char *);
|
||||
|
@@ -5,11 +5,11 @@
|
||||
* Contains variable linking and pointer type-checking code.
|
||||
************************************************************************/
|
||||
|
||||
#include "Python.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "Python.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
1
wxPython/wxSWIG/swig_lib/tcl/.cvsignore
Normal file
1
wxPython/wxSWIG/swig_lib/tcl/.cvsignore
Normal file
@@ -0,0 +1 @@
|
||||
Makefile
|
Reference in New Issue
Block a user