WIP Fix an error in which the current selected material was not

correctly selected when there is more than one brand (stupid mistake).
Also fix problems when the user changes some material information.

Contributes to CURA-5682.
This commit is contained in:
Diego Prado Gesto 2018-09-14 10:51:56 +02:00
parent 6dc53cc60a
commit 972f0bef43
3 changed files with 53 additions and 25 deletions

View file

@ -572,21 +572,21 @@ TabView
}
// update the values
base.materialManager.setMaterialName(base.currentMaterialNode, new_name);
materialProperties.name = new_name;
base.materialManager.setMaterialName(base.currentMaterialNode, new_name)
properties.name = new_name
}
// update the type of the material
function updateMaterialType(old_type, new_type)
{
base.setMetaDataEntry("material", old_type, new_type);
materialProperties.material = new_type;
base.setMetaDataEntry("material", old_type, new_type)
properties.material = new_type
}
// update the brand of the material
function updateMaterialBrand(old_brand, new_brand)
{
base.setMetaDataEntry("brand", old_brand, new_brand);
materialProperties.brand = new_brand;
base.setMetaDataEntry("brand", old_brand, new_brand)
properties.brand = new_brand
}
}