X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f87da7220560e2f1a57e4e291cc75341f0ff1abe..52f52ebc4e0be6a9899d328b08db9eb14629d219:/wxPython/src/_dataobj.i diff --git a/wxPython/src/_dataobj.i b/wxPython/src/_dataobj.i index 2f0896a208..a0b8fbbdd6 100644 --- a/wxPython/src/_dataobj.i +++ b/wxPython/src/_dataobj.i @@ -222,7 +222,7 @@ bool wxPyDataObjectSimple::SetData(size_t len, const void *buf) const{ // Now define it for SWIG class wxPyDataObjectSimple : public wxDataObjectSimple { public: - %addtofunc wxPyDataObjectSimple "self._setCallbackInfo(self, PyDataObjectSimple)" + %pythonAppend wxPyDataObjectSimple "self._setCallbackInfo(self, PyDataObjectSimple)" wxPyDataObjectSimple(const wxDataFormat& format = wxFormatInvalid); void _setCallbackInfo(PyObject* self, PyObject* _class); @@ -240,8 +240,9 @@ class wxDataObjectComposite : public wxDataObject { public: wxDataObjectComposite(); - %addtofunc Add "args[1].thisown = 0" + %apply SWIGTYPE *DISOWN { wxDataObjectSimple *dataObject }; void Add(wxDataObjectSimple *dataObject, int preferred = False); + %clear wxDataObjectSimple *dataObject; }; //--------------------------------------------------------------------------- @@ -280,7 +281,7 @@ IMP_PYCALLBACK__STRING(wxPyTextDataObject, wxTextDataObject, SetText); // Now define it for SWIG class wxPyTextDataObject : public wxTextDataObject { public: - %addtofunc wxPyTextDataObject "self._setCallbackInfo(self, PyTextDataObject)" + %pythonAppend wxPyTextDataObject "self._setCallbackInfo(self, PyTextDataObject)" wxPyTextDataObject(const wxString& text = wxPyEmptyString); void _setCallbackInfo(PyObject* self, PyObject* _class); @@ -343,7 +344,7 @@ void wxPyBitmapDataObject::SetBitmap(const wxBitmap& bitmap) { // Now define it for SWIG class wxPyBitmapDataObject : public wxBitmapDataObject { public: - %addtofunc wxPyBitmapDataObject "self._setCallbackInfo(self, PyBitmapDataObject)" + %pythonAppend wxPyBitmapDataObject "self._setCallbackInfo(self, PyBitmapDataObject)" wxPyBitmapDataObject(const wxBitmap& bitmap = wxNullBitmap); void _setCallbackInfo(PyObject* self, PyObject* _class); @@ -359,9 +360,7 @@ public: wxFileDataObject(); const wxArrayString& GetFilenames(); -#ifdef __WXMSW__ void AddFile(const wxString &filename); -#endif }; @@ -424,7 +423,7 @@ public: //--------------------------------------------------------------------------- -#if !defined(__WXGTK__) && !defined(__WXX11__) +#if defined(__WXMSW__) || defined(__WXMAC__) %{ #include