diff --git a/charon_vna/gui.py b/charon_vna/gui.py index a561353..d73be6e 100644 --- a/charon_vna/gui.py +++ b/charon_vna/gui.py @@ -136,15 +136,15 @@ class MainWindow(QMainWindow): action_load_config = QAction("&Open Configuration", self) menu_file.addAction(action_load_config) action_load_config.triggered.connect(self.load_config) - QShortcut(QKeySequence("Ctrl+O"), self).activated.connect(self.load_config) + action_load_config.setShortcut(QKeySequence("Ctrl+O")) action_save_config = QAction("&Save Configuration", self) menu_file.addAction(action_save_config) action_save_config.triggered.connect(self.save_config) - QShortcut(QKeySequence("Ctrl+S"), self).activated.connect(self.save_config) + action_save_config.setShortcut(QKeySequence("Ctrl+S")) action_saveas_config = QAction("Save Configuration &As", self) menu_file.addAction(action_saveas_config) action_saveas_config.triggered.connect(self.saveas_config) - QShortcut(QKeySequence("Ctrl+Shift+S"), self).activated.connect(self.saveas_config) + action_saveas_config.setShortcut(QKeySequence("Ctrl+Shift+S")) menu_stimulus = QMenu("&Stimulus") menubar.addMenu(menu_stimulus)