Don't show temperature if print core is removed in UM3

The empty string as hotend ID is interpreted as there being no hotend, since this is what the UM3 returns in that case.

Contributes to issue CURA-3161.
This commit is contained in:
Ghostkeeper 2017-02-16 13:23:20 +01:00
parent 140d5204c3
commit abf092512a
No known key found for this signature in database
GPG key ID: C5F96EE2BC0F7E75
2 changed files with 6 additions and 2 deletions

View file

@ -96,7 +96,7 @@ Column
}
Label //Temperature indication.
{
text: (connectedPrinter != null && connectedPrinter.hotendTemperatures[index] != null) ? Math.round(connectedPrinter.hotendTemperatures[index]) + "°C" : ""
text: (connectedPrinter != null && connectedPrinter.hotendIds[index] != null && connectedPrinter.hotendTemperatures[index] != null) ? Math.round(connectedPrinter.hotendTemperatures[index]) + "°C" : ""
color: UM.Theme.getColor("text")
font: UM.Theme.getFont("large")
anchors.right: parent.right