diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2016-03-02 22:40:14 +0200 |
---|---|---|
committer | Ashod Nakashian <ashod.nakashian@collabora.co.uk> | 2016-07-12 22:06:31 -0400 |
commit | 83644c8438a449eed20cd1cf52b0d78fb37b5b7b (patch) | |
tree | 94bf229354f14b7b6adffb95681c7dcf51a040c5 /sfx2 | |
parent | 320188bccca1458f1a40b3bb36f68799c841aab2 (diff) |
Context menus were never destructed
Change-Id: I34ae9dbb5b00fa2b6a1ef5c115a796d4e28eafa9
(cherry picked from commit 9d6e1de029e992d189882ed7098acb6ac8cfe1fe)
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/control/dispatch.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx index 12444ef21559..976ee4407236 100644 --- a/sfx2/source/control/dispatch.cxx +++ b/sfx2/source/control/dispatch.cxx @@ -1936,6 +1936,10 @@ void SfxDispatcher::ExecutePopup( const OUString& rResName, vcl::Window *pWin, c PopupMenu* pVCLMenu = static_cast< PopupMenu* >( pAwtMenu->GetMenu() ); if ( pVCLMenu && GetFrame()->GetViewShell()->TryContextMenuInterception( *pVCLMenu, rResName, aEvent ) ) pVCLMenu->Execute( pWindow, aPos ); + + css::uno::Reference< css::lang::XComponent > xComponent( xPopupController, css::uno::UNO_QUERY ); + if ( xComponent.is() ) + xComponent->dispose(); } /** With this method the SfxDispatcher can be locked and released. A locked |