Added opacity to preview if print is done / paused

CL-896
This commit is contained in:
Jaime van Kessel 2018-08-24 16:26:51 +02:00
parent 9564f98ccc
commit d57f166b08

View File

@ -439,6 +439,23 @@ Component
anchors.horizontalCenter: parent.horizontalCenter anchors.horizontalCenter: parent.horizontalCenter
width: parent.width / 2 width: parent.width / 2
height: width height: width
opacity:
{
if(modelData.activePrintJob == null)
{
return 1.0
}
switch(modelData.activePrintJob.state)
{
case "wait_cleanup":
case "wait_user_action":
case "paused":
return 0.5
default:
return 1.0
}
}
} }
Rectangle Rectangle