Просмотр исходного кода

Refusing to change material actually prevents material from being changed

CURA-1909
Jaime van Kessel 8 лет назад
Родитель
Сommit
951e7bf629
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      cura/Settings/MachineManager.py

+ 6 - 0
cura/Settings/MachineManager.py

@@ -126,6 +126,9 @@ class MachineManager(QObject):
         self._auto_change_material_hotend_flood_time = time.time()
         self._auto_change_material_hotend_flood_last_choice = button
 
+        if button == QMessageBox.No:
+            return
+
         Logger.log("d", "Setting hotend variant of hotend %d to %s" % (index, hotend_id))
 
         extruder_manager = ExtruderManager.getInstance()
@@ -174,6 +177,9 @@ class MachineManager(QObject):
         self._auto_change_material_hotend_flood_time = time.time()
         self._auto_change_material_hotend_flood_last_choice = button
 
+        if button == QMessageBox.No:
+            return
+
         Logger.log("d", "Setting material of hotend %d to %s" % (index, material_id))
 
         extruder_manager = ExtruderManager.getInstance()