fix crash on exit, after hiding search tool then toggling tooltips
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@54342 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
b4de6e0d25
commit
dea482c985
@ -332,6 +332,13 @@ void MyFrame::RecreateToolbar()
|
||||
wxToolBarBase *toolBar = GetToolBar();
|
||||
long style = toolBar ? toolBar->GetWindowStyle() : TOOLBAR_STYLE;
|
||||
|
||||
if (toolBar && m_searchTool && m_searchTool->GetToolBar() == NULL)
|
||||
{
|
||||
// see ~MyFrame()
|
||||
toolBar->AddTool(m_searchTool);
|
||||
}
|
||||
m_searchTool = NULL;
|
||||
|
||||
delete toolBar;
|
||||
|
||||
SetToolBar(NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user