mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-09 14:55:03 -06:00
Merge branch 'master' into CURA-5744-move-oauth-login
This commit is contained in:
commit
185a1707b2
10 changed files with 42 additions and 14 deletions
|
@ -37,7 +37,7 @@
|
|||
"top_bottom_thickness": {
|
||||
"default_value": 0.6
|
||||
},
|
||||
"top_bottom_pattern": {
|
||||
"top_bottom_pattern_0": {
|
||||
"default_value": "concentric"
|
||||
},
|
||||
"infill_pattern": {
|
||||
|
|
|
@ -29,7 +29,6 @@ Menu
|
|||
onTriggered:
|
||||
{
|
||||
settingVisibilityPresetsModel.setActivePreset(model.id);
|
||||
showSettingVisibilityProfile();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -27,9 +27,20 @@ Item
|
|||
|
||||
function updateMaterialPropertiesObject()
|
||||
{
|
||||
// DRAGON WARNING!!! DO NOT TOUCH THIS IF YOU DON'T KNOW.
|
||||
// TL;DR: Always update "container_id" first!
|
||||
//
|
||||
// Other widgets such as MaterialsView have bindings towards "materialProperties" and its properties. Here the
|
||||
// properties are updated one by one, and each change can trigger a reaction on those widgets that have
|
||||
// connections to the property gets changed, and some reactions will use functions such as
|
||||
// ContainerManager.getContainerMetaDataEntry() to fetch data using the "container_id" as the reference.
|
||||
// We need to change "container_id" first so any underlying triggers will use the correct "container_id" to
|
||||
// fetch data. Or, for example, if we change GUID first, which triggered the weight widget to fetch weight
|
||||
// before we can update "container_id", so it will fetch weight with the wrong (old) "container_id".
|
||||
materialProperties.container_id = currentItem.id
|
||||
|
||||
materialProperties.name = currentItem.name || "Unknown"
|
||||
materialProperties.guid = currentItem.GUID
|
||||
materialProperties.container_id = currentItem.id
|
||||
materialProperties.brand = currentItem.brand || "Unknown"
|
||||
materialProperties.material = currentItem.material || "Unknown"
|
||||
materialProperties.color_name = currentItem.color_name || "Yellow"
|
||||
|
|
|
@ -17,9 +17,23 @@ Item
|
|||
|
||||
// Children
|
||||
UM.I18nCatalog { id: catalog; name: "cura"; }
|
||||
Cura.MaterialBrandsModel { id: materialsModel }
|
||||
Cura.FavoriteMaterialsModel { id: favoriteMaterialsModel }
|
||||
Cura.GenericMaterialsModel { id: genericMaterialsModel }
|
||||
Cura.MaterialBrandsModel
|
||||
{
|
||||
id: materialsModel
|
||||
extruderPosition: Cura.ExtruderManager.activeExtruderIndex
|
||||
}
|
||||
|
||||
Cura.FavoriteMaterialsModel
|
||||
{
|
||||
id: favoriteMaterialsModel
|
||||
extruderPosition: Cura.ExtruderManager.activeExtruderIndex
|
||||
}
|
||||
|
||||
Cura.GenericMaterialsModel
|
||||
{
|
||||
id: genericMaterialsModel
|
||||
extruderPosition: Cura.ExtruderManager.activeExtruderIndex
|
||||
}
|
||||
|
||||
property var currentType: null
|
||||
property var currentBrand: null
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue