mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 06:39:04 +08:00
WIP: Fix material name fetching in QML
This commit is contained in:
parent
628d031542
commit
c65192000e
@ -252,8 +252,18 @@ Column
|
||||
{
|
||||
id: materialSelection
|
||||
|
||||
text: Cura.MachineManager.currentRootMaterialName[base.currentExtruderIndex]
|
||||
tooltip: Cura.MachineManager.currentRootMaterialName[base.currentExtruderIndex]
|
||||
property var currentRootMaterialName:
|
||||
{
|
||||
var materials = Cura.MachineManager.currentRootMaterialName;
|
||||
var materialName = "";
|
||||
if (base.currentExtruderIndex in materials) {
|
||||
materialName = materials[base.currentExtruderIndex];
|
||||
}
|
||||
return materialName;
|
||||
}
|
||||
|
||||
text: currentRootMaterialName
|
||||
tooltip: currentRootMaterialName
|
||||
visible: Cura.MachineManager.hasMaterials
|
||||
enabled: !extrudersList.visible || base.currentExtruderIndex > -1
|
||||
height: UM.Theme.getSize("setting_control").height
|
||||
|
Loading…
x
Reference in New Issue
Block a user