diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-10-12 15:42:59 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-10-16 09:54:13 +0200 |
commit | 8a2f7704cd0e43304e54bf2281232335cc0979a3 (patch) | |
tree | a8357d52e613dbff7bd4b6097f75be6871863ce6 /framework/source | |
parent | 7dc9fb33db45c269fece6cfec993b124491c68f6 (diff) |
drop LazyDeletor
Change-Id: I7d2e00466f321994a46b0529d645e342f229c929
Reviewed-on: https://gerrit.libreoffice.org/61718
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'framework/source')
-rw-r--r-- | framework/source/uielement/toolbarmanager.cxx | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 5ca1bb8daa69..1ee4797d889b 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -232,13 +232,10 @@ 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(); - // #i93173# delete toolbar lazily as we can still be in one of its handlers // tdf#119390 this will reparent the toolbar, so focus is restored from a // floating toolbar to the last focused control of the application window. - m_pToolBar->doLazyDelete(); - + m_pToolBar->SetParentToDefaultWindow(); + // #i93173# note we can still be in one of the toolbar's handlers m_pToolBar->SetSelectHdl( Link<ToolBox *, void>() ); m_pToolBar->SetActivateHdl( Link<ToolBox *, void>() ); m_pToolBar->SetDeactivateHdl( Link<ToolBox *, void>() ); @@ -248,7 +245,7 @@ void ToolBarManager::Destroy() m_pToolBar->SetStateChangedHdl( Link<StateChangedType const *, void>() ); m_pToolBar->SetDataChangedHdl( Link<DataChangedEvent const *, void>() ); - m_pToolBar.clear(); + m_pToolBar.disposeAndClear(); SvtMiscOptions().RemoveListenerLink( LINK( this, ToolBarManager, MiscOptionsChanged ) ); } |