Only show material info button for multi-extrusion machines

CURA-3810
This commit is contained in:
Lipu Fei 2017-05-29 16:01:32 +02:00
parent 85e875257b
commit c80e1b67a5
2 changed files with 9 additions and 5 deletions

View File

@ -1362,7 +1362,3 @@ class CuraApplication(QtApplication):
node = node.getParent()
Selection.add(node)
@pyqtSlot(result=str)
def getCuraVersion(self):
return CuraVersion

View File

@ -213,6 +213,7 @@ Column
width: height
anchors.margins: UM.Theme.getSize("default_margin").width
anchors.verticalCenter: parent.verticalCenter
visible: extrudersList.visible
text: "i"
style: UM.Theme.styles.info_button
@ -220,7 +221,7 @@ Column
onClicked:
{
// open the material URL with web browser
var version = CuraApplication.getCuraVersion();
var version = UM.Application.version;
var machineName = Cura.MachineManager.activeMachineDefinitionId;
var url = "https://ultimaker.com/materialcompatibility/" + version + "/" + machineName;
@ -243,6 +244,13 @@ Column
}
}
Text // to take the space of the material info button when the active machine doesn't have multiple extruders
{
height: parent.height * 0.70
width: height
visible: !extrudersList.visible
}
Text
{
width: parent.width * 0.10 - materialInfoButton.width - UM.Theme.getSize("default_margin").width