temperature: fix #763

This commit is contained in:
alfrix 2022-10-23 20:57:47 -03:00
parent d6e4ad0a35
commit b36e75ec1a
2 changed files with 2 additions and 2 deletions

View File

@ -146,7 +146,7 @@ class BasePanel(ScreenPanel):
n = 0
if self._screen.printer.get_tools():
self.current_extruder = self._screen.printer.get_stat("toolhead", "extruder")
if self.current_extruder:
if self.current_extruder and f"{self.current_extruder}_box" in self.labels:
self.control['temp_box'].add(self.labels[f"{self.current_extruder}_box"])
n += 1

View File

@ -211,7 +211,7 @@ class TemperaturePanel(ScreenPanel):
self.hide_numpad()
def select_heater(self, widget, device):
if self.active_heater is None and self.devices[device]["can_target"]:
if self.active_heater is None and device in self.devices and self.devices[device]["can_target"]:
if device in self.active_heaters:
self.active_heaters.pop(self.active_heaters.index(device))
self.devices[device]['name'].get_style_context().remove_class("button_active")