mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Disable user "unchecking" mesh type in per model settings panel
This commit is contained in:
parent
d00ec619f5
commit
ca7a4b4779
1 changed files with 12 additions and 5 deletions
|
@ -32,10 +32,7 @@ Item
|
||||||
var type = currentMeshType
|
var type = currentMeshType
|
||||||
|
|
||||||
// set checked state of mesh type buttons
|
// set checked state of mesh type buttons
|
||||||
normalButton.checked = type === normalMeshType
|
updateMeshTypeCheckedState(type)
|
||||||
supportMeshButton.checked = type === supportMeshType
|
|
||||||
overhangMeshButton.checked = type === infillMeshType || type === cuttingMeshType
|
|
||||||
antiOverhangMeshButton.checked = type === antiOverhangMeshType
|
|
||||||
|
|
||||||
// update active type label
|
// update active type label
|
||||||
for (var button in meshTypeButtons.children)
|
for (var button in meshTypeButtons.children)
|
||||||
|
@ -49,9 +46,19 @@ Item
|
||||||
visibility_handler.addSkipResetSetting(currentMeshType)
|
visibility_handler.addSkipResetSetting(currentMeshType)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function updateMeshTypeCheckedState(type)
|
||||||
|
{
|
||||||
|
// set checked state of mesh type buttons
|
||||||
|
normalButton.checked = type === normalMeshType
|
||||||
|
supportMeshButton.checked = type === supportMeshType
|
||||||
|
overlapMeshButton.checked = type === infillMeshType || type === cuttingMeshType
|
||||||
|
antiOverhangMeshButton.checked = type === antiOverhangMeshType
|
||||||
|
}
|
||||||
|
|
||||||
function setMeshType(type)
|
function setMeshType(type)
|
||||||
{
|
{
|
||||||
UM.ActiveTool.setProperty("MeshType", type)
|
UM.ActiveTool.setProperty("MeshType", type)
|
||||||
|
updateMeshTypeCheckedState(type)
|
||||||
}
|
}
|
||||||
|
|
||||||
UM.I18nCatalog { id: catalog; name: "uranium"}
|
UM.I18nCatalog { id: catalog; name: "uranium"}
|
||||||
|
@ -95,7 +102,7 @@ Item
|
||||||
|
|
||||||
Button
|
Button
|
||||||
{
|
{
|
||||||
id: overhangMeshButton
|
id: overlapMeshButton
|
||||||
text: catalog.i18nc("@label", "Modify settings for overlaps")
|
text: catalog.i18nc("@label", "Modify settings for overlaps")
|
||||||
iconSource: UM.Theme.getIcon("pos_modify_overlaps");
|
iconSource: UM.Theme.getIcon("pos_modify_overlaps");
|
||||||
property bool needBorder: true
|
property bool needBorder: true
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue