Fix material colour when no printer is selected

It's invisible anyway, but the hex colour gives no errors at least.

Contributes to issue CURA-3161.
This commit is contained in:
Ghostkeeper 2017-02-03 15:49:18 +01:00
parent 1305dd88d7
commit 03e16b5398
No known key found for this signature in database
GPG Key ID: C5F96EE2BC0F7E75

View File

@ -115,7 +115,7 @@ Column
id: materialColor
width: materialName.height * 0.75
height: materialName.height * 0.75
color: printerConnected ? connectedPrinter.materialColors[index] : [0, 0, 0, 0] //Need to check for printerConnected or materialColors[index] gives an error.
color: printerConnected ? connectedPrinter.materialColors[index] : "#00000000" //Need to check for printerConnected or materialColors[index] gives an error.
border.width: UM.Theme.getSize("default_lining").width
border.color: UM.Theme.getColor("lining")
visible: printerConnected