Viewer: Fix incorrect positioning of context menu for viewer toolbar. Fixes #1898577 [Right-clicking on toolbar - menu appears in corner of desktop](https://bugs.launchpad.net/calibre/+bug/1898577)

This commit is contained in:
Kovid Goyal 2020-10-05 21:32:52 +05:30
parent 56a9b9529a
commit 4ff8481b83
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -120,7 +120,7 @@ class ActionsToolBar(ToolBar):
a.triggered.connect(self.customize)
a = m.addAction(_('Hide this toolbar'))
a.triggered.connect(self.hide_toolbar)
m.exec_(pos)
m.exec_(self.mapToGlobal(pos))
def hide_toolbar(self):
self.web_view.trigger_shortcut('toggle_toolbar')