diff --git a/cura/Scene/CuraSceneController.py b/cura/Scene/CuraSceneController.py index c3aa3d0a7e..1d604b74b6 100644 --- a/cura/Scene/CuraSceneController.py +++ b/cura/Scene/CuraSceneController.py @@ -107,8 +107,8 @@ class CuraSceneController(QObject): """Either select or deselect an item""" modifiers = QApplication.keyboardModifiers() - ctrl_is_active = modifiers & Qt.ControlModifier - shift_is_active = modifiers & Qt.ShiftModifier + ctrl_is_active = modifiers & Qt.KeyboardModifier.ControlModifier + shift_is_active = modifiers & Qt.KeyboardModifier.ShiftModifier if ctrl_is_active: item = self._objects_model.getItem(index) diff --git a/plugins/SimulationView/SimulationView.py b/plugins/SimulationView/SimulationView.py index de13851f5d..532ef459c0 100644 --- a/plugins/SimulationView/SimulationView.py +++ b/plugins/SimulationView/SimulationView.py @@ -598,8 +598,8 @@ class SimulationView(CuraView): def event(self, event) -> bool: modifiers = QApplication.keyboardModifiers() - ctrl_is_active = modifiers & Qt.ControlModifier - shift_is_active = modifiers & Qt.ShiftModifier + ctrl_is_active = modifiers & Qt.KeyboardModifier.ControlModifier + shift_is_active = modifiers & Qt.KeyboardModifier.ShiftModifier if event.type == Event.KeyPressEvent and ctrl_is_active: amount = 10 if shift_is_active else 1 if event.key == KeyEvent.UpKey: diff --git a/plugins/SupportEraser/SupportEraser.py b/plugins/SupportEraser/SupportEraser.py index d9b0aa8483..0a714396aa 100644 --- a/plugins/SupportEraser/SupportEraser.py +++ b/plugins/SupportEraser/SupportEraser.py @@ -53,7 +53,7 @@ class SupportEraser(Tool): def event(self, event): super().event(event) modifiers = QApplication.keyboardModifiers() - ctrl_is_active = modifiers & Qt.ControlModifier + ctrl_is_active = modifiers & Qt.KeyboardModifier.ControlModifier if event.type == Event.MousePressEvent and MouseEvent.LeftButton in event.buttons and self._controller.getToolsEnabled(): if ctrl_is_active: