mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-23 22:54:01 -06:00
Merge branch 'master' into feature_sync_button
This commit is contained in:
commit
5280d21c26
16 changed files with 101 additions and 145 deletions
|
@ -52,6 +52,7 @@ Menu
|
|||
{
|
||||
text: model.name
|
||||
checkable: model.available
|
||||
enabled: model.available
|
||||
checked: Cura.MachineManager.activeQualityOrQualityChangesName == model.name
|
||||
exclusiveGroup: group
|
||||
onTriggered: Cura.MachineManager.setQualityChangesGroup(model.quality_changes_group)
|
||||
|
|
|
@ -47,6 +47,19 @@ TabView
|
|||
return Math.round(diameter);
|
||||
}
|
||||
|
||||
// This trick makes sure to make all fields lose focus so their onEditingFinished will be triggered
|
||||
// and modified values will be saved. This can happen when a user changes a value and then closes the
|
||||
// dialog directly.
|
||||
//
|
||||
// Please note that somehow this callback is ONLY triggered when visible is false.
|
||||
onVisibleChanged:
|
||||
{
|
||||
if (!visible)
|
||||
{
|
||||
base.focus = false;
|
||||
}
|
||||
}
|
||||
|
||||
Tab
|
||||
{
|
||||
title: catalog.i18nc("@title", "Information")
|
||||
|
|
|
@ -52,6 +52,24 @@ Item
|
|||
return base.currentItem.root_material_id == root_material_id;
|
||||
}
|
||||
|
||||
Component.onCompleted:
|
||||
{
|
||||
// Select the activated material when this page shows up
|
||||
const extruder_position = Cura.ExtruderManager.activeExtruderIndex;
|
||||
const active_root_material_id = Cura.MachineManager.currentRootMaterialId[extruder_position];
|
||||
var itemIndex = -1;
|
||||
for (var i = 0; i < materialsModel.rowCount(); ++i)
|
||||
{
|
||||
var item = materialsModel.getItem(i);
|
||||
if (item.root_material_id == active_root_material_id)
|
||||
{
|
||||
itemIndex = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
materialListView.currentIndex = itemIndex;
|
||||
}
|
||||
|
||||
Row // Button Row
|
||||
{
|
||||
id: buttonRow
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue