+//---------------------------------------------------------------------------
+
+
+%typemap(python, in) wxMemoryBuffer& {
+ if (!PyString_Check($source)) {
+ PyErr_SetString(PyExc_TypeError, "String buffer expected");
+ return NULL;
+ }
+ char* str = PyString_AS_STRING($source);
+ int len = PyString_GET_SIZE($source);
+ $target = new wxMemoryBuffer(len);
+ memcpy($target->GetData(), str, len);
+}
+
+%typemap(python, freearg) wxMemoryBuffer& {
+ if ($target)
+ delete $source;
+}
+
+%typemap(python, out) wxMemoryBuffer {
+ $target = PyString_FromStringAndSize((char*)$source->GetData(), $source->GetDataLen());
+}
+
+%typemap(python, ret) wxMemoryBuffer {
+ delete $source;
+}
//---------------------------------------------------------------------------
%typemap(python, out) wxToolTip* { $target = wxPyMake_wxObject($source); }
+%typemap(python, out) wxBitmapButton* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxButton* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxControl* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxFrame* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxGrid* { $target = wxPyMake_wxObject($source); }
+%typemap(python, out) wxListCtrl* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxMDIChildFrame* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxMDIClientWindow* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxMenuBar* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxTextCtrl* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxToolBar* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxToolBarBase* { $target = wxPyMake_wxObject($source); }
+%typemap(python, out) wxTreeCtrl* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxWindow* { $target = wxPyMake_wxObject($source); }
%typemap(python, out) wxHtmlWindow* { $target = wxPyMake_wxObject($source); }