diff --git a/src/aui/auibook.cpp b/src/aui/auibook.cpp index fd47ea1b14..96f9b24b23 100644 --- a/src/aui/auibook.cpp +++ b/src/aui/auibook.cpp @@ -3259,7 +3259,8 @@ bool wxAuiNotebook::DeletePage(size_t page_idx) // hide the window in advance, as this will // prevent flicker - ShowWnd(wnd, false); + if ( !IsBeingDeleted() ) + ShowWnd(wnd, false); if (!RemovePage(page_idx)) return false; diff --git a/src/aui/tabmdi.cpp b/src/aui/tabmdi.cpp index 853b5ae72b..82d199e645 100644 --- a/src/aui/tabmdi.cpp +++ b/src/aui/tabmdi.cpp @@ -716,7 +716,6 @@ wxAuiMDIClientWindow::wxAuiMDIClientWindow(wxAuiMDIParentFrame* parent, long sty wxAuiMDIClientWindow::~wxAuiMDIClientWindow() { - DestroyChildren(); } bool wxAuiMDIClientWindow::CreateClient(wxAuiMDIParentFrame* parent, long style)