diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2018-02-08 01:47:46 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2018-02-23 17:19:01 +0100 |
commit | 3b457cb8825882cadec44e0b0679d1e70051eb71 (patch) | |
tree | 7bad80e756ac1a7792ac5d3920aec97a5b335a42 | |
parent | a3f5be83da9a1147c102122a89f17e2b75e062fe (diff) |
tdf#100784 macOS: Don't attempt to handle shortcuts via the menubar
... when it's hidden.
Change-Id: I7930afb8124dd552843512cd30bce4d82ade0c70
Reviewed-on: https://gerrit.libreoffice.org/49399
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
(cherry picked from commit 9d77e7551e56b85d7f1b40bc42b9ba6876091f22)
Reviewed-on: https://gerrit.libreoffice.org/49707
Reviewed-by: Tor Lillqvist <tml@collabora.com>
-rw-r--r-- | vcl/osx/vclnsapp.mm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vcl/osx/vclnsapp.mm b/vcl/osx/vclnsapp.mm index a4f00e32c4f0..09c3a8001f2d 100644 --- a/vcl/osx/vclnsapp.mm +++ b/vcl/osx/vclnsapp.mm @@ -160,7 +160,8 @@ SAL_WNODEPRECATED_DECLARATIONS_PUSH // the main menu just beeps for an unknown or disabled key equivalent // and swallows the event wholesale NSMenu* pMainMenu = [NSApp mainMenu]; - if( ! bHandled && (pMainMenu == nullptr || ! [pMainMenu performKeyEquivalent: pEvent]) ) + if( ! bHandled && + (pMainMenu == nullptr || ! [NSMenu menuBarVisible] || ! [pMainMenu performKeyEquivalent: pEvent]) ) { [[pKeyWin contentView] keyDown: pEvent]; bHandled = GetSalData()->maKeyEventAnswer[ pEvent ]; |