wxListbook needs to clean up the wxListCtrl when DeleteAllPages is called.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28909 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
ffdf1b4903
commit
fbd11d30c8
@ -109,6 +109,8 @@ public:
|
||||
// returns true if we have wxLB_TOP or wxLB_BOTTOM style
|
||||
bool IsVertical() const { return HasFlag(wxLB_BOTTOM | wxLB_TOP); }
|
||||
|
||||
virtual bool DeleteAllPages();
|
||||
|
||||
protected:
|
||||
virtual wxWindow *DoRemovePage(size_t page);
|
||||
|
||||
|
@ -411,6 +411,13 @@ wxWindow *wxListbook::DoRemovePage(size_t page)
|
||||
return win;
|
||||
}
|
||||
|
||||
|
||||
bool wxListbook::DeleteAllPages()
|
||||
{
|
||||
m_list->DeleteAllItems();
|
||||
return wxBookCtrl::DeleteAllPages();
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxListbook events
|
||||
// ----------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user