Changes needed to be able to build with SWIG 1.3.24, 1.3.27 as well as
the upcoming 1.3.28, using #if statements on SWIG_VERSION. Adjustments to ownership of SWIG objects, add some destructors and explicitly disown non-window objects when their ownership is transfered to a C++ object. Since all window objects are owned by their parent, or by themselves, always set their thisown attribute to False. Explicitly set thisown to False after any Destroy() methods are called, so SWIG doesn't try to destroy them again. Etc. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37203 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -153,7 +153,7 @@ public:
|
||||
wxListItemAttr(const wxColour& colText = wxNullColour,
|
||||
const wxColour& colBack = wxNullColour,
|
||||
const wxFont& font = wxNullFont);
|
||||
|
||||
~wxListItemAttr();
|
||||
|
||||
// setters
|
||||
void SetTextColour(const wxColour& colText);
|
||||
@@ -169,6 +169,9 @@ public:
|
||||
wxColour GetBackgroundColour();
|
||||
wxFont GetFont();
|
||||
|
||||
void AssignFrom(const wxListItemAttr& source);
|
||||
|
||||
%pythonAppend Destroy "args[0].thisown = 0"
|
||||
%extend { void Destroy() { delete self; } }
|
||||
};
|
||||
|
||||
@@ -592,11 +595,9 @@ public:
|
||||
// Sets the image list
|
||||
void SetImageList(wxImageList *imageList, int which);
|
||||
|
||||
// is there a way to tell SWIG to disown this???
|
||||
|
||||
%apply SWIGTYPE *DISOWN { wxImageList *imageList };
|
||||
%disownarg( wxImageList *imageList );
|
||||
void AssignImageList(wxImageList *imageList, int which);
|
||||
%clear wxImageList *imageList;
|
||||
%cleardisown( wxImageList *imageList );
|
||||
|
||||
// are we in report mode?
|
||||
bool InReportView() const;
|
||||
|
Reference in New Issue
Block a user