diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2016-02-07 17:53:40 +0200 |
---|---|---|
committer | Maxim Monastirsky <momonasmon@gmail.com> | 2016-02-15 12:08:07 +0000 |
commit | 2abdcfd641883f246fe78f2fbe38499c9382c059 (patch) | |
tree | afbe57205258c7371f732389deb33c33cd49d639 /vcl/inc/salmenu.hxx | |
parent | 7347248254595c082682180f7a1cfe768f5509a6 (diff) |
tdf#97665 Let's hope that over activation isn't really needed
- MenuBarManager::Activate has a check for duplicate activation,
which makes the second activation attempt fail. Removing this
check or deactivating after each activation will likely affect
performance even more, but on the other hand should solve
lp#1296715, which was the main reason of the over activation
in the first place. So let's activate only one menu at a time,
and do full activation only on the initial update.
- Unfortunately the HUD activation callback doesn't work, so
we still have to keep active status listener for all menu
items. (Which is BTW against the recommendation in
XPopupMenuController::updatePopupMenu IDL doc. Fortunately
the performance problem hardly noticeable on modern hw.)
Change-Id: I96affa72412f3f38160fdca4b6efd20ca68d059f
Reviewed-on: https://gerrit.libreoffice.org/22369
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
Diffstat (limited to 'vcl/inc/salmenu.hxx')
-rw-r--r-- | vcl/inc/salmenu.hxx | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/vcl/inc/salmenu.hxx b/vcl/inc/salmenu.hxx index fba86a1fed59..d7930bbc39fe 100644 --- a/vcl/inc/salmenu.hxx +++ b/vcl/inc/salmenu.hxx @@ -77,6 +77,7 @@ public: virtual bool ShowNativePopupMenu(FloatingWindow * pWin, const Rectangle& rRect, FloatWinPopupFlags nFlags); virtual bool AddMenuBarButton( const SalMenuButtonItem& ); // return false if not implemented or failure virtual void RemoveMenuBarButton( sal_uInt16 nId ); + virtual void Update() {} // TODO: implement show/hide for the Win/Mac VCL native backends virtual void ShowItem( unsigned nPos, bool bShow ) { EnableItem( nPos, bShow ); } |