From b731267565579a085005434ed0d9803f71d386cb Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 23 Nov 1999 20:36:23 +0000 Subject: [PATCH 1/1] a bug fix in helpers for ref-counting callbacks some generated code updates git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4667 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- utils/wxPython/src/gtk/clip_dnd.cpp | 213 ++++++++++++++-------------- utils/wxPython/src/gtk/clip_dnd.py | 2 +- utils/wxPython/src/gtk/wx.cpp | 9 +- utils/wxPython/src/gtk/wx.py | 9 +- utils/wxPython/src/helpers.cpp | 5 +- utils/wxPython/src/helpers.h | 1 + 6 files changed, 129 insertions(+), 110 deletions(-) diff --git a/utils/wxPython/src/gtk/clip_dnd.cpp b/utils/wxPython/src/gtk/clip_dnd.cpp index f1a86494a8..066daef4df 100644 --- a/utils/wxPython/src/gtk/clip_dnd.cpp +++ b/utils/wxPython/src/gtk/clip_dnd.cpp @@ -1,15 +1,15 @@ /* * FILE : gtk/clip_dnd.cpp - * + * * This file was automatically generated by : * Simplified Wrapper and Interface Generator (SWIG) * Version 1.1 (Build 810) - * + * * Portions Copyright (c) 1995-1998 * The University of Utah and The Regents of the University of California. * Permission is granted to distribute this file in any manner provided * this notice remains intact. - * + * * Do not make changes to this file--changes will be lost! * */ @@ -27,13 +27,13 @@ # 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 #ifdef __cplusplus @@ -61,12 +61,12 @@ extern PyObject *SWIG_newvarlink(void); static PyObject* l_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 (!PyList_Check(target)) { o2 = target; target = PyList_New(0); @@ -83,23 +83,23 @@ 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; @@ -223,6 +223,8 @@ public: const wxIcon &go = wxNullIcon) : wxDropSource(win, go) {} #endif + ~wxPyDropSource() { printf("dtor\n"); } + DEC_PYCALLBACK_BOOL_DR(GiveFeedback); PYPRIVATE; }; @@ -331,7 +333,7 @@ static PyObject *_wrap_wxCustomDataFormat(PyObject *self, PyObject *args, PyObje char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataFormat",_kwnames,&_obj0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataFormat",_kwnames,&_obj0)) return NULL; { if (!PyString_Check(_obj0)) { @@ -396,7 +398,7 @@ static PyObject *_wrap_wxIsDragResultOk(PyObject *self, PyObject *args, PyObject char *_kwnames[] = { "res", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:wxIsDragResultOk",_kwnames,&_arg0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:wxIsDragResultOk",_kwnames,&_arg0)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -416,7 +418,7 @@ static PyObject *_wrap_new_wxDataFormat(PyObject *self, PyObject *args, PyObject char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:new_wxDataFormat",_kwnames,&_arg0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:new_wxDataFormat",_kwnames,&_arg0)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -441,7 +443,7 @@ static PyObject *_wrap_delete_wxDataFormat(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDataFormat",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDataFormat",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -469,7 +471,7 @@ static PyObject *_wrap_wxDataFormat_SetType(PyObject *self, PyObject *args, PyOb char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxDataFormat_SetType",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxDataFormat_SetType",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -497,7 +499,7 @@ static PyObject *_wrap_wxDataFormat_GetType(PyObject *self, PyObject *args, PyOb char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataFormat_GetType",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataFormat_GetType",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -524,7 +526,7 @@ static PyObject *_wrap_wxDataFormat_GetId(PyObject *self, PyObject *args, PyObje char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataFormat_GetId",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataFormat_GetId",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -556,7 +558,7 @@ static PyObject *_wrap_wxDataFormat_SetId(PyObject *self, PyObject *args, PyObje char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Os:wxDataFormat_SetId",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Os:wxDataFormat_SetId",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -583,7 +585,7 @@ static PyObject *_wrap_delete_wxDataObject(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -613,7 +615,7 @@ static PyObject *_wrap_wxDataObject_GetPreferredFormat(PyObject *self, PyObject char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDataObject_GetPreferredFormat",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDataObject_GetPreferredFormat",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -642,7 +644,7 @@ static PyObject *_wrap_wxDataObject_GetFormatCount(PyObject *self, PyObject *arg char *_kwnames[] = { "self","dir", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDataObject_GetFormatCount",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDataObject_GetFormatCount",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -671,7 +673,7 @@ static PyObject *_wrap_wxDataObject_GetAllFormats(PyObject *self, PyObject *args char *_kwnames[] = { "self","formats","dir", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|i:wxDataObject_GetAllFormats",_kwnames,&_argo0,&_argo1,&_arg2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|i:wxDataObject_GetAllFormats",_kwnames,&_argo0,&_argo1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -708,7 +710,7 @@ static PyObject *_wrap_wxDataObject_GetDataSize(PyObject *self, PyObject *args, char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObject_GetDataSize",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObject_GetDataSize",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -746,7 +748,7 @@ static PyObject *_wrap_wxDataObject_GetDataHere(PyObject *self, PyObject *args, char *_kwnames[] = { "self","format","buf", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDataObject_GetDataHere",_kwnames,&_argo0,&_argo1,&_argo2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDataObject_GetDataHere",_kwnames,&_argo0,&_argo1,&_argo2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -792,7 +794,7 @@ static PyObject *_wrap_wxDataObject_SetData(PyObject *self, PyObject *args, PyOb char *_kwnames[] = { "self","format","len","buf", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOiO:wxDataObject_SetData",_kwnames,&_argo0,&_argo1,&_arg2,&_argo3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOiO:wxDataObject_SetData",_kwnames,&_argo0,&_argo1,&_arg2,&_argo3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -835,7 +837,7 @@ static PyObject *_wrap_wxDataObject_IsSupportedFormat(PyObject *self, PyObject * char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObject_IsSupportedFormat",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObject_IsSupportedFormat",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -878,7 +880,7 @@ static PyObject *_wrap_new_wxDataObjectSimple(PyObject *self, PyObject *args, Py char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxDataObjectSimple",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxDataObjectSimple",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -912,7 +914,7 @@ static PyObject *_wrap_wxDataObjectSimple_GetFormat(PyObject *self, PyObject *ar char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataObjectSimple_GetFormat",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDataObjectSimple_GetFormat",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -947,7 +949,7 @@ static PyObject *_wrap_wxDataObjectSimple_SetFormat(PyObject *self, PyObject *ar char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObjectSimple_SetFormat",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDataObjectSimple_SetFormat",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -999,7 +1001,7 @@ static PyObject *_wrap_new_wxPyDataObjectSimple(PyObject *self, PyObject *args, char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyDataObjectSimple",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyDataObjectSimple",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1033,7 +1035,7 @@ static PyObject *_wrap_wxPyDataObjectSimple__setSelf(PyObject *self, PyObject *a char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDataObjectSimple__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDataObjectSimple__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1071,7 +1073,7 @@ static PyObject *_wrap_new_wxDataObjectComposite(PyObject *self, PyObject *args, char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxDataObjectComposite",_kwnames)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxDataObjectComposite",_kwnames)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -1099,7 +1101,7 @@ static PyObject *_wrap_wxDataObjectComposite_Add(PyObject *self, PyObject *args, char *_kwnames[] = { "self","dataObject","preferred", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|i:wxDataObjectComposite_Add",_kwnames,&_argo0,&_argo1,&_arg2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|i:wxDataObjectComposite_Add",_kwnames,&_argo0,&_argo1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1151,7 +1153,7 @@ static PyObject *_wrap_new_wxTextDataObject(PyObject *self, PyObject *args, PyOb char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxTextDataObject",_kwnames,&_obj0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxTextDataObject",_kwnames,&_obj0)) return NULL; if (_obj0) { @@ -1189,7 +1191,7 @@ static PyObject *_wrap_wxTextDataObject_GetTextLength(PyObject *self, PyObject * char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDataObject_GetTextLength",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDataObject_GetTextLength",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1216,7 +1218,7 @@ static PyObject *_wrap_wxTextDataObject_GetText(PyObject *self, PyObject *args, char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDataObject_GetText",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDataObject_GetText",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1249,7 +1251,7 @@ static PyObject *_wrap_wxTextDataObject_SetText(PyObject *self, PyObject *args, char *_kwnames[] = { "self","text", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTextDataObject_SetText",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTextDataObject_SetText",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1313,7 +1315,7 @@ static PyObject *_wrap_new_wxPyTextDataObject(PyObject *self, PyObject *args, Py char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyTextDataObject",_kwnames,&_obj0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyTextDataObject",_kwnames,&_obj0)) return NULL; if (_obj0) { @@ -1352,7 +1354,7 @@ static PyObject *_wrap_wxPyTextDataObject__setSelf(PyObject *self, PyObject *arg char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyTextDataObject__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyTextDataObject__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1400,7 +1402,7 @@ static PyObject *_wrap_new_wxBitmapDataObject(PyObject *self, PyObject *args, Py char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxBitmapDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxBitmapDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1434,7 +1436,7 @@ static PyObject *_wrap_wxBitmapDataObject_GetBitmap(PyObject *self, PyObject *ar char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmapDataObject_GetBitmap",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmapDataObject_GetBitmap",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1463,7 +1465,7 @@ static PyObject *_wrap_wxBitmapDataObject_SetBitmap(PyObject *self, PyObject *ar char *_kwnames[] = { "self","bitmap", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmapDataObject_SetBitmap",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmapDataObject_SetBitmap",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1523,7 +1525,7 @@ static PyObject *_wrap_new_wxPyBitmapDataObject(PyObject *self, PyObject *args, char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyBitmapDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyBitmapDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1557,7 +1559,7 @@ static PyObject *_wrap_wxPyBitmapDataObject__setSelf(PyObject *self, PyObject *a char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyBitmapDataObject__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyBitmapDataObject__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1603,7 +1605,7 @@ static PyObject *_wrap_new_wxFileDataObject(PyObject *self, PyObject *args, PyOb char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFileDataObject",_kwnames)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFileDataObject",_kwnames)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -1635,7 +1637,7 @@ static PyObject *_wrap_wxFileDataObject_GetFilenames(PyObject *self, PyObject *a char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFileDataObject_GetFilenames",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFileDataObject_GetFilenames",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1681,7 +1683,7 @@ static PyObject *_wrap_new_wxCustomDataObject(PyObject *self, PyObject *args, Py char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxCustomDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxCustomDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1719,7 +1721,7 @@ static PyObject *_wrap_wxCustomDataObject_TakeData(PyObject *self, PyObject *arg char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxCustomDataObject_TakeData",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxCustomDataObject_TakeData",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1757,7 +1759,7 @@ static PyObject *_wrap_wxCustomDataObject_SetData(PyObject *self, PyObject *args char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxCustomDataObject_SetData",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxCustomDataObject_SetData",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1787,7 +1789,7 @@ static PyObject *_wrap_wxCustomDataObject_GetSize(PyObject *self, PyObject *args char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataObject_GetSize",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataObject_GetSize",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1816,7 +1818,7 @@ static PyObject *_wrap_wxCustomDataObject_GetData(PyObject *self, PyObject *args char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataObject_GetData",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCustomDataObject_GetData",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1844,7 +1846,7 @@ static PyObject *_wrap_new_wxClipboard(PyObject *self, PyObject *args, PyObject char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxClipboard",_kwnames)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxClipboard",_kwnames)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -1870,7 +1872,7 @@ static PyObject *_wrap_wxClipboard_Open(PyObject *self, PyObject *args, PyObject char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Open",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Open",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1896,7 +1898,7 @@ static PyObject *_wrap_wxClipboard_Close(PyObject *self, PyObject *args, PyObjec char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Close",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Close",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1924,7 +1926,7 @@ static PyObject *_wrap_wxClipboard_IsOpened(PyObject *self, PyObject *args, PyOb char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_IsOpened",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_IsOpened",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1953,7 +1955,7 @@ static PyObject *_wrap_wxClipboard_AddData(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_AddData",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_AddData",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -1989,7 +1991,7 @@ static PyObject *_wrap_wxClipboard_SetData(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_SetData",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_SetData",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2025,7 +2027,7 @@ static PyObject *_wrap_wxClipboard_IsSupported(PyObject *self, PyObject *args, P char *_kwnames[] = { "self","format", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_IsSupported",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_IsSupported",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2061,7 +2063,7 @@ static PyObject *_wrap_wxClipboard_GetData(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_GetData",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxClipboard_GetData",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2094,7 +2096,7 @@ static PyObject *_wrap_wxClipboard_Clear(PyObject *self, PyObject *args, PyObjec char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Clear",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Clear",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2122,7 +2124,7 @@ static PyObject *_wrap_wxClipboard_Flush(PyObject *self, PyObject *args, PyObjec char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Flush",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxClipboard_Flush",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2149,7 +2151,7 @@ static PyObject *_wrap_wxClipboard_UsePrimarySelection(PyObject *self, PyObject char *_kwnames[] = { "self","primary", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxClipboard_UsePrimarySelection",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxClipboard_UsePrimarySelection",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2180,7 +2182,7 @@ static PyObject *_wrap_new_wxDropSource(PyObject *self, PyObject *args, PyObject char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|OO:new_wxDropSource",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|OO:new_wxDropSource",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2211,17 +2213,18 @@ static PyObject *_wrap_new_wxDropSource(PyObject *self, PyObject *args, PyObject return _resultobj; } -#define wxDropSource__setSelf(_swigobj,_swigarg0) (_swigobj->_setSelf(_swigarg0)) +#define wxDropSource__setSelf(_swigobj,_swigarg0,_swigarg1) (_swigobj->_setSelf(_swigarg0,_swigarg1)) static PyObject *_wrap_wxDropSource__setSelf(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; wxPyDropSource * _arg0; PyObject * _arg1; + int _arg2; PyObject * _argo0 = 0; PyObject * _obj1 = 0; - char *_kwnames[] = { "self","self", NULL }; + char *_kwnames[] = { "self","self","incref", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDropSource__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi:wxDropSource__setSelf",_kwnames,&_argo0,&_obj1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2235,7 +2238,7 @@ static PyObject *_wrap_wxDropSource__setSelf(PyObject *self, PyObject *args, PyO } { wxPy_BEGIN_ALLOW_THREADS; - wxDropSource__setSelf(_arg0,_arg1); + wxDropSource__setSelf(_arg0,_arg1,_arg2); wxPy_END_ALLOW_THREADS; } Py_INCREF(Py_None); @@ -2251,7 +2254,7 @@ static PyObject *_wrap_delete_wxDropSource(PyObject *self, PyObject *args, PyObj char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDropSource",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxDropSource",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2262,7 +2265,9 @@ static PyObject *_wrap_delete_wxDropSource(PyObject *self, PyObject *args, PyObj } { wxPy_BEGIN_ALLOW_THREADS; + printf("before dtor\n"); delete_wxPyDropSource(_arg0); + printf("after dtor\n"); wxPy_END_ALLOW_THREADS; } Py_INCREF(Py_None); @@ -2280,7 +2285,7 @@ static PyObject *_wrap_wxDropSource_SetData(PyObject *self, PyObject *args, PyOb char *_kwnames[] = { "self","data", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDropSource_SetData",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDropSource_SetData",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2316,7 +2321,7 @@ static PyObject *_wrap_wxDropSource_GetDataObject(PyObject *self, PyObject *args char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDropSource_GetDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDropSource_GetDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2351,7 +2356,7 @@ static PyObject *_wrap_wxDropSource_SetCursor(PyObject *self, PyObject *args, Py char *_kwnames[] = { "self","res","cursor", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiO:wxDropSource_SetCursor",_kwnames,&_argo0,&_arg1,&_argo2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiO:wxDropSource_SetCursor",_kwnames,&_argo0,&_arg1,&_argo2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2387,7 +2392,7 @@ static PyObject *_wrap_wxDropSource_DoDragDrop(PyObject *self, PyObject *args, P char *_kwnames[] = { "self","bAllowMove", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDropSource_DoDragDrop",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxDropSource_DoDragDrop",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2415,7 +2420,7 @@ static PyObject *_wrap_wxDropSource_base_GiveFeedback(PyObject *self, PyObject * char *_kwnames[] = { "self","effect", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxDropSource_base_GiveFeedback",_kwnames,&_argo0,&_arg1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxDropSource_base_GiveFeedback",_kwnames,&_argo0,&_arg1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2451,7 +2456,7 @@ static PyObject *_wrap_new_wxPyDropTarget(PyObject *self, PyObject *args, PyObje char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyDropTarget",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|O:new_wxPyDropTarget",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2485,7 +2490,7 @@ static PyObject *_wrap_wxPyDropTarget__setSelf(PyObject *self, PyObject *args, P char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2515,7 +2520,7 @@ static PyObject *_wrap_delete_wxPyDropTarget(PyObject *self, PyObject *args, PyO char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxPyDropTarget",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxPyDropTarget",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2544,7 +2549,7 @@ static PyObject *_wrap_wxPyDropTarget_GetDataObject(PyObject *self, PyObject *ar char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_GetDataObject",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_GetDataObject",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2578,7 +2583,7 @@ static PyObject *_wrap_wxPyDropTarget_SetDataObject(PyObject *self, PyObject *ar char *_kwnames[] = { "self","dataObject", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDropTarget_SetDataObject",_kwnames,&_argo0,&_argo1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyDropTarget_SetDataObject",_kwnames,&_argo0,&_argo1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2616,7 +2621,7 @@ static PyObject *_wrap_wxPyDropTarget_base_OnEnter(PyObject *self, PyObject *arg char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxPyDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxPyDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2646,7 +2651,7 @@ static PyObject *_wrap_wxPyDropTarget_base_OnDragOver(PyObject *self, PyObject * char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxPyDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxPyDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2672,7 +2677,7 @@ static PyObject *_wrap_wxPyDropTarget_base_OnLeave(PyObject *self, PyObject *arg char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_base_OnLeave",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_base_OnLeave",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2702,7 +2707,7 @@ static PyObject *_wrap_wxPyDropTarget_base_OnDrop(PyObject *self, PyObject *args char *_kwnames[] = { "self","x","y", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxPyDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxPyDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2729,7 +2734,7 @@ static PyObject *_wrap_wxPyDropTarget_GetData(PyObject *self, PyObject *args, Py char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_GetData",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPyDropTarget_GetData",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2771,7 +2776,7 @@ static PyObject *_wrap_new_wxTextDropTarget(PyObject *self, PyObject *args, PyOb char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxTextDropTarget",_kwnames)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxTextDropTarget",_kwnames)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -2798,7 +2803,7 @@ static PyObject *_wrap_wxTextDropTarget__setSelf(PyObject *self, PyObject *args, char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTextDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTextDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2832,7 +2837,7 @@ static PyObject *_wrap_wxTextDropTarget_base_OnEnter(PyObject *self, PyObject *a char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2862,7 +2867,7 @@ static PyObject *_wrap_wxTextDropTarget_base_OnDragOver(PyObject *self, PyObject char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2888,7 +2893,7 @@ static PyObject *_wrap_wxTextDropTarget_base_OnLeave(PyObject *self, PyObject *a char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDropTarget_base_OnLeave",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextDropTarget_base_OnLeave",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2918,7 +2923,7 @@ static PyObject *_wrap_wxTextDropTarget_base_OnDrop(PyObject *self, PyObject *ar char *_kwnames[] = { "self","x","y", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxTextDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxTextDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2948,7 +2953,7 @@ static PyObject *_wrap_wxTextDropTarget_base_OnData(PyObject *self, PyObject *ar char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnData",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxTextDropTarget_base_OnData",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -2990,7 +2995,7 @@ static PyObject *_wrap_new_wxFileDropTarget(PyObject *self, PyObject *args, PyOb char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFileDropTarget",_kwnames)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFileDropTarget",_kwnames)) return NULL; { wxPy_BEGIN_ALLOW_THREADS; @@ -3017,7 +3022,7 @@ static PyObject *_wrap_wxFileDropTarget__setSelf(PyObject *self, PyObject *args, char *_kwnames[] = { "self","self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxFileDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxFileDropTarget__setSelf",_kwnames,&_argo0,&_obj1)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3051,7 +3056,7 @@ static PyObject *_wrap_wxFileDropTarget_base_OnEnter(PyObject *self, PyObject *a char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnEnter",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3081,7 +3086,7 @@ static PyObject *_wrap_wxFileDropTarget_base_OnDragOver(PyObject *self, PyObject char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnDragOver",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3107,7 +3112,7 @@ static PyObject *_wrap_wxFileDropTarget_base_OnLeave(PyObject *self, PyObject *a char *_kwnames[] = { "self", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFileDropTarget_base_OnLeave",_kwnames,&_argo0)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFileDropTarget_base_OnLeave",_kwnames,&_argo0)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3137,7 +3142,7 @@ static PyObject *_wrap_wxFileDropTarget_base_OnDrop(PyObject *self, PyObject *ar char *_kwnames[] = { "self","x","y", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxFileDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxFileDropTarget_base_OnDrop",_kwnames,&_argo0,&_arg1,&_arg2)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3167,7 +3172,7 @@ static PyObject *_wrap_wxFileDropTarget_base_OnData(PyObject *self, PyObject *ar char *_kwnames[] = { "self","x","y","def", NULL }; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnData",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiii:wxFileDropTarget_base_OnData",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3)) return NULL; if (_argo0) { if (_argo0 == Py_None) { _arg0 = NULL; } @@ -3547,7 +3552,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { static PyObject *SWIG_globals; #ifdef __cplusplus -extern "C" +extern "C" #endif SWIGEXPORT(void) initclip_dndc() { PyObject *m, *d; diff --git a/utils/wxPython/src/gtk/clip_dnd.py b/utils/wxPython/src/gtk/clip_dnd.py index 7ebfabdb1a..471aecf292 100644 --- a/utils/wxPython/src/gtk/clip_dnd.py +++ b/utils/wxPython/src/gtk/clip_dnd.py @@ -333,7 +333,7 @@ class wxDropSource(wxDropSourcePtr): def __init__(self,*_args,**_kwargs): self.this = apply(clip_dndc.new_wxDropSource,_args,_kwargs) self.thisown = 1 - self._setSelf(self) + self._setSelf(self, 0) diff --git a/utils/wxPython/src/gtk/wx.cpp b/utils/wxPython/src/gtk/wx.cpp index 23bac2cda8..5b77d35318 100644 --- a/utils/wxPython/src/gtk/wx.cpp +++ b/utils/wxPython/src/gtk/wx.cpp @@ -2071,11 +2071,16 @@ SWIGEXPORT(void) initwxc() { PyDict_SetItemString(d,"wxCOLOURED", PyInt_FromLong((long) wxCOLOURED)); PyDict_SetItemString(d,"wxFIXED_LENGTH", PyInt_FromLong((long) wxFIXED_LENGTH)); PyDict_SetItemString(d,"wxALIGN_LEFT", PyInt_FromLong((long) wxALIGN_LEFT)); - PyDict_SetItemString(d,"wxALIGN_CENTER", PyInt_FromLong((long) wxALIGN_CENTER)); - PyDict_SetItemString(d,"wxALIGN_CENTRE", PyInt_FromLong((long) wxALIGN_CENTRE)); + PyDict_SetItemString(d,"wxALIGN_CENTER_HORIZONTAL", PyInt_FromLong((long) wxALIGN_CENTER_HORIZONTAL)); + PyDict_SetItemString(d,"wxALIGN_CENTRE_HORIZONTAL", PyInt_FromLong((long) wxALIGN_CENTRE_HORIZONTAL)); PyDict_SetItemString(d,"wxALIGN_RIGHT", PyInt_FromLong((long) wxALIGN_RIGHT)); PyDict_SetItemString(d,"wxALIGN_BOTTOM", PyInt_FromLong((long) wxALIGN_BOTTOM)); + PyDict_SetItemString(d,"wxALIGN_CENTER_VERTICAL", PyInt_FromLong((long) wxALIGN_CENTER_VERTICAL)); + PyDict_SetItemString(d,"wxALIGN_CENTRE_VERTICAL", PyInt_FromLong((long) wxALIGN_CENTRE_VERTICAL)); PyDict_SetItemString(d,"wxALIGN_TOP", PyInt_FromLong((long) wxALIGN_TOP)); + PyDict_SetItemString(d,"wxALIGN_CENTER", PyInt_FromLong((long) wxALIGN_CENTER)); + PyDict_SetItemString(d,"wxALIGN_CENTRE", PyInt_FromLong((long) wxALIGN_CENTRE)); + PyDict_SetItemString(d,"wxSHAPED", PyInt_FromLong((long) wxSHAPED)); PyDict_SetItemString(d,"wxLB_NEEDED_SB", PyInt_FromLong((long) wxLB_NEEDED_SB)); PyDict_SetItemString(d,"wxLB_ALWAYS_SB", PyInt_FromLong((long) wxLB_ALWAYS_SB)); PyDict_SetItemString(d,"wxLB_SORT", PyInt_FromLong((long) wxLB_SORT)); diff --git a/utils/wxPython/src/gtk/wx.py b/utils/wxPython/src/gtk/wx.py index 87f04b8258..04d55385c7 100644 --- a/utils/wxPython/src/gtk/wx.py +++ b/utils/wxPython/src/gtk/wx.py @@ -197,11 +197,16 @@ wxTB_DOCKABLE = wxc.wxTB_DOCKABLE wxCOLOURED = wxc.wxCOLOURED wxFIXED_LENGTH = wxc.wxFIXED_LENGTH wxALIGN_LEFT = wxc.wxALIGN_LEFT -wxALIGN_CENTER = wxc.wxALIGN_CENTER -wxALIGN_CENTRE = wxc.wxALIGN_CENTRE +wxALIGN_CENTER_HORIZONTAL = wxc.wxALIGN_CENTER_HORIZONTAL +wxALIGN_CENTRE_HORIZONTAL = wxc.wxALIGN_CENTRE_HORIZONTAL wxALIGN_RIGHT = wxc.wxALIGN_RIGHT wxALIGN_BOTTOM = wxc.wxALIGN_BOTTOM +wxALIGN_CENTER_VERTICAL = wxc.wxALIGN_CENTER_VERTICAL +wxALIGN_CENTRE_VERTICAL = wxc.wxALIGN_CENTRE_VERTICAL wxALIGN_TOP = wxc.wxALIGN_TOP +wxALIGN_CENTER = wxc.wxALIGN_CENTER +wxALIGN_CENTRE = wxc.wxALIGN_CENTRE +wxSHAPED = wxc.wxSHAPED wxLB_NEEDED_SB = wxc.wxLB_NEEDED_SB wxLB_ALWAYS_SB = wxc.wxLB_ALWAYS_SB wxLB_SORT = wxc.wxLB_SORT diff --git a/utils/wxPython/src/helpers.cpp b/utils/wxPython/src/helpers.cpp index 2d0466944a..87ec5fbe71 100644 --- a/utils/wxPython/src/helpers.cpp +++ b/utils/wxPython/src/helpers.cpp @@ -382,12 +382,14 @@ void wxPyCallback::EventThunker(wxEvent& event) { wxPyCallbackHelper::wxPyCallbackHelper() { m_self = NULL; m_lastFound = NULL; + m_incRef = FALSE; } wxPyCallbackHelper::~wxPyCallbackHelper() { bool doSave = wxPyRestoreThread(); - Py_XDECREF(m_self); + if (m_incRef) + Py_XDECREF(m_self); wxPySaveThread(doSave); } @@ -401,6 +403,7 @@ wxPyCallbackHelper::wxPyCallbackHelper(const wxPyCallbackHelper& other) { void wxPyCallbackHelper::setSelf(PyObject* self, int incref) { m_self = self; + m_incRef = incref; if (incref) Py_INCREF(m_self); } diff --git a/utils/wxPython/src/helpers.h b/utils/wxPython/src/helpers.h index bcf992aca6..c257924cdc 100644 --- a/utils/wxPython/src/helpers.h +++ b/utils/wxPython/src/helpers.h @@ -179,6 +179,7 @@ public: private: PyObject* m_self; PyObject* m_lastFound; + int m_incRef; }; -- 2.45.2