From ee56b6b0862f2c3d92cb535542c124db739819cf Mon Sep 17 00:00:00 2001 From: Carsten Driesner Date: Fri, 20 Nov 2009 09:22:11 +0000 Subject: #i107003# Make toolbar invisible before calling doLazyDelete. This prevents possible crashes in scenarios where a modal dialog is visible. --- framework/source/uielement/toolbarmanager.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'framework/source') diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 55c8d16af2ec..294ab6ef3b74 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -341,9 +341,11 @@ void ToolBarManager::Destroy() delete static_cast< AddonsParams* >( m_pToolBar->GetItemData( nItemId )); } + // Hide toolbar as lazy delete can destroy the toolbar much later. + m_pToolBar->Hide(); /* #i99167# removed change for i93173 since there is some weird crash */ // #i93173# delete toolbar lazily as we can still be in one of its handlers - m_pToolBar->doLazyDelete(); + m_pToolBar->doLazyDelete(); Link aEmpty; m_pToolBar->SetSelectHdl( aEmpty ); -- cgit v1.2.3