Removed the static placeholders for monitor info

CL-894
This commit is contained in:
Jaime van Kessel 2018-08-16 15:54:35 +02:00
parent 0fe0e4ac54
commit 5bee561c9c
2 changed files with 29 additions and 9 deletions

View File

@ -19,7 +19,7 @@ Item
text: printCoreConfiguration.activeMaterial != null ? printCoreConfiguration.activeMaterial.name : ":(" text: printCoreConfiguration.activeMaterial != null ? printCoreConfiguration.activeMaterial.name : ":("
elide: Text.ElideRight elide: Text.ElideRight
width: parent.width width: parent.width
font: UM.Theme.getFont("very_small") font: UM.Theme.getFont("default_bold")
} }
Label Label
@ -29,7 +29,5 @@ Item
anchors.top: materialLabel.bottom anchors.top: materialLabel.bottom
elide: Text.ElideRight elide: Text.ElideRight
width: parent.width width: parent.width
font: UM.Theme.getFont("very_small")
opacity: 0.5
} }
} }

View File

@ -35,14 +35,15 @@ Item
Label Label
{ {
id: printJobName id: printJobName
text: "printJobName" text: printJob.name
font: UM.Theme.getFont("default_bold")
} }
Label Label
{ {
id: ownerName id: ownerName
anchors.top: printJobName.bottom anchors.top: printJobName.bottom
text: "OwnerName" text: printJob.owner
} }
Image Image
@ -61,7 +62,7 @@ Item
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.right: parent.right anchors.right: parent.right
text: printJob != null ? getPrettyTime(printJob.timeTotal) : "3h 12m" text: printJob != null ? getPrettyTime(printJob.timeTotal) : ""
elide: Text.ElideRight elide: Text.ElideRight
} }
} }
@ -81,7 +82,27 @@ Item
Label Label
{ {
id: targetPrinterLabel id: targetPrinterLabel
text: "Waiting for: first available" elide: Text.ElideRight
font: UM.Theme.getFont("default_bold")
text:
{
if(printJob.assignedPrinter == null)
{
return "Waiting for: first available"
}
else
{
return "Waiting for: " + printJob.assignedPrinter.name
}
}
anchors
{
left: parent.left
right: contextButton.left
rightMargin: UM.Theme.getSize("default_margin").width
}
} }
@ -89,6 +110,7 @@ Item
{ {
popup.visible ? popup.close() : popup.open() popup.visible ? popup.close() : popup.open()
} }
Button Button
{ {
id: contextButton id: contextButton
@ -119,8 +141,8 @@ Item
transformOrigin: Popup.Top transformOrigin: Popup.Top
contentItem: Item contentItem: Item
{ {
width: panelWidth - 2 * popup.padding width: popup.width - 2 * popup.padding
height: cildrenRect.height height: childrenRect.height
Button Button
{ {
text: "Send to top" text: "Send to top"