gui/shortcuts: make global shortcuts really global

This commit is contained in:
Sebastien Bourdeauducq 2015-12-01 18:49:23 +08:00
parent de54f57fbe
commit 08abc2e00a

View File

@ -1,7 +1,7 @@
import logging
from functools import partial
from quamash import QtGui
from quamash import QtGui, QtCore
from pyqtgraph import dockarea
try:
from quamash import QtWidgets
@ -63,6 +63,7 @@ class ShortcutsDock(dockarea.Dock):
"submit": submit
}
shortcut = QShortcut("F" + str(i+1), main_window)
shortcut.setContext(QtCore.Qt.ApplicationShortcut)
shortcut.activated.connect(partial(self._activated, i))
def _activated(self, nr):